From 4edbc9349476e1c36b650f2b7cd8a7329e6bdf24 Mon Sep 17 00:00:00 2001 From: Brad Hards Date: Sun, 8 Oct 2006 06:28:19 +0000 Subject: [PATCH] Change the taglib build system to use relative include paths. This allows you to build taglib either as part of kdesupport (i.e. with a source directory of kdesupport/) or by itself (i.e. with a source directory of kdesupport/taglib/). git-svn-id: svn://anonsvn.kde.org/home/kde/trunk/kdesupport/taglib@593544 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- bindings/c/CMakeLists.txt | 18 +++++++++--------- examples/CMakeLists.txt | 7 ++++++- tests/CMakeLists.txt | 4 +++- 3 files changed, 18 insertions(+), 11 deletions(-) diff --git a/bindings/c/CMakeLists.txt b/bindings/c/CMakeLists.txt index 2f834d1f..5f08c65a 100644 --- a/bindings/c/CMakeLists.txt +++ b/bindings/c/CMakeLists.txt @@ -1,12 +1,12 @@ -INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR}/taglib/taglib - ${CMAKE_SOURCE_DIR}/taglib/taglib/toolkit - ${CMAKE_SOURCE_DIR}/taglib/taglib/mpeg - ${CMAKE_SOURCE_DIR}/taglib/taglib/ogg - ${CMAKE_SOURCE_DIR}/taglib/taglib/ogg/vorbis - ${CMAKE_SOURCE_DIR}/taglib/taglib/ogg/flac - ${CMAKE_SOURCE_DIR}/taglib/taglib/flac - ${CMAKE_SOURCE_DIR}/taglib/taglib/mpc - ${CMAKE_SOURCE_DIR}/taglib/taglib/mpeg/id3v2 ) +INCLUDE_DIRECTORIES( ${CMAKE_CURRENT_SOURCE_DIR}/../../taglib + ${CMAKE_CURRENT_SOURCE_DIR}/../../taglib/toolkit + ${CMAKE_CURRENT_SOURCE_DIR}/../../taglib/mpeg + ${CMAKE_CURRENT_SOURCE_DIR}/../../taglib/ogg + ${CMAKE_CURRENT_SOURCE_DIR}/../../taglib/ogg/vorbis + ${CMAKE_CURRENT_SOURCE_DIR}/../../taglib/ogg/flac + ${CMAKE_CURRENT_SOURCE_DIR}/../../taglib/flac + ${CMAKE_CURRENT_SOURCE_DIR}/../../taglib/mpc + ${CMAKE_CURRENT_SOURCE_DIR}/../../taglib/mpeg/id3v2 ) configure_file(${CMAKE_CURRENT_SOURCE_DIR}/taglib_c.pc.cmake ${CMAKE_CURRENT_BINARY_DIR}/taglib_c.pc ) diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt index 78dcda50..2abd51d8 100644 --- a/examples/CMakeLists.txt +++ b/examples/CMakeLists.txt @@ -1,5 +1,10 @@ if(BUILD_TESTS) -INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR}/taglib ${CMAKE_SOURCE_DIR}/taglib/toolkit ${CMAKE_SOURCE_DIR}/taglib/mpeg ${CMAKE_SOURCE_DIR}/taglib/mpeg/id3v1 ${CMAKE_SOURCE_DIR}/taglib/mpeg/id3v2 ${CMAKE_SOURCE_DIR}/bindings/c/ ) +INCLUDE_DIRECTORIES( ${CMAKE_CURRENT_SOURCE_DIR}/../taglib + ${CMAKE_CURRENT_SOURCE_DIR}/../taglib/toolkit + ${CMAKE_CURRENT_SOURCE_DIR}/../taglib/mpeg + ${CMAKE_CURRENT_SOURCE_DIR}/../taglib/mpeg/id3v1 + ${CMAKE_CURRENT_SOURCE_DIR}/../taglib/mpeg/id3v2 + ${CMAKE_CURRENT_SOURCE_DIR}/../bindings/c/ ) ########### next target ############### diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 8c323cf1..8ce01c8c 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -1,5 +1,7 @@ if(BUILD_TESTS) -INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR}/taglib ${CMAKE_SOURCE_DIR}/taglib/toolkit ${CMAKE_SOURCE_DIR}/taglib/mpeg/id3v2 ) +INCLUDE_DIRECTORIES( ${CMAKE_CURRENT_SOURCE_DIR}/../taglib + ${CMAKE_CURRENT_SOURCE_DIR}/../taglib/toolkit + ${CMAKE_CURRENT_SOURCE_DIR}/../taglib/mpeg/id3v2 ) ########### next target ###############