yftzeng / phash-0.9.6-patches Goto Github PK
View Code? Open in Web Editor NEWpHash-0.9.6 was released at 2013-04-23, but there are 2 major problems for certain usage, so I patched
pHash-0.9.6 was released at 2013-04-23, but there are 2 major problems for certain usage, so I patched
Using on old Ubuntu 16 LTS... Official pHash-0.9.6 not works. Using here was good (!), all installation ok... But PHP step not:
phpize
PHP Api Version: 20170718
Zend Module Api No: 20170718
Zend Extension Api No: 320170718
autoconf: warning: both `configure.ac' and `configure.in' are present.
autoconf: warning: proceeding with `configure.ac'.
autoheader: 'configure.ac' and 'configure.in' both present.
autoheader: proceeding with 'configure.ac'
./configure LIBS="-lpthread"
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for a sed that does not truncate output... /bin/sed
checking for cc... cc
(...)
checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking dynamic linker characteristics... (cached) GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
configure: creating ./config.status
config.status: creating config.h
config.status: executing libtool commands
make && sudo make install
/bin/bash /home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php/libtool --mode=compile g++ -I. -I/home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php -DPHP_ATOM_INC -I/home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php/include -I/home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php/main -I/home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php -I/usr/include/php/20170718 -I/usr/include/php/20170718/main -I/usr/include/php/20170718/TSRM -I/usr/include/php/20170718/Zend -I/usr/include/php/20170718/ext -I/usr/include/php/20170718/ext/date/lib -I/usr/local/include -DHAVE_CONFIG_H -g -O2 -c /home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php/pHash.cpp -o pHash.lo
libtool: compile: g++ -I. -I/home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php -DPHP_ATOM_INC -I/home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php/include -I/home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php/main -I/home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php -I/usr/include/php/20170718 -I/usr/include/php/20170718/main -I/usr/include/php/20170718/TSRM -I/usr/include/php/20170718/Zend -I/usr/include/php/20170718/ext -I/usr/include/php/20170718/ext/date/lib -I/usr/local/include -DHAVE_CONFIG_H -g -O2 -c /home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php/pHash.cpp -fPIC -DPIC -o .libs/pHash.o
/home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php/pHash.cpp:296:23: error: macro "RETURN_STRING" passed 2 arguments, but takes just 1
RETURN_STRING(str, 0);
^
/home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php/pHash.cpp:51:36: error: variable or field ‘ph_video_hash_dtor’ declared void
extern "C" void ph_video_hash_dtor(zend_rsrc_list_entry *rsrc TSRMLS_DC)
^
/home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php/pHash.cpp:51:36: error: ‘zend_rsrc_list_entry’ was not declared in this scope
/home/user/sandbox/pHash-0.9.6-patches/pHash-0.9.6/bindings/php/pHash.cpp:51:58: error: ‘rsrc’ was not declared in this scope
extern "C" void ph_video_hash_dtor(zend_rsrc_list_entry *rsrc TSRMLS_DC)
^
Makefile:195: recipe for target 'pHash.lo' failed
make: *** [pHash.lo] Error 1
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.