Index: head/audio/libsamplerate/Makefile =================================================================== --- head/audio/libsamplerate/Makefile (revision 564878) +++ head/audio/libsamplerate/Makefile (revision 564879) @@ -1,50 +1,38 @@ # Created by: # $FreeBSD$ PORTNAME= libsamplerate -PORTVERSION= 0.1.9 -PORTREVISION= 1 +DISTVERSION= 0.2.1 CATEGORIES= audio -MASTER_SITES= http://www.mega-nerd.com/SRC/ +MASTER_SITES= https://github.com/libsndfile/${PORTNAME}/releases/download/${DISTVERSION}/ MAINTAINER= multimedia@FreeBSD.org COMMENT= Secret Rabbit Code: a Sample Rate Converter for audio LICENSE= BSD2CLAUSE LICENSE_FILE= ${WRKSRC}/COPYING -USES= cpe libtool pathfix pkgconfig -USE_LDCONFIG= yes +USES= cmake cpe pkgconfig tar:bz2 + CPE_VENDOR= ${CPE_PRODUCT}_project -GNU_CONFIGURE= yes -INSTALL_TARGET= install-strip -TEST_TARGET= check -OPTIONS_DEFINE= CPU_CLIP DOCS EXAMPLES -CPU_CLIP_DESC= Allow machine-dependent clipping +USE_LDCONFIG= yes -.include +TEST_TARGET= test -MAKE_ARGS+= htmldocdir=${PREFIX}/share/doc/libsamplerate +CMAKE_ON= BUILD_SHARED_LIBS LIBSAMPLERATE_INSTALL -.if ${PORT_OPTIONS:MCPU_CLIP} -MANUAL_PACKAGE_BUILD= CPU_CLIP may customize the package for the build machine -.else -CONFIGURE_ARGS+= --disable-cpu-clip -.endif +OPTIONS_DEFINE= DOCS EXAMPLES TEST -.if defined(MAINTAINER_MODE) || defined(PACKAGE_BUILDING) -BUILD_DEPENDS += ${LOCALBASE}/lib/libfftw3.so:math/fftw3 -.else -CONFIGURE_ARGS+= --disable-fftw -.endif +EXAMPLES_LIB_DEPENDS= libsndfile.so:audio/libsndfile +EXAMPLES_CMAKE_BOOL= LIBSAMPLERATE_EXAMPLES -.if ${PORT_OPTIONS:MEXAMPLES} -LIB_DEPENDS+= libsndfile.so:audio/libsndfile -.elif defined(MAINTAINER_MODE) || defined(PACKAGE_BUILDING) -BUILD_DEPENDS += libsndfile>=0:audio/libsndfile -.else -CONFIGURE_ARGS+= --disable-sndfile -.endif +TEST_LIB_DEPENDS= libfftw3.so:math/fftw3 \ + libsndfile.so:audio/libsndfile +TEST_CMAKE_BOOL= BUILD_TESTING + +do-install-EXAMPLES-on: + ${INSTALL_PROGRAM} ${WRKDIR}/.build/examples/timewarp-file ${STAGEDIR}${PREFIX}/bin/ + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/timewarp-file .include Index: head/audio/libsamplerate/distinfo =================================================================== --- head/audio/libsamplerate/distinfo (revision 564878) +++ head/audio/libsamplerate/distinfo (revision 564879) @@ -1,3 +1,3 @@ -TIMESTAMP = 1478374868 -SHA256 (libsamplerate-0.1.9.tar.gz) = 0a7eb168e2f21353fb6d84da152e4512126f7dc48ccb0be80578c565413444c1 -SIZE (libsamplerate-0.1.9.tar.gz) = 4336641 +TIMESTAMP = 1611794308 +SHA256 (libsamplerate-0.2.1.tar.bz2) = f6323b5e234753579d70a0af27796dde4ebeddf58aae4be598e39b3cee00c90a +SIZE (libsamplerate-0.2.1.tar.bz2) = 3747188 Index: head/audio/libsamplerate/files/patch-examples_audio__out.c =================================================================== --- head/audio/libsamplerate/files/patch-examples_audio__out.c (revision 564878) +++ head/audio/libsamplerate/files/patch-examples_audio__out.c (nonexistent) @@ -1,14 +0,0 @@ ---- examples/audio_out.c.orig 2016-09-13 10:20:20 UTC -+++ examples/audio_out.c -@@ -33,9 +33,9 @@ - #define MAKE_MAGIC(a,b,c,d,e,f,g,h) \ - ((a) + ((b) << 1) + ((c) << 2) + ((d) << 3) + ((e) << 4) + ((f) << 5) + ((g) << 6) + ((h) << 7)) - --typedef struct AUDIO_OUT_s -+struct AUDIO_OUT_s - { int magic ; --} AUDIO_OUT ; -+}; - - - /*------------------------------------------------------------------------------ Property changes on: head/audio/libsamplerate/files/patch-examples_audio__out.c ___________________________________________________________________ Deleted: fbsd:nokeywords ## -1 +0,0 ## -yes \ No newline at end of property Deleted: svn:eol-style ## -1 +0,0 ## -native \ No newline at end of property Deleted: svn:mime-type ## -1 +0,0 ## -text/plain \ No newline at end of property Index: head/audio/libsamplerate/files/patch-src_samplerate.h =================================================================== --- head/audio/libsamplerate/files/patch-src_samplerate.h (revision 564878) +++ head/audio/libsamplerate/files/patch-src_samplerate.h (nonexistent) @@ -1,11 +0,0 @@ ---- src/samplerate.h.orig 2016-09-13 10:13:14 UTC -+++ src/samplerate.h -@@ -160,7 +160,7 @@ enum - SRC_SINC_MEDIUM_QUALITY = 1, - SRC_SINC_FASTEST = 2, - SRC_ZERO_ORDER_HOLD = 3, -- SRC_LINEAR = 4, -+ SRC_LINEAR = 4 - } ; - - /* Property changes on: head/audio/libsamplerate/files/patch-src_samplerate.h ___________________________________________________________________ Deleted: fbsd:nokeywords ## -1 +0,0 ## -yes \ No newline at end of property Deleted: svn:eol-style ## -1 +0,0 ## -native \ No newline at end of property Deleted: svn:mime-type ## -1 +0,0 ## -text/plain \ No newline at end of property Index: head/audio/libsamplerate/files/patch-cmake_FindSndFile.cmake =================================================================== --- head/audio/libsamplerate/files/patch-cmake_FindSndFile.cmake (nonexistent) +++ head/audio/libsamplerate/files/patch-cmake_FindSndFile.cmake (revision 564879) @@ -0,0 +1,32 @@ +--- cmake/FindSndFile.cmake.orig 2021-01-28 01:50:45 UTC ++++ cmake/FindSndFile.cmake +@@ -16,10 +16,6 @@ pkg_check_modules(PC_SndFile QUIET sndfile) + + set(SndFile_VERSION ${PC_SndFile_VERSION}) + +-find_package(Vorbis COMPONENTS Enc QUIET) +-find_package(FLAC QUIET) +-find_package(Opus QUIET) +- + find_path(SndFile_INCLUDE_DIR sndfile.h + HINTS + ${PC_SndFile_INCLUDEDIR} +@@ -42,15 +38,14 @@ find_package_handle_standard_args(SndFile + + if(SndFile_FOUND) + +- set(SndFile_LIBRARIES ${SndFile_LIBRARY} ${Vorbis_Enc_LIBRARIES} ${FLAC_LIBRARIES} ${OPUS_LIBRARIES}) +- set(SndFile_INCLUDE_DIRS ${SndFile_INCLUDE_DIR} ${Vorbis_Enc_INCLUDE_DIRS} ${FLAC_INCLUDE_DIRS} ${OPUS_INCLUDE_DIRS}) ++ set(SndFile_LIBRARIES ${SndFile_LIBRARY}) ++ set(SndFile_INCLUDE_DIRS ${SndFile_INCLUDE_DIR}) + + if(NOT TARGET SndFile::sndfile) + add_library(SndFile::sndfile UNKNOWN IMPORTED) + set_target_properties(SndFile::sndfile PROPERTIES + INTERFACE_INCLUDE_DIRECTORIES "${SndFile_INCLUDE_DIR}" +- IMPORTED_LOCATION "${SndFile_LIBRARY}" +- INTERFACE_LINK_LIBRARIES "Vorbis::vorbisenc;Opus::opus;FLAC::FLAC") ++ IMPORTED_LOCATION "${SndFile_LIBRARY}") + endif() + endif() + Property changes on: head/audio/libsamplerate/files/patch-cmake_FindSndFile.cmake ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/audio/libsamplerate/files/patch-examples_CMakeLists.txt =================================================================== --- head/audio/libsamplerate/files/patch-examples_CMakeLists.txt (nonexistent) +++ head/audio/libsamplerate/files/patch-examples_CMakeLists.txt (revision 564879) @@ -0,0 +1,34 @@ +--- examples/CMakeLists.txt.orig 2021-01-28 01:57:53 UTC ++++ examples/CMakeLists.txt +@@ -1,31 +1,5 @@ +-find_package(ALSA) +-set(HAVE_ALSA ${ALSA_FOUND} PARENT_SCOPE) +-# ALSA::ALSA target is exported since CMake >= 3.12, create it for +-# old CMake versions +-if(ALSA_FOUND) +- if(NOT TARGET ALSA::ALSA) +- add_library(ALSA::ALSA UNKNOWN IMPORTED) +- set_target_properties(ALSA::ALSA PROPERTIES +- INTERFACE_INCLUDE_DIRECTORIES "${ALSA_INCLUDE_DIRS}" +- IMPORTED_LOCATION "${ALSA_LIBRARIES}") +- endif() +-endif() +- + add_executable(timewarp-file timewarp-file.c) + target_link_libraries(timewarp-file + PRIVATE + samplerate + $<$:SndFile::sndfile>) +- +-add_executable(varispeed-play varispeed-play.c audio_out.c audio_out.h) +-target_link_libraries(varispeed-play +- PRIVATE +- samplerate +- $<$:SndFile::sndfile>) +-if(WIN32) +- target_link_libraries(varispeed-play PRIVATE winmm) +-elseif(APPLE) +- target_link_libraries(varispeed-play PRIVATE "-framework CoreAudio") +-elseif(ALSA_FOUND) +- target_link_libraries(varispeed-play PRIVATE ALSA::ALSA) +-endif() Property changes on: head/audio/libsamplerate/files/patch-examples_CMakeLists.txt ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/audio/libsamplerate/pkg-plist =================================================================== --- head/audio/libsamplerate/pkg-plist (revision 564878) +++ head/audio/libsamplerate/pkg-plist (revision 564879) @@ -1,22 +1,25 @@ -%%PORTEXAMPLES%%bin/sndfile-resample +%%PORTEXAMPLES%%bin/timewarp-file include/samplerate.h -lib/libsamplerate.a +lib/cmake/SampleRate/SampleRateConfig.cmake +lib/cmake/SampleRate/SampleRateConfigVersion.cmake +lib/cmake/SampleRate/SampleRateTargets-%%CMAKE_BUILD_TYPE%%.cmake +lib/cmake/SampleRate/SampleRateTargets.cmake lib/libsamplerate.so lib/libsamplerate.so.0 -lib/libsamplerate.so.0.1.8 +lib/libsamplerate.so.0.2.1 libdata/pkgconfig/samplerate.pc -%%PORTDOCS%%%%DOCSDIR%%/SRC.css %%PORTDOCS%%%%DOCSDIR%%/SRC.png -%%PORTDOCS%%%%DOCSDIR%%/api.html -%%PORTDOCS%%%%DOCSDIR%%/api_callback.html -%%PORTDOCS%%%%DOCSDIR%%/api_full.html -%%PORTDOCS%%%%DOCSDIR%%/api_misc.html -%%PORTDOCS%%%%DOCSDIR%%/api_simple.html -%%PORTDOCS%%%%DOCSDIR%%/download.html -%%PORTDOCS%%%%DOCSDIR%%/faq.html -%%PORTDOCS%%%%DOCSDIR%%/history.html -%%PORTDOCS%%%%DOCSDIR%%/index.html -%%PORTDOCS%%%%DOCSDIR%%/license.html -%%PORTDOCS%%%%DOCSDIR%%/lists.html -%%PORTDOCS%%%%DOCSDIR%%/quality.html -%%PORTDOCS%%%%DOCSDIR%%/win32.html +%%PORTDOCS%%%%DOCSDIR%%/api.md +%%PORTDOCS%%%%DOCSDIR%%/api_callback.md +%%PORTDOCS%%%%DOCSDIR%%/api_full.md +%%PORTDOCS%%%%DOCSDIR%%/api_misc.md +%%PORTDOCS%%%%DOCSDIR%%/api_simple.md +%%PORTDOCS%%%%DOCSDIR%%/bugs.md +%%PORTDOCS%%%%DOCSDIR%%/download.md +%%PORTDOCS%%%%DOCSDIR%%/faq.md +%%PORTDOCS%%%%DOCSDIR%%/history.md +%%PORTDOCS%%%%DOCSDIR%%/index.md +%%PORTDOCS%%%%DOCSDIR%%/license.md +%%PORTDOCS%%%%DOCSDIR%%/lists.md +%%PORTDOCS%%%%DOCSDIR%%/quality.md +%%PORTDOCS%%%%DOCSDIR%%/win32.md