/[pcre]/code/trunk/CMakeLists.txt
ViewVC logotype

Diff of /code/trunk/CMakeLists.txt

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1053 by zherczeg, Tue Oct 9 15:43:08 2012 UTC revision 1055 by chpe, Tue Oct 16 15:53:30 2012 UTC
# Line 58  Line 58 
58  #            of the configure.ac file  #            of the configure.ac file
59  # 2012-02-26 PH added support for libedit  # 2012-02-26 PH added support for libedit
60  # 2012-09-06 PH added support for PCRE_EBCDIC_NL25  # 2012-09-06 PH added support for PCRE_EBCDIC_NL25
61    # 2012-09-08 ChPe added PCRE32 support
62    
63  PROJECT(PCRE C CXX)  PROJECT(PCRE C CXX)
64    
# Line 113  OPTION(PCRE_BUILD_PCRE8 "Build 8 bit PCR Line 114  OPTION(PCRE_BUILD_PCRE8 "Build 8 bit PCR
114    
115  OPTION(PCRE_BUILD_PCRE16 "Build 16 bit PCRE library" OFF)  OPTION(PCRE_BUILD_PCRE16 "Build 16 bit PCRE library" OFF)
116    
117    OPTION(PCRE_BUILD_PCRE32 "Build 32 bit PCRE library" OFF)
118    
119  OPTION(PCRE_BUILD_PCRECPP "Build the PCRE C++ library (pcrecpp)." ON)  OPTION(PCRE_BUILD_PCRECPP "Build the PCRE C++ library (pcrecpp)." ON)
120    
121  SET(PCRE_EBCDIC OFF CACHE BOOL  SET(PCRE_EBCDIC OFF CACHE BOOL
# Line 149  SET(PCRE_SUPPORT_PCREGREP_JIT ON CACHE B Line 152  SET(PCRE_SUPPORT_PCREGREP_JIT ON CACHE B
152      "Enable use of Just-in-time compiling in pcregrep.")      "Enable use of Just-in-time compiling in pcregrep.")
153    
154  SET(PCRE_SUPPORT_UTF OFF CACHE BOOL  SET(PCRE_SUPPORT_UTF OFF CACHE BOOL
155      "Enable support for Unicode Transformation Format (UTF-8 and/or UTF-16) encoding.")      "Enable support for Unicode Transformation Format (UTF-8/UTF-16/UTF-32) encoding.")
156    
157  SET(PCRE_SUPPORT_UNICODE_PROPERTIES OFF CACHE BOOL  SET(PCRE_SUPPORT_UNICODE_PROPERTIES OFF CACHE BOOL
158      "Enable support for Unicode properties (if set, UTF support will be enabled as well).")      "Enable support for Unicode properties (if set, UTF support will be enabled as well).")
# Line 231  IF(NOT BUILD_SHARED_LIBS) Line 234  IF(NOT BUILD_SHARED_LIBS)
234          SET(PCRE_STATIC 1)          SET(PCRE_STATIC 1)
235  ENDIF(NOT BUILD_SHARED_LIBS)  ENDIF(NOT BUILD_SHARED_LIBS)
236    
237  IF(NOT PCRE_BUILD_PCRE8 AND NOT PCRE_BUILD_PCRE16)  IF(NOT PCRE_BUILD_PCRE8 AND NOT PCRE_BUILD_PCRE16 AND NOT PCRE_BUILD_PCRE32)
238          MESSAGE(FATAL_ERROR "Either PCRE_BUILD_PCRE8 or PCRE_BUILD_PCRE16 must be enabled")          MESSAGE(FATAL_ERROR "Either PCRE_BUILD_PCRE8, PCRE_BUILD_PCRE16 or PCRE_BUILD_PCRE32 must be enabled")
239  ENDIF(NOT PCRE_BUILD_PCRE8 AND NOT PCRE_BUILD_PCRE16)  ENDIF(NOT PCRE_BUILD_PCRE8 AND NOT PCRE_BUILD_PCRE16 AND NOT PCRE_BUILD_PCRE32)
240    
241  IF(PCRE_BUILD_PCRE8)  IF(PCRE_BUILD_PCRE8)
242          SET(SUPPORT_PCRE8 1)          SET(SUPPORT_PCRE8 1)
# Line 243  IF(PCRE_BUILD_PCRE16) Line 246  IF(PCRE_BUILD_PCRE16)
246          SET(SUPPORT_PCRE16 1)          SET(SUPPORT_PCRE16 1)
247  ENDIF(PCRE_BUILD_PCRE16)  ENDIF(PCRE_BUILD_PCRE16)
248    
249    IF(PCRE_BUILD_PCRE32)
250            SET(SUPPORT_PCRE32 1)
251    ENDIF(PCRE_BUILD_PCRE32)
252    
253  IF(PCRE_BUILD_PCRECPP AND NOT PCRE_BUILD_PCRE8)  IF(PCRE_BUILD_PCRECPP AND NOT PCRE_BUILD_PCRE8)
254          MESSAGE(STATUS "** PCRE_BUILD_PCRE8 must be enabled for the C++ library support")          MESSAGE(STATUS "** PCRE_BUILD_PCRE8 must be enabled for the C++ library support")
255          SET(PCRE_BUILD_PCRECPP OFF)          SET(PCRE_BUILD_PCRECPP OFF)
# Line 477  SET(PCRE16_SOURCES Line 484  SET(PCRE16_SOURCES
484  )  )
485  ENDIF(PCRE_BUILD_PCRE16)  ENDIF(PCRE_BUILD_PCRE16)
486    
487    IF(PCRE_BUILD_PCRE32)
488    SET(PCRE32_SOURCES
489      pcre32_byte_order.c
490      pcre32_chartables.c
491      pcre32_compile.c
492      pcre32_config.c
493      pcre32_dfa_exec.c
494      pcre32_exec.c
495      pcre32_fullinfo.c
496      pcre32_get.c
497      pcre32_globals.c
498      pcre32_jit_compile.c
499      pcre32_maketables.c
500      pcre32_newline.c
501      pcre32_ord2utf32.c
502      pcre32_refcount.c
503      pcre32_string_utils.c
504      pcre32_study.c
505      pcre32_tables.c
506      pcre32_ucd.c
507      pcre32_utf32_utils.c
508      pcre32_valid_utf32.c
509      pcre32_version.c
510      pcre32_xclass.c
511    )
512    ENDIF(PCRE_BUILD_PCRE32)
513    
514  IF(MINGW AND NOT PCRE_STATIC)  IF(MINGW AND NOT PCRE_STATIC)
515  IF (EXISTS ${PROJECT_SOURCE_DIR}/pcre.rc)  IF (EXISTS ${PROJECT_SOURCE_DIR}/pcre.rc)
516  ADD_CUSTOM_COMMAND(OUTPUT ${PROJECT_SOURCE_DIR}/pcre.o  ADD_CUSTOM_COMMAND(OUTPUT ${PROJECT_SOURCE_DIR}/pcre.o
# Line 575  ENDIF(MINGW AND NOT PCRE_STATIC) Line 609  ENDIF(MINGW AND NOT PCRE_STATIC)
609    
610  ENDIF(PCRE_BUILD_PCRE16)  ENDIF(PCRE_BUILD_PCRE16)
611    
612    IF(PCRE_BUILD_PCRE32)
613    ADD_LIBRARY(pcre32 ${PCRE_HEADERS} ${PCRE32_SOURCES} ${PROJECT_BINARY_DIR}/config.h)
614    SET(targets ${targets} pcre32)
615    
616    IF(MINGW AND NOT PCRE_STATIC)
617      IF(NON_STANDARD_LIB_PREFIX)
618        SET_TARGET_PROPERTIES(pcre32
619                            PROPERTIES PREFIX ""
620        )
621      ENDIF(NON_STANDARD_LIB_PREFIX)
622    
623      IF(NON_STANDARD_LIB_SUFFIX)
624        SET_TARGET_PROPERTIES(pcre32
625                            PROPERTIES SUFFIX "-0.dll"
626        )
627      ENDIF(NON_STANDARD_LIB_SUFFIX)
628    ENDIF(MINGW AND NOT PCRE_STATIC)
629    
630    ENDIF(PCRE_BUILD_PCRE32)
631    
632  # pcrecpp  # pcrecpp
633  IF(PCRE_BUILD_PCRECPP)  IF(PCRE_BUILD_PCRECPP)
634  ADD_LIBRARY(pcrecpp ${PCRECPP_HEADERS} ${PCRECPP_SOURCES})  ADD_LIBRARY(pcrecpp ${PCRECPP_HEADERS} ${PCRECPP_SOURCES})
# Line 625  IF(PCRE_BUILD_TESTS) Line 679  IF(PCRE_BUILD_TESTS)
679    IF(PCRE_BUILD_PCRE16)    IF(PCRE_BUILD_PCRE16)
680      LIST(APPEND PCRETEST_SOURCES pcre16_printint.c)      LIST(APPEND PCRETEST_SOURCES pcre16_printint.c)
681    ENDIF(PCRE_BUILD_PCRE16)    ENDIF(PCRE_BUILD_PCRE16)
682      IF(PCRE_BUILD_PCRE32)
683        LIST(APPEND PCRETEST_SOURCES pcre32_printint.c)
684      ENDIF(PCRE_BUILD_PCRE32)
685    
686    ADD_EXECUTABLE(pcretest ${PCRETEST_SOURCES})    ADD_EXECUTABLE(pcretest ${PCRETEST_SOURCES})
687    SET(targets ${targets} pcretest)    SET(targets ${targets} pcretest)
# Line 634  IF(PCRE_BUILD_TESTS) Line 691  IF(PCRE_BUILD_TESTS)
691    IF(PCRE_BUILD_PCRE16)    IF(PCRE_BUILD_PCRE16)
692      LIST(APPEND PCRETEST_LIBS pcre16)      LIST(APPEND PCRETEST_LIBS pcre16)
693    ENDIF(PCRE_BUILD_PCRE16)    ENDIF(PCRE_BUILD_PCRE16)
694      IF(PCRE_BUILD_PCRE32)
695        LIST(APPEND PCRETEST_LIBS pcre32)
696      ENDIF(PCRE_BUILD_PCRE32)
697    TARGET_LINK_LIBRARIES(pcretest ${PCRETEST_LIBS})    TARGET_LINK_LIBRARIES(pcretest ${PCRETEST_LIBS})
698    
699    IF(PCRE_SUPPORT_JIT)    IF(PCRE_SUPPORT_JIT)
# Line 646  IF(PCRE_BUILD_TESTS) Line 706  IF(PCRE_BUILD_TESTS)
706      IF(PCRE_BUILD_PCRE16)      IF(PCRE_BUILD_PCRE16)
707        LIST(APPEND PCRE_JIT_TEST_LIBS pcre16)        LIST(APPEND PCRE_JIT_TEST_LIBS pcre16)
708      ENDIF(PCRE_BUILD_PCRE16)      ENDIF(PCRE_BUILD_PCRE16)
709        IF(PCRE_BUILD_PCRE32)
710          LIST(APPEND PCRE_JIT_TEST_LIBS pcre32)
711        ENDIF(PCRE_BUILD_PCRE32)
712      TARGET_LINK_LIBRARIES(pcre_jit_test ${PCRE_JIT_TEST_LIBS})      TARGET_LINK_LIBRARIES(pcre_jit_test ${PCRE_JIT_TEST_LIBS})
713    ENDIF(PCRE_SUPPORT_JIT)    ENDIF(PCRE_SUPPORT_JIT)
714    
# Line 823  IF(PCRE_SHOW_REPORT) Line 886  IF(PCRE_SHOW_REPORT)
886    MESSAGE(STATUS "")    MESSAGE(STATUS "")
887    MESSAGE(STATUS "  Build 8 bit PCRE library ........ : ${PCRE_BUILD_PCRE8}")    MESSAGE(STATUS "  Build 8 bit PCRE library ........ : ${PCRE_BUILD_PCRE8}")
888    MESSAGE(STATUS "  Build 16 bit PCRE library ....... : ${PCRE_BUILD_PCRE16}")    MESSAGE(STATUS "  Build 16 bit PCRE library ....... : ${PCRE_BUILD_PCRE16}")
889      MESSAGE(STATUS "  Build 32 bit PCRE library ....... : ${PCRE_BUILD_PCRE32}")
890    MESSAGE(STATUS "  Build C++ library ............... : ${PCRE_BUILD_PCRECPP}")    MESSAGE(STATUS "  Build C++ library ............... : ${PCRE_BUILD_PCRECPP}")
891    MESSAGE(STATUS "  Enable JIT compiling support .... : ${PCRE_SUPPORT_JIT}")    MESSAGE(STATUS "  Enable JIT compiling support .... : ${PCRE_SUPPORT_JIT}")
892    MESSAGE(STATUS "  Enable UTF support .............. : ${PCRE_SUPPORT_UTF}")    MESSAGE(STATUS "  Enable UTF support .............. : ${PCRE_SUPPORT_UTF}")

Legend:
Removed from v.1053  
changed lines
  Added in v.1055

  ViewVC Help
Powered by ViewVC 1.1.5