]> gerrit.simantics Code Review - simantics/fmil.git/blob - org.simantics.fmil.core/native/FMILibrary/Config.cmake/fmicapi.cmake
Switch to full JavaSE-11+ compatibility
[simantics/fmil.git] / org.simantics.fmil.core / native / FMILibrary / Config.cmake / fmicapi.cmake
1 #    Copyright (C) 2012 Modelon AB
2
3 #    This program is free software: you can redistribute it and/or modify
4 #    it under the terms of the BSD style license.
5
6 # #    This program is distributed in the hope that it will be useful,
7 #    but WITHOUT ANY WARRANTY; without even the implied warranty of
8 #    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
9 #    FMILIB_License.txt file for more details.
10
11 #    You should have received a copy of the FMILIB_License.txt file
12 #    along with this program. If not, contact Modelon AB <http://www.modelon.com>.
13
14 if(NOT FMICAPIDIR)
15 set(FMICAPIDIR ${FMILIBRARYHOME}/src/CAPI)
16
17 # set(DOXYFILE_EXTRA_SOURCES "${DOXYFILE_EXTRA_SOURCES} \"${FMICAPIDIR}/include\"")
18
19 include(jmutil)
20
21 include_directories("${FMICAPIDIR}/include" "${FMICAPIDIR}/src")
22 set(FMICAPI_LIBRARIES fmicapi)
23
24 set(FMICAPISOURCE
25     src/FMI1/fmi1_capi_cs.c
26     src/FMI1/fmi1_capi_me.c
27     src/FMI1/fmi1_capi.c
28     src/FMI2/fmi2_capi_cs.c
29     src/FMI2/fmi2_capi_me.c
30     src/FMI2/fmi2_capi.c
31 )
32 set(FMICAPIHEADERS
33         include/FMI1/fmi1_capi.h        
34         src/FMI1/fmi1_capi_impl.h
35         include/FMI2/fmi2_capi.h        
36         src/FMI2/fmi2_capi_impl.h
37 )
38  
39 include_directories(${FMILIB_FMI_STANDARD_HEADERS})
40
41 PREFIXLIST(FMICAPISOURCE  ${FMICAPIDIR}/)
42 PREFIXLIST(FMICAPIHEADERS ${FMICAPIDIR}/)
43
44 add_library(fmicapi ${FMILIBKIND} ${FMICAPISOURCE} ${FMICAPIHEADERS})
45
46 target_link_libraries(fmicapi ${JMUTIL_LIBRARIES})
47
48 # install(DIRECTORY ${FMIXMLDIR}/include DESTINATION .)
49 # install(DIRECTORY ${FMICAPIDIR}/include DESTINATION .)
50 #install(DIRECTORY ${JMRUNTIMEHOME}/FMI/ZIP/include DESTINATION include)
51
52 endif(NOT FMICAPIDIR)