mirror of
https://github.com/pdf2htmlEX/pdf2htmlEX.git
synced 2024-10-05 19:41:40 +00:00
Merge branch 'master' into devv
This commit is contained in:
commit
d8d0bb026d
@ -8,8 +8,14 @@ pkg_check_modules(POPPLER REQUIRED poppler>=0.20.0)
|
|||||||
include_directories(${POPPLER_INCLUDE_DIRS})
|
include_directories(${POPPLER_INCLUDE_DIRS})
|
||||||
link_directories(${POPPLER_LIBRARY_DIRS})
|
link_directories(${POPPLER_LIBRARY_DIRS})
|
||||||
|
|
||||||
find_path(FF_INCLUDE_PATH fontforge/fontforge.h)
|
# fontforge starts using pkg-config 'correctly' since 2.0.0
|
||||||
if(FF_INCLUDE_PATH)
|
pkg_check_modules(FONTFORGE libfontforge>=2.0.0)
|
||||||
|
if(FONTFORGE_FOUND)
|
||||||
|
include_directories(${FONTFORGE_INCLUDE_DIRS})
|
||||||
|
link_directories(${FONTFORGE_LIBRARY_DIRS})
|
||||||
|
else()
|
||||||
|
find_path(FF_INCLUDE_PATH fontforge/fontforge.h)
|
||||||
|
if(FF_INCLUDE_PATH)
|
||||||
message("Found fontforge.h: ${FF_INCLUDE_PATH}/fontforge/fontforge.h")
|
message("Found fontforge.h: ${FF_INCLUDE_PATH}/fontforge/fontforge.h")
|
||||||
include_directories(${FF_INCLUDE_PATH}/fontforge)
|
include_directories(${FF_INCLUDE_PATH}/fontforge)
|
||||||
# MacOSX gettext is in /opt/local/include - strange
|
# MacOSX gettext is in /opt/local/include - strange
|
||||||
@ -22,35 +28,38 @@ if(FF_INCLUDE_PATH)
|
|||||||
set(NO_GETTEXT "YesPlease")
|
set(NO_GETTEXT "YesPlease")
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
message(FATAL_ERROR "Error: cannot locate fontforge.h")
|
message(FATAL_ERROR "Error: cannot locate fontforge.h")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
find_path(FF_CONFIG_INCLUDE_PATH fontforge/config.h)
|
find_path(FF_CONFIG_INCLUDE_PATH fontforge/config.h)
|
||||||
if(FF_CONFIG_INCLUDE_PATH)
|
if(FF_CONFIG_INCLUDE_PATH)
|
||||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -include ${FF_INCLUDE_PATH}/fontforge/config.h")
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -include ${FF_INCLUDE_PATH}/fontforge/config.h")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
foreach(FF_LIB_NAME
|
foreach(FF_LIB_NAME
|
||||||
${CMAKE_IMPORT_LIBRARY_PREFIX}fontforge${CMAKE_IMPORT_LIBRARY_SUFFIX}
|
${CMAKE_IMPORT_LIBRARY_PREFIX}fontforge${CMAKE_IMPORT_LIBRARY_SUFFIX}
|
||||||
${CMAKE_SHARED_LIBRARY_PREFIX}fontforge${CMAKE_SHARED_LIBRARY_SUFFIX}
|
${CMAKE_SHARED_LIBRARY_PREFIX}fontforge${CMAKE_SHARED_LIBRARY_SUFFIX}
|
||||||
${CMAKE_STATIC_LIBRARY_PREFIX}fontforge${CMAKE_STATIC_LIBRARY_SUFFIX}
|
${CMAKE_STATIC_LIBRARY_PREFIX}fontforge${CMAKE_STATIC_LIBRARY_SUFFIX}
|
||||||
)
|
)
|
||||||
find_library(FF_LIB ${FF_LIB_NAME})
|
find_library(FF_LIB ${FF_LIB_NAME})
|
||||||
if(FF_LIB)
|
if(FF_LIB)
|
||||||
message("Found ${FF_LIB_NAME}: ${FF_LIB}")
|
message("Found ${FF_LIB_NAME}: ${FF_LIB}")
|
||||||
set(FONTFORGE_LIBRARIES ${FF_LIB})
|
set(FONTFORGE_LIBRARIES ${FF_LIB})
|
||||||
break()
|
break()
|
||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
if(NOT FF_LIB)
|
if(NOT FF_LIB)
|
||||||
set(FONTFORGE_LIBRARIES fontforge)
|
set(FONTFORGE_LIBRARIES fontforge)
|
||||||
message("Error: cannot locate ${FF_LIB_NAME}")
|
message("Error: cannot locate ${FF_LIB_NAME}")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
message("Looking for libraries of python, which is required by fontforge, if you can link fontforge without python, you may disable this")
|
||||||
|
pkg_search_module(PYTHON python python-2.7)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
message("Looking for libraries of python, which is required by fontforge, if you can link fontforge without python, you may disable this")
|
|
||||||
pkg_search_module(PYTHON python python-2.7)
|
|
||||||
|
|
||||||
set(PDF2HTMLEX_VERSION "0.3")
|
set(PDF2HTMLEX_VERSION "0.3")
|
||||||
set(ARCHIVE_NAME pdf2htmlex-${PDF2HTMLEX_VERSION})
|
set(ARCHIVE_NAME pdf2htmlex-${PDF2HTMLEX_VERSION})
|
||||||
|
Loading…
Reference in New Issue
Block a user