2014-02-05 09:27:21 +00:00
|
|
|
include_directories(
|
2017-03-02 22:53:49 +00:00
|
|
|
"${CMAKE_SOURCE_DIR}/include"
|
2014-02-05 09:27:21 +00:00
|
|
|
"${CMAKE_SOURCE_DIR}/utils/idftools"
|
2014-12-16 20:47:47 +00:00
|
|
|
${OPENGL_INCLUDE_DIR}
|
2017-03-02 22:53:49 +00:00
|
|
|
)
|
2014-02-05 09:27:21 +00:00
|
|
|
|
2017-03-02 22:53:49 +00:00
|
|
|
set( IDF3_FILES
|
|
|
|
idf_helpers.cpp
|
|
|
|
idf_common.cpp
|
|
|
|
idf_outlines.cpp
|
|
|
|
idf_parser.cpp
|
|
|
|
vrml_layer.cpp
|
|
|
|
)
|
|
|
|
|
|
|
|
if( MINGW )
|
|
|
|
list( APPEND IDF3_FILES ${CMAKE_SOURCE_DIR}/common/streamwrapper.cpp )
|
|
|
|
endif( MINGW )
|
|
|
|
|
|
|
|
add_library( idf3 STATIC ${IDF3_FILES} )
|
2020-01-07 17:12:59 +00:00
|
|
|
target_link_libraries( idf3
|
|
|
|
kimath
|
2023-03-10 13:22:42 +00:00
|
|
|
Boost::headers
|
2020-01-07 17:12:59 +00:00
|
|
|
)
|
2014-02-05 09:27:21 +00:00
|
|
|
|
2014-05-28 06:26:46 +00:00
|
|
|
add_executable( idfcyl idf_cylinder.cpp )
|
2014-02-05 09:27:21 +00:00
|
|
|
add_executable( idfrect idf_rect.cpp )
|
2018-07-08 18:12:06 +00:00
|
|
|
add_executable( dxf2idf dxf2idfmain.cpp dxf2idf.cpp )
|
2014-05-28 06:26:46 +00:00
|
|
|
add_executable( idf2vrml idf2vrml.cpp )
|
2014-02-05 09:27:21 +00:00
|
|
|
|
2020-01-07 17:12:59 +00:00
|
|
|
target_link_libraries( dxf2idf
|
|
|
|
dxflib_qcad
|
|
|
|
idf3
|
|
|
|
kimath
|
2024-04-23 21:43:01 +00:00
|
|
|
common
|
2020-01-07 17:12:59 +00:00
|
|
|
${OPENGL_LIBRARIES}
|
|
|
|
${wxWidgets_LIBRARIES}
|
|
|
|
)
|
2014-05-28 06:26:46 +00:00
|
|
|
|
2020-01-07 17:12:59 +00:00
|
|
|
target_link_libraries( idf2vrml
|
|
|
|
idf3
|
|
|
|
kimath
|
2024-04-23 21:43:01 +00:00
|
|
|
common
|
2020-01-07 17:12:59 +00:00
|
|
|
${OPENGL_LIBRARIES}
|
|
|
|
${wxWidgets_LIBRARIES}
|
|
|
|
)
|
2014-02-05 09:27:21 +00:00
|
|
|
|
2022-01-31 23:57:56 +00:00
|
|
|
if( APPLE )
|
2014-10-02 23:03:52 +00:00
|
|
|
# puts binaries into the *.app bundle while linking
|
|
|
|
set_target_properties( idfcyl idfrect dxf2idf idf2vrml PROPERTIES
|
|
|
|
RUNTIME_OUTPUT_DIRECTORY ${OSX_BUNDLE_BUILD_BIN_DIR}
|
|
|
|
)
|
2023-09-20 13:52:25 +00:00
|
|
|
set_target_properties( idfcyl idfrect dxf2idf idf2vrml PROPERTIES INSTALL_RPATH
|
|
|
|
"@executable_path/../Frameworks" )
|
|
|
|
set_target_properties( idfcyl idfrect dxf2idf idf2vrml PROPERTIES BUILD_WITH_INSTALL_RPATH 1 )
|
2014-10-02 23:03:52 +00:00
|
|
|
else()
|
2018-07-07 11:04:01 +00:00
|
|
|
install( TARGETS idfcyl idfrect idf2vrml
|
2018-07-08 18:12:06 +00:00
|
|
|
dxf2idf
|
2014-10-02 23:03:52 +00:00
|
|
|
DESTINATION ${KICAD_BIN}
|
|
|
|
COMPONENT binary )
|
|
|
|
endif()
|