aboutsummaryrefslogtreecommitdiff
path: root/ports/speexdsp
diff options
context:
space:
mode:
authorStefano Sinigardi <stesinigardi@hotmail.com>2019-10-07 19:35:13 +0200
committerCurtis J Bezault <curtbezault@gmail.com>2019-10-07 10:35:13 -0700
commit726c11148105a97aef39bec024fdb7c140b1b154 (patch)
tree26bd2aee0c13a8351b259cc4ffffaf0efededb4e /ports/speexdsp
parente86ff2cc54bda9e9ee322ab69141e7113d5c40a9 (diff)
downloadvcpkg-726c11148105a97aef39bec024fdb7c140b1b154.tar.gz
vcpkg-726c11148105a97aef39bec024fdb7c140b1b154.zip
[vcpkg] fatal_error when patch fails to apply (#8087)
vcpkg will now fail on failure to apply patches except when using `--head`.
Diffstat (limited to 'ports/speexdsp')
-rw-r--r--ports/speexdsp/CMakeLists.txt18
-rw-r--r--ports/speexdsp/CONTROL2
-rw-r--r--ports/speexdsp/portfile.cmake26
3 files changed, 23 insertions, 23 deletions
diff --git a/ports/speexdsp/CMakeLists.txt b/ports/speexdsp/CMakeLists.txt
index dd0edfe09..a1dec7f3b 100644
--- a/ports/speexdsp/CMakeLists.txt
+++ b/ports/speexdsp/CMakeLists.txt
@@ -1,17 +1,15 @@
-# CMAKE project for libspeexdsp
cmake_minimum_required(VERSION 3.1)
-option(SOURCE_PATH "Root directory.")
-option(USE_SSE "Use SSE")
+option(USE_SSE "Use SSE" ON)
project (libspeexdsp)
-file(GLOB_RECURSE LIBSPEEXDSP_SOURCES "${SOURCE_PATH}/libspeexdsp/*.c")
-list(FILTER LIBSPEEXDSP_SOURCES EXCLUDE REGEX "${SOURCE_PATH}/libspeexdsp/test.*\\.c")
-file(GLOB_RECURSE LIBSPEEXDSP_HEADERS "${SOURCE_PATH}/libspeexdsp/*.h")
-file(GLOB_RECURSE LIBSPEEXDSP_HEADERS_PUBLIC "${SOURCE_PATH}/include/**/*.h")
+file(GLOB_RECURSE LIBSPEEXDSP_SOURCES "${CMAKE_CURRENT_LIST_DIR}/libspeexdsp/*.c")
+list(FILTER LIBSPEEXDSP_SOURCES EXCLUDE REGEX "${CMAKE_CURRENT_LIST_DIR}/libspeexdsp/test.*\\.c")
+file(GLOB_RECURSE LIBSPEEXDSP_HEADERS "${CMAKE_CURRENT_LIST_DIR}/libspeexdsp/*.h")
+file(GLOB_RECURSE LIBSPEEXDSP_HEADERS_PUBLIC "${CMAKE_CURRENT_LIST_DIR}/include/**/*.h")
if (BUILD_SHARED_LIBS)
add_definitions(-D_WINDOWS -D_USRDLL)
- list(APPEND LIBSPEEXDSP_SOURCES "${SOURCE_PATH}/win32/libspeexdsp.def")
+ list(APPEND LIBSPEEXDSP_SOURCES "${CMAKE_CURRENT_LIST_DIR}/win32/libspeexdsp.def")
else ()
add_definitions(-D_LIB)
endif ()
@@ -22,8 +20,8 @@ if (USE_SSE)
add_definitions(-D_USE_SSE -D_USE_SSE2)
endif()
-include_directories("${SOURCE_PATH}/include"
- "${SOURCE_PATH}/win32")
+include_directories("${CMAKE_CURRENT_LIST_DIR}/include"
+ "${CMAKE_CURRENT_LIST_DIR}/win32")
add_library(libspeexdsp ${LIBSPEEXDSP_SOURCES} ${LIBSPEEXDSP_HEADERS})
set_target_properties(libspeexdsp PROPERTIES PUBLIC_HEADER "${LIBSPEEXDSP_HEADERS_PUBLIC}")
diff --git a/ports/speexdsp/CONTROL b/ports/speexdsp/CONTROL
index ce181ae58..749633995 100644
--- a/ports/speexdsp/CONTROL
+++ b/ports/speexdsp/CONTROL
@@ -1,5 +1,5 @@
Source: speexdsp
-Version: 1.2.0
+Version: 1.2.0-1
Homepage: https://ftp.osuosl.org/pub/xiph/releases/speex/
Description: A patent-free, Open Source/Free Software DSP library.
Build-Depends:
diff --git a/ports/speexdsp/portfile.cmake b/ports/speexdsp/portfile.cmake
index 44d340d1e..4e4bc5742 100644
--- a/ports/speexdsp/portfile.cmake
+++ b/ports/speexdsp/portfile.cmake
@@ -1,31 +1,33 @@
include(vcpkg_common_functions)
-set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/speexdsp-1.2.0)
-set(CMAKE_PATH ${CMAKE_CURRENT_LIST_DIR})
-vcpkg_download_distfile(ARCHIVE_FILE
+
+vcpkg_download_distfile(ARCHIVE
URLS "http://downloads.xiph.org/releases/speex/speexdsp-1.2.0.tar.gz"
FILENAME "speexdsp-1.2.0.tar.gz"
SHA512 e357cd5377415ea66c862302c7cf8bf6a10063cacd903f0846478975b87974cf5bdf00e2c6759d8f4f453c4c869cf284e9dc948a84a83d7b2ab96bd5405c05ec
)
-vcpkg_extract_source_archive(${ARCHIVE_FILE})
+
+vcpkg_extract_source_archive_ex(
+ OUT_SOURCE_PATH SOURCE_PATH
+ ARCHIVE ${ARCHIVE}
+)
+
+file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
set(USE_SSE OFF)
-set(USE_NEON OFF)
if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x64" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "x86")
set(USE_SSE ON)
endif()
vcpkg_configure_cmake(
- SOURCE_PATH ${CMAKE_PATH}
+ SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
- OPTIONS -DSOURCE_PATH=${SOURCE_PATH} -DUSE_SSE=${USE_SSE}
+ OPTIONS
+ -DUSE_SSE=${USE_SSE}
)
vcpkg_install_cmake()
+vcpkg_copy_pdbs()
-# Remove debug include
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
-# Copy copright information
-file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/speexdsp" RENAME "copyright")
-
-vcpkg_copy_pdbs()
+file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME "copyright")