2012-01-23 04:33:36 +00:00
|
|
|
|
|
|
|
include_directories(BEFORE ${INC_BEFORE})
|
|
|
|
include_directories(
|
|
|
|
bitmaps
|
|
|
|
dialogs
|
|
|
|
transline
|
|
|
|
attenuators
|
|
|
|
../polygon
|
|
|
|
../common
|
|
|
|
${INC_AFTER}
|
|
|
|
)
|
2011-08-12 05:21:36 +00:00
|
|
|
|
|
|
|
set(PCB_CALCULATOR_SRCS
|
|
|
|
attenuators.cpp
|
|
|
|
board_classes_values.cpp
|
|
|
|
colorcode.cpp
|
|
|
|
electrical_spacing_values.cpp
|
|
|
|
params_read_write.cpp
|
|
|
|
pcb_calculator.cpp
|
|
|
|
pcb_calculator_frame.cpp
|
2012-04-02 18:11:00 +00:00
|
|
|
datafile_read_write.cpp
|
2011-08-12 05:21:36 +00:00
|
|
|
regulators_funct.cpp
|
|
|
|
tracks_width_versus_current.cpp
|
|
|
|
transline_ident.cpp
|
|
|
|
UnitSelector.cpp
|
2012-04-02 18:11:00 +00:00
|
|
|
pcb_calculator_datafile_keywords.cpp
|
2011-08-12 05:21:36 +00:00
|
|
|
transline/transline.cpp
|
|
|
|
transline/c_microstrip.cpp
|
|
|
|
transline/microstrip.cpp
|
|
|
|
transline/coplanar.cpp
|
|
|
|
transline/coax.cpp
|
|
|
|
transline/rectwaveguide.cpp
|
|
|
|
transline/stripline.cpp
|
|
|
|
transline/twistedpair.cpp
|
|
|
|
transline_dlg_funct.cpp
|
|
|
|
attenuators/attenuator_classes.cpp
|
|
|
|
dialogs/pcb_calculator_frame_base.cpp
|
2012-04-02 18:11:00 +00:00
|
|
|
dialogs/dialog_regulator_data_base.cpp
|
2011-08-12 05:21:36 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
if(WIN32)
|
|
|
|
if(MINGW)
|
|
|
|
# PCB_CALCULATOR_RESOURCES variable is set by the macro.
|
|
|
|
mingw_resource_compiler(pcb_calculator)
|
|
|
|
else(MINGW)
|
|
|
|
set(PCB_CALCULATOR_RESOURCES pcb_calculator.rc)
|
|
|
|
endif(MINGW)
|
|
|
|
endif(WIN32)
|
|
|
|
|
|
|
|
|
|
|
|
if(APPLE)
|
|
|
|
set(PCB_CALCULATOR_RESOURCES pcb_calculator.icns)
|
|
|
|
set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/pcb_calculator.icns"
|
|
|
|
PROPERTIES MACOSX_PACKAGE_LOCATION Resources)
|
|
|
|
set(MACOSX_BUNDLE_ICON_FILE pcb_calculator.icns)
|
|
|
|
set(MACOSX_BUNDLE_GUI_IDENTIFIER org.kicad-eda.pcb_calculator)
|
2011-12-07 21:06:02 +00:00
|
|
|
set(MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist)
|
2011-08-12 05:21:36 +00:00
|
|
|
endif(APPLE)
|
|
|
|
|
2012-04-02 18:11:00 +00:00
|
|
|
# auto-generate pcb_calculator_datafile.h and pcb_calculator_datafile_keywords.cpp
|
|
|
|
# for the storage data file format.
|
|
|
|
make_lexer(
|
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/pcb_calculator_datafile.keywords
|
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/pcb_calculator_datafile_lexer.h
|
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/pcb_calculator_datafile_keywords.cpp
|
|
|
|
PCBCALC_DATA_T
|
|
|
|
)
|
2011-08-12 05:21:36 +00:00
|
|
|
|
|
|
|
|
|
|
|
add_executable(pcb_calculator WIN32 MACOSX_BUNDLE
|
2012-01-27 15:40:04 +00:00
|
|
|
${PCB_CALCULATOR_SRCS}
|
|
|
|
${PCB_CALCULATOR_RESOURCES}
|
|
|
|
)
|
2011-08-12 05:21:36 +00:00
|
|
|
|
|
|
|
|
|
|
|
if(APPLE)
|
|
|
|
set_target_properties(pcb_calculator PROPERTIES MACOSX_BUNDLE_INFO_PLIST
|
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/Info.plist)
|
|
|
|
endif(APPLE)
|
|
|
|
|
2012-01-23 04:53:21 +00:00
|
|
|
target_link_libraries( pcb_calculator
|
2012-01-27 15:40:04 +00:00
|
|
|
common
|
|
|
|
bitmaps
|
|
|
|
polygon
|
2012-01-23 04:53:21 +00:00
|
|
|
${wxWidgets_LIBRARIES}
|
|
|
|
)
|
2011-08-12 05:21:36 +00:00
|
|
|
|
|
|
|
install(TARGETS pcb_calculator
|
|
|
|
DESTINATION ${KICAD_BIN}
|
|
|
|
COMPONENT binary)
|
|
|
|
|