File: CMakeLists.txt

package info (click to toggle)
mapserver 6.4.1-5+deb8u3
  • links: PTS, VCS
  • area: main
  • in suites: jessie
  • size: 12,960 kB
  • ctags: 19,791
  • sloc: ansic: 119,501; cpp: 54,044; python: 3,055; xml: 1,676; cs: 875; lex: 741; yacc: 707; java: 588; perl: 428; makefile: 382; sh: 373; tcl: 158; ruby: 55
file content (25 lines) | stat: -rw-r--r-- 1,239 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
FIND_PACKAGE(SWIG REQUIRED)
INCLUDE(${SWIG_USE_FILE})
FIND_PACKAGE(Perl REQUIRED)
FIND_PACKAGE(PerlLibs REQUIRED)
set(CUSTOM_PERL_VENDOR_ARCH_DIR ${PERL_VENDORARCH} CACHE DIR "Custom installation directory for perl binary extension")
INCLUDE_DIRECTORIES(${PERL_INCLUDE_PATH})
include_directories(${PROJECT_SOURCE_DIR}/mapscript/swiginc)
include_directories(${PROJECT_SOURCE_DIR}/mapscript/)
add_definitions(${PERL_EXTRA_C_FLAGS})
SET(CMAKE_SWIG_FLAGS -shadow -w314)
include_directories(${PROJECT_SOURCE_DIR}/mapscript/perl)
SWIG_ADD_MODULE(perlmapscript perl5 ../mapscript.i)

SWIG_LINK_LIBRARIES(perlmapscript ${PERL_LIBRARIES} ${MAPSERVER_LIBMAPSERVER})
set_target_properties(perlmapscript PROPERTIES OUTPUT_NAME mapscript)
set_target_properties(perlmapscript PROPERTIES PREFIX "")
if(APPLE)
  set_target_properties(perlmapscript PROPERTIES SUFFIX ".bundle")
endif(APPLE)

get_target_property(LOC_MAPSCRIPT_LIB ${SWIG_MODULE_perlmapscript_REAL_NAME} LOCATION)
set(mapscript_files ${LOC_MAPSCRIPT_LIB} ${CMAKE_CURRENT_BINARY_DIR}/mapscript.pm)
install(FILES ${LOC_MAPSCRIPT_LIB} DESTINATION ${CUSTOM_PERL_VENDOR_ARCH_DIR}/auto/mapscript)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/mapscript.pm DESTINATION ${CUSTOM_PERL_VENDOR_ARCH_DIR})