Changeset b9156e9 in OpenModelica for OMCompiler/Parser/CMakeLists.txt


Ignore:
Timestamp:
2020-10-21T14:04:15+02:00 (4 years ago)
Author:
Mahder Gebremedhin <mahder.gebremedhin@…>
Children:
28fb3e1
Parents:
a44b408
git-author:
Mahder Gebremedhin <mahder.gebremedhin@…> (07/12/20 20:34:30)
git-committer:
Mahder Gebremedhin <mahder.gebremedhin@…> (10/21/20 14:04:15)
Message:

[cmake] Add CMake support for OMCompiler/runtime.

  • OMCompiler/runtime cannow be compiled using cmake.
    • Right now there is missing symbols from dgsev. I am not sure yet where to add them. Maybe dgsev can be added to simulationRuntime/c libraries. Other than that OMCompiler/runtime can be compiled with all symbols found at the moment.
  • We now use proper qualified names for libraries, e.g. omc::3rd::gc for the gc-lib in 3rdParty/gc. These names are added as aliases to the actual library. Use these everywhere. There should not be a single use of the actual library names.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • OMCompiler/Parser/CMakeLists.txt

    ra44b408 rb9156e9  
    44
    55find_package(Java REQUIRED Runtime)
    6 omc_add_to_report(Java_JAVA_EXECUTABLE)
     6# omc_add_to_report(Java_JAVA_EXECUTABLE)
     7find_package(Intl REQUIRED)
    78
    89
     
    3233
    3334######################### add libomparser ###########################
    34 add_library(omparse SHARED ${OM_PARSE_SOURCES})
    35 target_link_libraries(omparse PUBLIC omantlr3)
     35add_library(omparse STATIC ${OM_PARSE_SOURCES})
     36target_link_libraries(omparse PUBLIC Intl)
     37target_link_libraries(omparse PUBLIC omc::compiler::runtime)
     38target_link_libraries(omparse PUBLIC omc::3rd::omantlr3)
    3639target_link_libraries(omparse PUBLIC OpenModelicaRuntimeC)
    3740
    38 # # to find the generated antlr headers
    39 # # SYSTEM to disable warnings on the generated code.
    40 # target_include_directories(omparse SYSTEM PRIVATE ${GNERATED_DIRECTORY})
     41
    4142target_include_directories(omparse PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
    4243
     
    5051######################### add libomparser-boot ###########################
    5152add_library(omparse-boot STATIC ${OM_PARSE_SOURCES})
    52 target_link_libraries(omparse-boot PUBLIC omantlr3)
     53target_link_libraries(omparse-boot PUBLIC Intl)
     54target_link_libraries(omparse-boot PUBLIC omc::compiler::runtime)
     55target_link_libraries(omparse-boot PUBLIC omc::3rd::omantlr3)
    5356target_link_libraries(omparse-boot PUBLIC OpenModelicaRuntimeC)
    5457
Note: See TracChangeset for help on using the changeset viewer.