[flac] use nasm

This commit is contained in:
codicodi 2017-03-09 23:52:45 +01:00
parent 2054f964fd
commit c24afa97a2
3 changed files with 14 additions and 1 deletions

View File

@ -24,6 +24,13 @@ endif()
if(LIBFLAC_ARCHITECTURE MATCHES x86)
add_definitions(-DFLAC__CPU_IA32)
add_definitions(-DFLAC__HAS_NASM)
enable_language(ASM_NASM)
list(APPEND LIBFLAC_SOURCES
src/libFLAC/ia32/cpu_asm.nasm
src/libFLAC/ia32/fixed_asm.nasm
src/libFLAC/ia32/lpc_asm.nasm)
set(CMAKE_ASM_NASM_FLAGS "-i${PROJECT_SOURCE_DIR}/src/libFLAC/ia32/ -f win32 -d OBJ_FORMAT_win32")
elseif(LIBFLAC_ARCHITECTURE MATCHES x64)
add_definitions(-DFLAC__CPU_X86_64)
add_definitions(-DENABLE_64_BIT_WORDS)

View File

@ -1,4 +1,4 @@
Source: libflac
Version: 1.3.2
Version: 1.3.2-1
Description: Library for manipulating FLAC files
Build-Depends: libogg

View File

@ -12,6 +12,12 @@ vcpkg_download_distfile(ARCHIVE
vcpkg_extract_source_archive(${ARCHIVE})
if(VCPKG_TARGET_ARCHITECTURE STREQUAL x86)
vcpkg_find_acquire_program(NASM)
get_filename_component(NASM_EXE_PATH ${NASM} DIRECTORY)
set(ENV{PATH} "$ENV{PATH};${NASM_EXE_PATH}")
endif()
file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
vcpkg_configure_cmake(