Description: Use the system copy of freetype Author: James Cowgill --- This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -218,18 +218,18 @@ SET(QT_USE_QTHELP TRUE) ## freetype2 >= 2.5.2 ## -##if (APPLE) -## PKGCONFIG1 (freetype2 2.5.2 FREETYPE_INCLUDE_DIRS FREETYPE_LIBDIR FREETYPE_LIBRARIES FREETYPE_CPP) -## if (FREETYPE_INCLUDE_DIRS) -## STRING(REGEX REPLACE "\"" "" FREETYPE_INCLUDE_DIRS ${FREETYPE_INCLUDE_DIRS}) -## STRING(REGEX REPLACE "\"" "" FREETYPE_LIBDIR ${FREETYPE_LIBDIR}) -## message("freetype2 detected ${FREETYPE_INCLUDE_DIRS} ${FREETYPE_LIBDIR} ${FREETYPE_LIBRARIES}") -## else (FREETYPE_INCLUDE_DIRS) -## message(FATAL_ERROR "freetype >= 2.5.2 is required\n") -## endif (FREETYPE_INCLUDE_DIRS) -##else (APPLE) -## find_package(Freetype REQUIRED) -##endif (APPLE) +if (APPLE) + PKGCONFIG1 (freetype2 2.5.2 FREETYPE_INCLUDE_DIRS FREETYPE_LIBDIR FREETYPE_LIBRARIES FREETYPE_CPP) + if (FREETYPE_INCLUDE_DIRS) + STRING(REGEX REPLACE "\"" "" FREETYPE_INCLUDE_DIRS ${FREETYPE_INCLUDE_DIRS}) + STRING(REGEX REPLACE "\"" "" FREETYPE_LIBDIR ${FREETYPE_LIBDIR}) + message("freetype2 detected ${FREETYPE_INCLUDE_DIRS} ${FREETYPE_LIBDIR} ${FREETYPE_LIBRARIES}") + else (FREETYPE_INCLUDE_DIRS) + message(FATAL_ERROR "freetype >= 2.5.2 is required\n") + endif (FREETYPE_INCLUDE_DIRS) +else (APPLE) + find_package(Freetype REQUIRED) +endif (APPLE) ## ## alsa >= 1.0.0 @@ -606,7 +606,6 @@ if (OSC) subdirs (thirdparty/ofqf) endif (OSC) -subdirs (thirdparty/freetype) ## @@ -622,8 +621,7 @@ include_directories( ${VORBIS_INCDIR} ${SNDFILE_INCDIR} ${LAME_INCLUDE_DIR} -# ${FREETYPE_INCLUDE_DIRS} - ${PROJECT_SOURCE_DIR}/thirdparty/freetype/include + ${FREETYPE_INCLUDE_DIRS} ) ## --- a/mscore/CMakeLists.txt +++ b/mscore/CMakeLists.txt @@ -385,7 +385,7 @@ if (MINGW) portaudio portmidi winmm - mscore_freetype + freetype z ) @@ -477,7 +477,7 @@ else (MINGW) target_link_libraries(mscore ${ALSA_LIB} ${QT_LIBRARIES} - mscore_freetype + freetype z dl pthread --- a/mtest/CMakeLists.txt +++ b/mtest/CMakeLists.txt @@ -17,7 +17,6 @@ enable_testing() include_directories( ${PROJECT_BINARY_DIR} ${PROJECT_SOURCE_DIR} - ${PROJECT_SOURCE_DIR}/thirdparty/freetype/include ) if (OMR) @@ -108,7 +107,7 @@ add_executable( target_link_libraries( mtest ${QT_LIBRARIES} - mscore_freetype + freetype ) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${Qt5Widgets_EXECUTABLE_COMPILE_FLAGS}")