diff options
author | Jan Beich <jbeich@FreeBSD.org> | 2015-09-11 23:27:46 +0000 |
---|---|---|
committer | Jan Beich <jbeich@FreeBSD.org> | 2015-09-11 23:27:46 +0000 |
commit | 47471a2a828c48e9671bb5947df3f5db1019b1d6 (patch) | |
tree | 0f84db6d703d1d80878c37a8674970bf20ba74ce | |
parent | 8f5451ae43c3821516210a7b3de4f0394d6a5c9c (diff) | |
download | ports-47471a2a828c48e9671bb5947df3f5db1019b1d6.tar.gz ports-47471a2a828c48e9671bb5947df3f5db1019b1d6.zip |
Notes
-rw-r--r-- | multimedia/Makefile | 1 | ||||
-rw-r--r-- | multimedia/pHash/Makefile | 57 | ||||
-rw-r--r-- | multimedia/pHash/distinfo | 2 | ||||
-rw-r--r-- | multimedia/pHash/files/patch-src_pHash.cpp | 22 | ||||
-rw-r--r-- | multimedia/pHash/pkg-descr | 5 | ||||
-rw-r--r-- | multimedia/pHash/pkg-plist | 9 |
6 files changed, 96 insertions, 0 deletions
diff --git a/multimedia/Makefile b/multimedia/Makefile index f1d5f77d8824..fc872faf3e51 100644 --- a/multimedia/Makefile +++ b/multimedia/Makefile @@ -279,6 +279,7 @@ SUBDIR += p5-Subtitles SUBDIR += p5-Umph-Prompt SUBDIR += p5-Video-OpenQuicktime + SUBDIR += pHash SUBDIR += phonon SUBDIR += phonon-designerplugin SUBDIR += phonon-gstreamer diff --git a/multimedia/pHash/Makefile b/multimedia/pHash/Makefile new file mode 100644 index 000000000000..795554abf884 --- /dev/null +++ b/multimedia/pHash/Makefile @@ -0,0 +1,57 @@ +# Created by: Naram Qashat <cyberbotx@cyberbotx.com> +# $FreeBSD$ + +PORTNAME= pHash +PORTVERSION= 0.9.6 +CATEGORIES= multimedia devel +MASTER_SITES= http://phash.org/releases/ \ + http://www.cyberbotx.com/pHash/ + +MAINTAINER= cyberbotx@cyberbotx.com +COMMENT= Open source perceptual hash library + +LICENSE= GPLv3 # or any later version + +USES= gmake libtool pathfix +GNU_CONFIGURE= yes +CONFIGURE_ENV= PTHREAD_LIBS="-lpthread" +INSTALL_TARGET= install-strip +USE_LDCONFIG= yes + +OPTIONS_DEFINE= DEBUG FFTW JPEG OPENMP PNG +OPTIONS_MULTI= HASHING +OPTIONS_MULTI_HASHING= AUDIO IMAGE VIDEO +OPTIONS_DEFAULT= FFTW JPEG PNG AUDIO IMAGE VIDEO +AUDIO_DESC= Enable audio hashing +IMAGE_DESC= Enable image hashing +VIDEO_DESC= Enable video hashing + +DEBUG_CONFIGURE_ENABLE= debug + +FFTW_CONFIGURE_WITH= fftw +FFTW_LIB_DEPENDS= libfftw3.so:${PORTSDIR}/math/fftw3 + +JPEG_CONFIGURE_WITH= libjpeg +JPEG_USES= jpeg + +OPENMP_CONFIGURE_ENABLE=openmp +OPENMP_USES= compiler:openmp + +PNG_CONFIGURE_WITH= libpng +PNG_LIB_DEPENDS= libpng.so:${PORTSDIR}/graphics/png + +AUDIO_CONFIGURE_ENABLE= audio-hash +AUDIO_LIB_DEPENDS= libsndfile.so:${PORTSDIR}/audio/libsndfile \ + libsamplerate.so:${PORTSDIR}/audio/libsamplerate \ + libmpg123.so:${PORTSDIR}/audio/mpg123 + +IMAGE_CONFIGURE_ENABLE= image-hash +IMAGE_BUILD_DEPENDS= ${LOCALBASE}/include/CImg.h:${PORTSDIR}/graphics/cimg +IMAGE_RUN_DEPENDS= ${LOCALBASE}/include/CImg.h:${PORTSDIR}/graphics/cimg + +VIDEO_CONFIGURE_ENABLE= video-hash +VIDEO_BUILD_DEPENDS= ${LOCALBASE}/include/CImg.h:${PORTSDIR}/graphics/cimg +VIDEO_RUN_DEPENDS= ${LOCALBASE}/include/CImg.h:${PORTSDIR}/graphics/cimg +VIDEO_LIB_DEPENDS= libavcodec.so:${PORTSDIR}/multimedia/ffmpeg + +.include <bsd.port.mk> diff --git a/multimedia/pHash/distinfo b/multimedia/pHash/distinfo new file mode 100644 index 000000000000..ccda48e78c3e --- /dev/null +++ b/multimedia/pHash/distinfo @@ -0,0 +1,2 @@ +SHA256 (pHash-0.9.6.tar.gz) = 3c8258a014f9c2491fb1153010984606805638a45d00498864968a9a30102935 +SIZE (pHash-0.9.6.tar.gz) = 1315965 diff --git a/multimedia/pHash/files/patch-src_pHash.cpp b/multimedia/pHash/files/patch-src_pHash.cpp new file mode 100644 index 000000000000..5528ff0e505f --- /dev/null +++ b/multimedia/pHash/files/patch-src_pHash.cpp @@ -0,0 +1,22 @@ +--- src/pHash.cpp.orig 2013-04-13 17:23:12 UTC ++++ src/pHash.cpp +@@ -34,14 +34,18 @@ + int ph_num_threads() + { + int numCPU = 1; +-#ifdef __GLIBC__ ++#ifdef _SC_NPROCESSORS_ONLN + numCPU = sysconf( _SC_NPROCESSORS_ONLN ); + #else + int mib[2]; + size_t len; + + mib[0] = CTL_HW; ++#ifdef HW_AVAILCPU + mib[1] = HW_AVAILCPU; ++#else ++ mib[1] = HW_NCPU; ++#endif + + sysctl(mib, 2, &numCPU, &len, NULL, 0); + diff --git a/multimedia/pHash/pkg-descr b/multimedia/pHash/pkg-descr new file mode 100644 index 000000000000..f7373cd7321e --- /dev/null +++ b/multimedia/pHash/pkg-descr @@ -0,0 +1,5 @@ +pHash is an open source software library released under the GPLv3 license that +implements several perceptual hashing algorithms, and provides a C-like API to +use those functions in your own programs. pHash itself is written in C++. + +WWW: http://phash.org/ diff --git a/multimedia/pHash/pkg-plist b/multimedia/pHash/pkg-plist new file mode 100644 index 000000000000..13814d437c3a --- /dev/null +++ b/multimedia/pHash/pkg-plist @@ -0,0 +1,9 @@ +include/audiophash.h +include/pHash-config.h +include/pHash.h +include/ph_fft.h +lib/libpHash.a +lib/libpHash.so +lib/libpHash.so.0 +lib/libpHash.so.0.0.0 +libdata/pkgconfig/pHash.pc |