mirror of
https://github.com/cookiengineer/audacity
synced 2025-10-11 09:03:36 +02:00
Updates the cmake build system
It's still has some work, but it successfully builds on all 3 main platforms. Some of the outstanding items include: Install target testing (mostly important for Linux) CMakeList clean up and comments Debug and Release build verification Audit of compile/link options Need a Mac signed and notarized build (and probably more)
This commit is contained in:
@@ -1,71 +1,58 @@
|
||||
#directory cmake-proxies/libvorbis
|
||||
set( TARGET libvorbis )
|
||||
set( TARGET_SOURCE ${LIB_SRC_DIRECTORY}${TARGET} )
|
||||
project( ${TARGET} )
|
||||
|
||||
set( SOURCES
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/examples/chaining_example.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/examples/decoder_example.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/examples/encoder_example.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/examples/seeking_example.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/examples/vorbisfile_example.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/analysis.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/lib/barkmel.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/bitrate.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/block.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/codebook.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/envelope.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/floor0.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/floor1.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/info.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/lookup.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/lpc.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/lsp.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/mapping0.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/mdct.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/psy.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/lib/psytune.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/registry.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/res0.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/sharedbook.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/smallft.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/synthesis.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/lib/tone.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/vorbisenc.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/vorbisfile.c
|
||||
${LIB_SRC_DIRECTORY}libvorbis/lib/window.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/macos/compat/strdup.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/test/test.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/test/util.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/test/write_read.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/bookutil.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/build.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/cascade.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/distribution.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/genericdata.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/huffbuild.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/latticebuild.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/latticehint.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/latticepare.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/latticetune.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/lspdata.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/metrics.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/residuedata.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/residuesplit.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/run.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/train.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/vqgen.c
|
||||
#${LIB_SRC_DIRECTORY}libvorbis/vq/vqsplit.c
|
||||
)
|
||||
# This defines the #define on both Windows and Linux.
|
||||
add_definitions(
|
||||
-D_LIB
|
||||
)
|
||||
add_library( ${TARGET} STATIC ${SOURCES})
|
||||
add_library( ${TARGET} STATIC )
|
||||
|
||||
target_include_directories( ${TARGET} PRIVATE
|
||||
${TARGET_SOURCE}/include
|
||||
${LIB_SRC_DIRECTORY}/libogg/include
|
||||
list( APPEND SOURCES
|
||||
PRIVATE
|
||||
${TARGET_ROOT}/lib/analysis.c
|
||||
${TARGET_ROOT}/lib/bitrate.c
|
||||
${TARGET_ROOT}/lib/block.c
|
||||
${TARGET_ROOT}/lib/codebook.c
|
||||
${TARGET_ROOT}/lib/envelope.c
|
||||
${TARGET_ROOT}/lib/floor0.c
|
||||
${TARGET_ROOT}/lib/floor1.c
|
||||
${TARGET_ROOT}/lib/info.c
|
||||
${TARGET_ROOT}/lib/lookup.c
|
||||
${TARGET_ROOT}/lib/lpc.c
|
||||
${TARGET_ROOT}/lib/lsp.c
|
||||
${TARGET_ROOT}/lib/mapping0.c
|
||||
${TARGET_ROOT}/lib/mdct.c
|
||||
${TARGET_ROOT}/lib/psy.c
|
||||
${TARGET_ROOT}/lib/registry.c
|
||||
${TARGET_ROOT}/lib/res0.c
|
||||
${TARGET_ROOT}/lib/sharedbook.c
|
||||
${TARGET_ROOT}/lib/smallft.c
|
||||
${TARGET_ROOT}/lib/synthesis.c
|
||||
${TARGET_ROOT}/lib/vorbisenc.c
|
||||
${TARGET_ROOT}/lib/vorbisfile.c
|
||||
${TARGET_ROOT}/lib/window.c
|
||||
)
|
||||
|
||||
target_link_libraries( ${TARGET} )
|
||||
list( APPEND INCLUDES
|
||||
PRIVATE
|
||||
${CMAKE_CURRENT_BINARY_DIR}/private
|
||||
${TARGET_ROOT}/lib
|
||||
${LIBOGG_INCLUDES}
|
||||
PUBLIC
|
||||
${TARGET_ROOT}/include
|
||||
)
|
||||
|
||||
list( APPEND DEFINES
|
||||
PRIVATE
|
||||
HAVE_CONFIG_H
|
||||
)
|
||||
|
||||
list( APPEND LIBRARIES
|
||||
PRIVATE
|
||||
libogg
|
||||
)
|
||||
|
||||
configure_file( config.h.in private/config.h )
|
||||
|
||||
organize_source( "${TARGET_ROOT}" "" "${SOURCES}" )
|
||||
target_sources( ${TARGET} PRIVATE ${SOURCES} )
|
||||
target_compile_definitions( ${TARGET} PRIVATE ${DEFINES} )
|
||||
target_compile_features( ${TARGET} PRIVATE ${FEATURES} )
|
||||
target_compile_options( ${TARGET} PRIVATE ${OPTIONS} )
|
||||
target_include_directories( ${TARGET} PRIVATE ${INCLUDES} )
|
||||
target_link_libraries( ${TARGET} PRIVATE ${LIBRARIES} )
|
||||
|
||||
|
94
cmake-proxies/libvorbis/config.h.in
Normal file
94
cmake-proxies/libvorbis/config.h.in
Normal file
@@ -0,0 +1,94 @@
|
||||
/* config.h.in. Generated from configure.ac by autoheader. */
|
||||
|
||||
/* Define to one of `_getb67', `GETB67', `getb67' for Cray-2 and Cray-YMP
|
||||
systems. This function is required for `alloca.c' support on those systems.
|
||||
*/
|
||||
#cmakedefine CRAY_STACKSEG_END 1
|
||||
|
||||
/* Define to 1 if using `alloca.c'. */
|
||||
#cmakedefine C_ALLOCA 1
|
||||
|
||||
/* Define to 1 if you have `alloca', as a function or macro. */
|
||||
#cmakedefine HAVE_ALLOCA 1
|
||||
|
||||
/* Define to 1 if you have <alloca.h> and it should be used (not on Ultrix).
|
||||
*/
|
||||
#cmakedefine HAVE_ALLOCA_H 1
|
||||
|
||||
/* Define to 1 if you have the <dlfcn.h> header file. */
|
||||
#cmakedefine HAVE_DLFCN_H 1
|
||||
|
||||
/* Define to 1 if you have the <inttypes.h> header file. */
|
||||
#cmakedefine HAVE_INTTYPES_H 1
|
||||
|
||||
/* Define to 1 if you have the <memory.h> header file. */
|
||||
#cmakedefine HAVE_MEMORY_H 1
|
||||
|
||||
/* Define to 1 if you have the <stdint.h> header file. */
|
||||
#cmakedefine HAVE_STDINT_H 1
|
||||
|
||||
/* Define to 1 if you have the <stdlib.h> header file. */
|
||||
#cmakedefine HAVE_STDLIB_H 1
|
||||
|
||||
/* Define to 1 if you have the <strings.h> header file. */
|
||||
#cmakedefine HAVE_STRINGS_H 1
|
||||
|
||||
/* Define to 1 if you have the <string.h> header file. */
|
||||
#cmakedefine HAVE_STRING_H 1
|
||||
|
||||
/* Define to 1 if you have the <sys/stat.h> header file. */
|
||||
#cmakedefine HAVE_SYS_STAT_H 1
|
||||
|
||||
/* Define to 1 if you have the <sys/types.h> header file. */
|
||||
#cmakedefine HAVE_SYS_TYPES_H 1
|
||||
|
||||
/* Define to 1 if you have the <unistd.h> header file. */
|
||||
#cmakedefine HAVE_UNISTD_H 1
|
||||
|
||||
/* Define to the sub-directory in which libtool stores uninstalled libraries.
|
||||
*/
|
||||
#cmakedefine LT_OBJDIR "@LT_OBDIR@"
|
||||
|
||||
/* Name of package */
|
||||
#cmakedefine PACKAGE "@PACKAGE@"
|
||||
|
||||
/* Define to the address where bug reports for this package should be sent. */
|
||||
#cmakedefine PACKAGE_BUGREPORT "@PACKAGE_BUGREPORT@"
|
||||
|
||||
/* Define to the full name of this package. */
|
||||
#cmakedefine PACKAGE_NAME "@PACKAGE_NAME@"
|
||||
|
||||
/* Define to the full name and version of this package. */
|
||||
#cmakedefine PACKAGE_STRING "@PACKAGE_STRING@"
|
||||
|
||||
/* Define to the one symbol short name of this package. */
|
||||
#cmakedefine PACKAGE_TARNAME "@PACKAGE_TARNAME@"
|
||||
|
||||
/* Define to the home page for this package. */
|
||||
#cmakedefine PACKAGE_URL "@PACKAGE_URL@"
|
||||
|
||||
/* Define to the version of this package. */
|
||||
#cmakedefine PACKAGE_VERSION "@PACKAGE_VERSION@"
|
||||
|
||||
/* If using the C implementation of alloca, define if you know the
|
||||
direction of stack growth for your system; otherwise it will be
|
||||
automatically deduced at runtime.
|
||||
STACK_DIRECTION > 0 => grows toward higher addresses
|
||||
STACK_DIRECTION < 0 => grows toward lower addresses
|
||||
STACK_DIRECTION = 0 => direction of growth unknown */
|
||||
#cmakedefine STACK_DIRECTION 1
|
||||
|
||||
/* Define to 1 if you have the ANSI C header files. */
|
||||
#cmakedefine STDC_HEADERS 1
|
||||
|
||||
/* Version number of package */
|
||||
#cmakedefine VERSION "@VERSION@"
|
||||
|
||||
/* Define to `__inline__' or `__inline' if that's what the C compiler
|
||||
calls it, or to nothing if 'inline' is not supported under any name. */
|
||||
#ifndef __cplusplus
|
||||
#cmakedefine inline @inline@
|
||||
#endif
|
||||
|
||||
/* Define to `unsigned int' if <sys/types.h> does not define. */
|
||||
#cmakedefine size_t @size_t@
|
Reference in New Issue
Block a user