~s-cecilio/lenmus/trunk

« back to all changes in this revision

Viewing changes to lomse/trunk/build-options.cmake

  • Committer: Cecilio Salmeron
  • Date: 2016-02-04 10:15:44 UTC
  • Revision ID: s.cecilios@gmail.com-20160204101544-wdodav3eyyej64ga
Prepare for GitHub migration

Show diffs side-by-side

added added

removed removed

Lines of Context:
49
49
option(LOMSE_BUILD_EXAMPLE "Build the example-1 program" OFF)
50
50
 
51
51
 
52
 
message("Build the static library = ${LOMSE_BUILD_STATIC_LIB}")
53
 
message("Build the shared library = ${LOMSE_BUILD_SHARED_LIB}")
54
 
message("Build testlib program = ${LOMSE_BUILD_TESTS}")
55
 
message("Run tests after building = ${LOMSE_RUN_TESTS}")
56
 
message("Create Debug build = ${LOMSE_DEBUG}")
57
 
message("Enable debug logs = ${LOMSE_ENABLE_DEBUG_LOGS}")
58
 
message("Compatibility for LDP v1.5 = ${LOMSE_COMPATIBILITY_LDP_1_5}")
 
52
message(STATUS "** Build the static library = ${LOMSE_BUILD_STATIC_LIB}")
 
53
message(STATUS "** Build the shared library = ${LOMSE_BUILD_SHARED_LIB}")
 
54
message(STATUS "** Build testlib program = ${LOMSE_BUILD_TESTS}")
 
55
message(STATUS "** Run tests after building = ${LOMSE_RUN_TESTS}")
 
56
message(STATUS "** Create Debug build = ${LOMSE_DEBUG}")
 
57
message(STATUS "** Enable debug logs = ${LOMSE_ENABLE_DEBUG_LOGS}")
 
58
message(STATUS "** Compatibility for LDP v1.5 = ${LOMSE_COMPATIBILITY_LDP_1_5}")
59
59
 
60
60
 
61
61
 
77
77
#    set( LOMSE_CREATE_DLL "1")
78
78
#endif()
79
79
 
80
 
# version. Extract values from lomse_version.h header file
81
 
file(STRINGS ${LOMSE_ROOT_DIR}/include/lomse_version.h LOMSE_VERSION_LIST)
82
 
list (GET LOMSE_VERSION_LIST 5 MAJOR_LINE)
83
 
list (GET LOMSE_VERSION_LIST 6 MINOR_LINE)
84
 
list (GET LOMSE_VERSION_LIST 7 TYPE_LINE)
85
 
list (GET LOMSE_VERSION_LIST 8 PATCH_LINE)
86
 
list (GET LOMSE_VERSION_LIST 9 REVNO_LINE)
87
 
string(REGEX REPLACE "\#define LOMSE_VERSION_MAJOR    " "" LOMSE_VERSION_MAJOR "${MAJOR_LINE}")
88
 
string(REGEX REPLACE "\#define LOMSE_VERSION_MINOR    " "" LOMSE_VERSION_MINOR "${MINOR_LINE}")
89
 
string(REGEX REPLACE "\#define LOMSE_VERSION_TYPE     " "" LOMSE_VERSION_TYPE "${TYPE_LINE}")
90
 
string(REGEX REPLACE "\#define LOMSE_VERSION_PATCH    " "" LOMSE_VERSION_PATCH "${PATCH_LINE}")
91
 
string(REGEX REPLACE "\#define LOMSE_VERSION_REVNO    " "" LOMSE_REVISION "${REVNO_LINE}")
92
 
 
93
 
message ("major = '${LOMSE_VERSION_MAJOR}'") 
94
 
message ("minor = '${LOMSE_VERSION_MINOR}'") 
95
 
message ("type = '${LOMSE_VERSION_TYPE}'") 
96
 
message ("patch = '${LOMSE_VERSION_PATCH}'") 
97
 
message ("revision = '${LOMSE_REVISION}'") 
98
 
 
99
 
 
100
 
#build version string for installer name
101
 
set(LOMSE_VERSION_STRING "${LOMSE_VERSION_MAJOR}.${LOMSE_VERSION_MINOR}" )
102
 
if (NOT("${LOMSE_VERSION_TYPE}" STREQUAL ""))
103
 
    set(LTYPE "")
104
 
    if ("${LOMSE_VERSION_TYPE}" STREQUAL "'a'")
105
 
        set(LTYPE "a")
106
 
    elseif ("${LOMSE_VERSION_TYPE}" STREQUAL "'b'")
107
 
        set(LTYPE "b")
108
 
    endif()
109
 
    set(LOMSE_VERSION_STRING "${LOMSE_VERSION_STRING}.${LTYPE}${LOMSE_VERSION_PATCH}" )
110
 
else()
111
 
    if (NOT("${LOMSE_VERSION_PATCH}" STREQUAL "0"))
112
 
        set(LOMSE_VERSION_STRING "${LOMSE_VERSION_STRING}.${LOMSE_VERSION_PATCH}" )
113
 
    endif()
114
 
endif()
115
 
 
116
 
if (NOT("${LOMSE_REVISION}" STREQUAL ""))
117
 
    set(LOMSE_VERSION_STRING "${LOMSE_VERSION_STRING}-${LOMSE_REVISION}" )
118
 
endif()
119
 
 
120
 
set(LOMSE_VERSION "${LOMSE_VERSION_STRING}" )
121
 
message ("version = '${LOMSE_VERSION}'") 
122
 
message ("version string = '${LOMSE_VERSION_STRING}'") 
123
 
 
124
80
 
125
81
# platform
126
82
if(WIN32)