2008-03-11 15:57:54 +00:00
|
|
|
add_definitions(-DPCBNEW)
|
2007-11-08 07:17:37 +00:00
|
|
|
|
2012-03-17 15:17:13 +00:00
|
|
|
if (KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES)
|
2012-03-17 17:30:03 +00:00
|
|
|
|
|
|
|
file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/scripting)
|
2012-03-17 15:17:13 +00:00
|
|
|
|
|
|
|
FIND_PACKAGE(SWIG REQUIRED)
|
|
|
|
INCLUDE(${SWIG_USE_FILE})
|
|
|
|
|
|
|
|
FIND_PACKAGE(PythonLibs)
|
|
|
|
INCLUDE_DIRECTORIES(${PYTHON_INCLUDE_PATH})
|
|
|
|
add_definitions(-DPCBNEW -DKICAD_SCRIPTING)
|
|
|
|
endif()
|
2012-02-28 21:30:46 +00:00
|
|
|
|
2010-05-16 18:18:38 +00:00
|
|
|
###
|
|
|
|
# Includes
|
|
|
|
###
|
2012-01-23 04:33:36 +00:00
|
|
|
include_directories(BEFORE ${INC_BEFORE})
|
|
|
|
include_directories(
|
|
|
|
./dialogs
|
|
|
|
../3d-viewer
|
|
|
|
../common
|
|
|
|
${Boost_INCLUDE_DIR}
|
|
|
|
../polygon
|
|
|
|
../common/dialogs
|
2012-03-10 21:40:41 +00:00
|
|
|
./scripting
|
2012-03-17 17:30:03 +00:00
|
|
|
../scripting
|
2012-01-23 04:33:36 +00:00
|
|
|
${INC_AFTER}
|
|
|
|
)
|
|
|
|
|
2007-11-08 07:17:37 +00:00
|
|
|
|
2010-05-16 18:18:38 +00:00
|
|
|
###
|
|
|
|
# Sources
|
|
|
|
#
|
2010-11-24 15:10:33 +00:00
|
|
|
set(PCBNEW_DIALOGS
|
2010-11-12 18:38:48 +00:00
|
|
|
dialogs/dialog_block_options_base.cpp
|
2010-11-21 18:28:32 +00:00
|
|
|
dialogs/dialog_cleaning_options_base.cpp
|
|
|
|
dialogs/dialog_cleaning_options.cpp
|
2010-11-24 20:37:00 +00:00
|
|
|
dialogs/dialog_copper_zones.cpp
|
|
|
|
dialogs/dialog_copper_zones_base.cpp
|
2010-11-26 20:00:39 +00:00
|
|
|
dialogs/dialog_design_rules.cpp
|
|
|
|
dialogs/dialog_design_rules_base.cpp
|
2011-11-24 19:57:41 +00:00
|
|
|
dialogs/dialog_dimension_editor_base.cpp
|
2010-11-24 20:37:00 +00:00
|
|
|
dialogs/dialog_display_options.cpp
|
|
|
|
dialogs/dialog_display_options_base.cpp
|
2010-11-26 17:47:35 +00:00
|
|
|
dialogs/dialog_drc_base.cpp
|
|
|
|
dialogs/dialog_drc.cpp
|
2010-11-26 11:55:34 +00:00
|
|
|
dialogs/dialog_edit_module_for_BoardEditor.cpp
|
|
|
|
dialogs/dialog_edit_module_for_BoardEditor_base.cpp
|
|
|
|
dialogs/dialog_edit_module_for_Modedit_base.cpp
|
|
|
|
dialogs/dialog_edit_module_for_Modedit.cpp
|
|
|
|
dialogs/dialog_edit_module_text.cpp
|
|
|
|
dialogs/dialog_edit_module_text_base.cpp
|
|
|
|
dialogs/dialog_exchange_modules_base.cpp
|
2010-11-24 20:37:00 +00:00
|
|
|
dialogs/dialog_export_3Dfiles_base.cpp
|
2010-11-29 15:05:01 +00:00
|
|
|
dialogs/dialog_freeroute_exchange.cpp
|
|
|
|
dialogs/dialog_freeroute_exchange_base.cpp
|
2010-11-24 15:10:33 +00:00
|
|
|
dialogs/dialog_gendrill.cpp
|
|
|
|
dialogs/dialog_gendrill_base.cpp
|
2012-02-15 10:41:16 +00:00
|
|
|
dialogs/dialog_gen_module_position_file_base.cpp
|
2010-11-26 17:47:35 +00:00
|
|
|
dialogs/dialog_general_options.cpp
|
|
|
|
dialogs/dialog_general_options_BoardEditor_base.cpp
|
|
|
|
dialogs/dialog_global_edit_tracks_and_vias.cpp
|
|
|
|
dialogs/dialog_global_edit_tracks_and_vias_base.cpp
|
|
|
|
dialogs/dialog_global_pads_edition_base.cpp
|
2010-11-26 11:55:34 +00:00
|
|
|
dialogs/dialog_graphic_items_options.cpp
|
|
|
|
dialogs/dialog_graphic_items_options_base.cpp
|
|
|
|
dialogs/dialog_graphic_item_properties.cpp
|
|
|
|
dialogs/dialog_graphic_item_properties_base.cpp
|
2012-02-12 19:39:37 +00:00
|
|
|
dialogs/dialog_graphic_item_properties_for_Modedit.cpp
|
2010-11-26 20:00:39 +00:00
|
|
|
dialogs/dialog_global_deletion.cpp
|
|
|
|
dialogs/dialog_global_deletion_base.cpp
|
|
|
|
dialogs/dialog_layers_setup.cpp
|
|
|
|
dialogs/dialog_layers_setup_base.cpp
|
2010-11-26 17:47:35 +00:00
|
|
|
dialogs/dialog_netlist.cpp
|
|
|
|
dialogs/dialog_netlist_fbp.cpp
|
|
|
|
dialogs/dialog_pcb_text_properties.cpp
|
2010-11-27 13:09:18 +00:00
|
|
|
dialogs/dialog_pcb_text_properties_base.cpp
|
2010-11-24 20:37:00 +00:00
|
|
|
dialogs/dialog_non_copper_zones_properties_base.cpp
|
|
|
|
dialogs/dialog_pad_properties.cpp
|
|
|
|
dialogs/dialog_pad_properties_base.cpp
|
|
|
|
dialogs/dialog_pcbnew_config_libs_and_paths.cpp
|
|
|
|
dialogs/dialog_pcbnew_config_libs_and_paths_fbp.cpp
|
|
|
|
dialogs/dialog_plot_base.cpp
|
|
|
|
dialogs/dialog_print_for_modedit.cpp
|
|
|
|
dialogs/dialog_print_for_modedit_base.cpp
|
|
|
|
dialogs/dialog_print_using_printer.cpp
|
|
|
|
dialogs/dialog_print_using_printer_base.cpp
|
2010-11-26 17:47:35 +00:00
|
|
|
dialogs/dialog_orient_footprints.cpp
|
|
|
|
dialogs/dialog_orient_footprints_base.cpp
|
2010-11-26 11:55:34 +00:00
|
|
|
dialogs/dialog_mask_clearance.cpp
|
|
|
|
dialogs/dialog_mask_clearance_base.cpp
|
2010-11-24 20:37:00 +00:00
|
|
|
dialogs/dialog_SVG_print.cpp
|
|
|
|
dialogs/dialog_SVG_print_base.cpp
|
|
|
|
dialogs/dialog_set_grid_base.cpp
|
2012-03-01 07:21:53 +00:00
|
|
|
dialogs/dialog_scripting_base.cpp
|
|
|
|
dialogs/dialog_scripting.cpp
|
2010-11-24 15:10:33 +00:00
|
|
|
)
|
|
|
|
|
2012-03-11 19:48:43 +00:00
|
|
|
set(PCBNEW_CLASS_SRCS
|
2012-02-09 20:33:38 +00:00
|
|
|
tool_modview.cpp
|
|
|
|
modview.cpp
|
|
|
|
modview_frame.cpp
|
2010-11-24 15:10:33 +00:00
|
|
|
pcbframe.cpp
|
|
|
|
attribut.cpp
|
|
|
|
automove.cpp
|
|
|
|
autoplac.cpp
|
|
|
|
autorout.cpp
|
|
|
|
board.cpp
|
|
|
|
board_items_to_polygon_shape_transform.cpp
|
|
|
|
board_undo_redo.cpp
|
|
|
|
block.cpp
|
|
|
|
block_module_editor.cpp
|
|
|
|
build_BOM_from_board.cpp
|
2011-07-06 16:40:54 +00:00
|
|
|
class_footprint_library.cpp
|
2010-11-24 15:10:33 +00:00
|
|
|
class_pcb_layer_widget.cpp
|
|
|
|
clean.cpp
|
|
|
|
connect.cpp
|
|
|
|
controle.cpp
|
|
|
|
dimension.cpp
|
|
|
|
cross-probing.cpp
|
|
|
|
deltrack.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
dist.cpp
|
|
|
|
dragsegm.cpp
|
|
|
|
drc.cpp
|
2010-09-20 16:21:47 +00:00
|
|
|
drc_clearance_test_functions.cpp
|
2010-09-18 17:55:08 +00:00
|
|
|
drc_marker_functions.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
edgemod.cpp
|
|
|
|
edit.cpp
|
|
|
|
editedge.cpp
|
|
|
|
editmod.cpp
|
|
|
|
editrack.cpp
|
|
|
|
editrack-part2.cpp
|
2009-06-21 13:37:27 +00:00
|
|
|
edit_pcb_text.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
edit_track_width.cpp
|
|
|
|
edtxtmod.cpp
|
2009-10-03 17:18:08 +00:00
|
|
|
event_handlers_tracks_vias_sizes.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
export_gencad.cpp
|
2010-04-19 06:21:56 +00:00
|
|
|
export_vrml.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
files.cpp
|
|
|
|
find.cpp
|
2008-01-18 17:09:39 +00:00
|
|
|
gen_drill_report_files.cpp
|
2008-02-08 00:16:59 +00:00
|
|
|
gen_holes_and_tools_lists_for_drill.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
gen_modules_placefile.cpp
|
|
|
|
gendrill.cpp
|
|
|
|
globaleditpad.cpp
|
2008-03-11 15:57:54 +00:00
|
|
|
gpcb_exchange.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
graphpcb.cpp
|
2011-10-17 20:01:27 +00:00
|
|
|
highlight.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
hotkeys.cpp
|
2010-11-24 15:10:33 +00:00
|
|
|
hotkeys_board_editor.cpp
|
|
|
|
hotkeys_module_editor.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
initpcb.cpp
|
|
|
|
ioascii.cpp
|
2010-01-21 07:41:30 +00:00
|
|
|
layer_widget.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
librairi.cpp
|
|
|
|
loadcmp.cpp
|
2009-10-10 17:27:53 +00:00
|
|
|
magnetic_tracks_functions.cpp
|
2010-01-17 20:25:10 +00:00
|
|
|
menubar_modedit.cpp
|
|
|
|
menubar_pcbframe.cpp
|
2011-11-07 18:04:19 +00:00
|
|
|
minimun_spanning_tree.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
mirepcb.cpp
|
|
|
|
modedit.cpp
|
|
|
|
modedit_onclick.cpp
|
|
|
|
modeditoptions.cpp
|
|
|
|
modedit_undo_redo.cpp
|
|
|
|
moduleframe.cpp
|
|
|
|
modules.cpp
|
|
|
|
move-drag_pads.cpp
|
|
|
|
move_or_drag_track.cpp
|
|
|
|
muonde.cpp
|
|
|
|
muwave_command.cpp
|
|
|
|
netlist.cpp
|
2012-02-01 19:49:37 +00:00
|
|
|
netlist_reader_common.cpp
|
2012-01-26 09:37:36 +00:00
|
|
|
netlist_reader_firstformat.cpp
|
|
|
|
netlist_reader_kicad.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
onleftclick.cpp
|
|
|
|
onrightclick.cpp
|
2011-01-28 22:54:16 +00:00
|
|
|
pcb_plot_params.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
pcbnew.cpp
|
2009-10-27 13:48:24 +00:00
|
|
|
pcbnew_config.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
pcbplot.cpp
|
|
|
|
plotgerb.cpp
|
|
|
|
plothpgl.cpp
|
|
|
|
plotps.cpp
|
2009-06-30 10:43:20 +00:00
|
|
|
plotdxf.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
plot_rtn.cpp
|
2010-01-26 11:05:30 +00:00
|
|
|
print_board_functions.cpp
|
|
|
|
printout_controler.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
queue.cpp
|
|
|
|
ratsnest.cpp
|
|
|
|
set_grid.cpp
|
|
|
|
solve.cpp
|
2008-01-21 22:16:45 +00:00
|
|
|
specctra.cpp
|
|
|
|
specctra_export.cpp
|
2008-02-06 22:32:15 +00:00
|
|
|
specctra_import.cpp
|
2011-01-19 20:46:07 +00:00
|
|
|
specctra_keywords.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
swap_layers.cpp
|
|
|
|
tool_modedit.cpp
|
|
|
|
tool_onrightclick.cpp
|
|
|
|
tool_pcb.cpp
|
2009-09-27 11:00:21 +00:00
|
|
|
toolbars_update_user_interface.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
tracepcb.cpp
|
|
|
|
tr_modif.cpp
|
|
|
|
trpiste.cpp
|
|
|
|
work.cpp
|
|
|
|
xchgmod.cpp
|
2011-10-25 16:24:56 +00:00
|
|
|
zones_convert_brd_items_to_polygons_with_Boost.cpp
|
2010-11-18 13:38:08 +00:00
|
|
|
zones_convert_to_polygons_aux_functions.cpp
|
2008-01-18 17:10:54 +00:00
|
|
|
zones_by_polygon.cpp
|
2009-08-23 15:22:44 +00:00
|
|
|
zones_by_polygon_fill_functions.cpp
|
2008-10-02 13:24:31 +00:00
|
|
|
zone_filling_algorithm.cpp
|
2009-08-23 15:22:44 +00:00
|
|
|
zones_functions_for_undo_redo.cpp
|
2010-01-26 11:05:30 +00:00
|
|
|
zones_non_copper_type_functions.cpp
|
2008-10-11 19:27:43 +00:00
|
|
|
zones_polygons_insulated_copper_islands.cpp
|
2008-11-18 18:13:55 +00:00
|
|
|
zones_polygons_test_connections.cpp
|
2008-10-02 13:24:31 +00:00
|
|
|
zones_test_and_combine_areas.cpp
|
|
|
|
)
|
2007-11-08 07:17:37 +00:00
|
|
|
|
2012-03-11 19:48:43 +00:00
|
|
|
set(PCBNEW_SRCS ${PCBNEW_CLASS_SRCS} ${PCBNEW_DIALOGS})
|
|
|
|
|
2010-05-16 18:18:38 +00:00
|
|
|
###
|
|
|
|
# We need some extra sources from common
|
|
|
|
###
|
2012-01-23 04:33:36 +00:00
|
|
|
set(PCBNEW_COMMON_SRCS
|
2010-11-20 10:59:59 +00:00
|
|
|
../common/dialogs/dialog_page_settings.cpp
|
2009-04-05 20:49:15 +00:00
|
|
|
)
|
2007-11-08 07:17:37 +00:00
|
|
|
|
2012-02-28 21:30:46 +00:00
|
|
|
##
|
|
|
|
# Scripting sources
|
|
|
|
##
|
2012-03-11 19:48:43 +00:00
|
|
|
|
2012-03-17 15:17:13 +00:00
|
|
|
if (KICAD_SCRIPTING)
|
|
|
|
|
|
|
|
set(PCBNEW_SCRIPTING_PYTHON_HELPERS
|
2012-03-17 17:30:03 +00:00
|
|
|
../scripting/wx_python_helpers.cpp
|
|
|
|
../scripting/python_scripting.cpp
|
2012-03-17 15:17:13 +00:00
|
|
|
scripting/pcbnew_scripting_helpers.cpp
|
|
|
|
)
|
|
|
|
|
|
|
|
set(PCBNEW_SCRIPTING_SRCS
|
|
|
|
pcbnew_wrap.cxx
|
|
|
|
${PCBNEW_SCRIPTING_PYTHON_HELPERS}
|
|
|
|
)
|
|
|
|
endif()
|
2012-02-28 21:30:46 +00:00
|
|
|
|
|
|
|
##
|
|
|
|
# Scripting build
|
|
|
|
##
|
|
|
|
|
2012-03-17 15:17:13 +00:00
|
|
|
if (KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES)
|
|
|
|
|
2012-03-17 17:30:03 +00:00
|
|
|
set(SWIG_FLAGS -I${CMAKE_CURRENT_SOURCE_DIR}/../.. -I${CMAKE_CURRENT_SOURCE_DIR} -I${CMAKE_CURRENT_SOURCE_DIR}/../include -I${CMAKE_CURRENT_SOURCE_DIR}/../scripting -DDEBUG)
|
2012-03-17 15:17:13 +00:00
|
|
|
|
|
|
|
# collect CFLAGS , and pass them to swig later
|
|
|
|
|
|
|
|
get_directory_property( DirDefs DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} COMPILE_DEFINITIONS )
|
|
|
|
foreach( d ${DirDefs} )
|
|
|
|
SET(SWIG_FLAGS ${SWIG_FLAGS} -D${d} )
|
|
|
|
endforeach()
|
|
|
|
|
|
|
|
# check if we have IO_MGR and KICAD_PLUGIN available
|
|
|
|
if ( USE_NEW_PCBNEW_LOAD OR USE_NEW_PCBNEW_SAVE )
|
|
|
|
SET(SWIG_FLAGS ${SWIG_FLAGS} -DBUILD_WITH_PLUGIN)
|
|
|
|
endif()
|
2012-02-28 21:30:46 +00:00
|
|
|
|
2012-03-11 19:07:10 +00:00
|
|
|
endif()
|
2012-03-17 15:17:13 +00:00
|
|
|
|
|
|
|
if (KICAD_SCRIPTING)
|
|
|
|
|
|
|
|
SET(SWIG_OPTS -python -c++ -outdir ${CMAKE_CURRENT_BINARY_DIR} ${SWIG_FLAGS} )
|
|
|
|
|
|
|
|
add_custom_command(
|
|
|
|
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/pcbnew_wrap.cxx
|
|
|
|
COMMAND ${SWIG_EXECUTABLE} ${SWIG_OPTS} -o ${CMAKE_CURRENT_BINARY_DIR}/pcbnew_wrap.cxx scripting/pcbnew.i
|
|
|
|
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
|
|
|
)
|
|
|
|
|
|
|
|
endif(KICAD_SCRIPTING)
|
2012-02-28 21:30:46 +00:00
|
|
|
|
2012-01-23 04:33:36 +00:00
|
|
|
|
2012-03-11 19:48:43 +00:00
|
|
|
###
|
|
|
|
# _pcbnew DLL/DSO file creation
|
|
|
|
###
|
|
|
|
|
2012-03-17 15:17:13 +00:00
|
|
|
if (KICAD_SCRIPTING_MODULES)
|
|
|
|
|
|
|
|
SET(CMAKE_SWIG_FLAGS ${SWIG_FLAGS})
|
|
|
|
SET_SOURCE_FILES_PROPERTIES(scripting/pcbnew.i PROPERTIES CPLUSPLUS ON)
|
|
|
|
SWIG_ADD_MODULE(pcbnew python scripting/pcbnew.i ${PCBNEW_SCRIPTING_PYTHON_HELPERS} ${PCBNEW_SRCS})
|
|
|
|
SWIG_LINK_LIBRARIES(pcbnew
|
|
|
|
3d-viewer
|
|
|
|
pcbcommon
|
|
|
|
common
|
|
|
|
bitmaps
|
|
|
|
polygon
|
|
|
|
kbool
|
|
|
|
${wxWidgets_LIBRARIES}
|
|
|
|
${OPENGL_LIBRARIES}
|
|
|
|
${GDI_PLUS_LIBRARIES}
|
|
|
|
${PYTHON_LIBRARIES})
|
|
|
|
|
|
|
|
endif (KICAD_SCRIPTING_MODULES)
|
2012-03-11 19:48:43 +00:00
|
|
|
|
2010-05-16 18:18:38 +00:00
|
|
|
###
|
|
|
|
# Windows resource file
|
|
|
|
###
|
2008-03-11 15:57:54 +00:00
|
|
|
if(WIN32)
|
|
|
|
if(MINGW)
|
2008-04-18 08:04:54 +00:00
|
|
|
# PCBNEW_RESOURCES variable is set by the macro.
|
2008-04-13 19:07:32 +00:00
|
|
|
mingw_resource_compiler(pcbnew)
|
2008-03-11 15:57:54 +00:00
|
|
|
else(MINGW)
|
|
|
|
set(PCBNEW_RESOURCES pcbnew.rc)
|
|
|
|
endif(MINGW)
|
|
|
|
endif(WIN32)
|
2008-09-07 19:32:07 +00:00
|
|
|
|
2010-05-16 18:18:38 +00:00
|
|
|
###
|
|
|
|
# Set properties for APPLE on pcbnew target
|
|
|
|
###
|
2008-03-11 15:57:54 +00:00
|
|
|
if(APPLE)
|
2009-04-29 12:10:15 +00:00
|
|
|
set(PCBNEW_RESOURCES pcbnew.icns pcbnew_doc.icns)
|
2008-06-15 16:31:32 +00:00
|
|
|
set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/pcbnew.icns"
|
2008-09-07 19:32:07 +00:00
|
|
|
PROPERTIES MACOSX_PACKAGE_LOCATION Resources)
|
2009-04-29 12:10:15 +00:00
|
|
|
set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/pcbnew_doc.icns"
|
|
|
|
PROPERTIES MACOSX_PACKAGE_LOCATION Resources)
|
2008-06-15 16:31:32 +00:00
|
|
|
set(MACOSX_BUNDLE_ICON_FILE pcbnew.icns)
|
|
|
|
set(MACOSX_BUNDLE_GUI_IDENTIFIER org.kicad-eda.pcbnew)
|
2009-04-29 12:10:15 +00:00
|
|
|
set(MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist)
|
2008-03-11 15:57:54 +00:00
|
|
|
endif(APPLE)
|
2007-11-08 07:17:37 +00:00
|
|
|
|
2009-12-03 06:30:54 +00:00
|
|
|
# Create a C++ compilable string initializer containing html text into a *.h file:
|
2009-12-03 06:25:35 +00:00
|
|
|
add_custom_command(
|
2010-11-29 15:49:22 +00:00
|
|
|
OUTPUT ${CMAKE_CURRENT_SOURCE_DIR}/dialogs/dialog_freeroute_exchange_help_html.h
|
2010-09-29 20:39:53 +00:00
|
|
|
COMMAND ${CMAKE_COMMAND}
|
2010-11-29 15:05:01 +00:00
|
|
|
-DinputFile=${CMAKE_CURRENT_SOURCE_DIR}/dialogs/dialog_freeroute_exchange_help.html
|
|
|
|
-DoutputFile=${CMAKE_CURRENT_SOURCE_DIR}/dialogs/dialog_freeroute_exchange_help_html.h
|
2009-12-03 06:25:35 +00:00
|
|
|
-P ${CMAKE_MODULE_PATH}/Html2C.cmake
|
2010-11-29 15:05:01 +00:00
|
|
|
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/dialogs/dialog_freeroute_exchange_help.html
|
|
|
|
COMMENT "creating ${CMAKE_CURRENT_SOURCE_DIR}/dialogs/dialog_freeroute_exchange_help_html.h
|
|
|
|
from ${CMAKE_CURRENT_SOURCE_DIR}/dialogs/dialog_freeroute_exchange_help.html"
|
2009-12-03 06:25:35 +00:00
|
|
|
)
|
|
|
|
|
2010-11-29 15:05:01 +00:00
|
|
|
set_source_files_properties( dialogs/dialog_freeroute_exchange.cpp
|
2009-12-03 06:30:54 +00:00
|
|
|
PROPERTIES
|
2010-11-29 15:05:01 +00:00
|
|
|
OBJECT_DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/dialogs/dialog_freeroute_exchange_help_html.h
|
2009-12-03 06:30:54 +00:00
|
|
|
)
|
2009-12-03 06:25:35 +00:00
|
|
|
|
2011-01-19 20:46:07 +00:00
|
|
|
|
|
|
|
# auto-generate specctra_lexer.h and specctra_keywords.cpp
|
|
|
|
make_lexer(
|
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/specctra.keywords
|
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/specctra_lexer.h
|
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/specctra_keywords.cpp
|
|
|
|
DSN
|
|
|
|
)
|
|
|
|
|
|
|
|
|
2010-05-16 18:18:38 +00:00
|
|
|
###
|
|
|
|
# Create the pcbnew executable
|
|
|
|
###
|
|
|
|
add_executable(pcbnew WIN32 MACOSX_BUNDLE
|
2012-01-23 04:33:36 +00:00
|
|
|
${PCBNEW_SRCS}
|
|
|
|
${PCBNEW_COMMON_SRCS}
|
2012-02-28 21:30:46 +00:00
|
|
|
${PCBNEW_SCRIPTING_SRCS}
|
2012-01-23 04:33:36 +00:00
|
|
|
${PCBNEW_RESOURCES}
|
|
|
|
)
|
2007-11-08 07:17:37 +00:00
|
|
|
|
2010-05-16 18:18:38 +00:00
|
|
|
###
|
|
|
|
# Set properties for APPLE on pcbnew target
|
|
|
|
###
|
2009-04-29 12:10:15 +00:00
|
|
|
if(APPLE)
|
2010-05-16 18:18:38 +00:00
|
|
|
set_target_properties(pcbnew PROPERTIES MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist)
|
2009-04-29 12:10:15 +00:00
|
|
|
endif(APPLE)
|
|
|
|
|
2010-05-16 18:18:38 +00:00
|
|
|
###
|
|
|
|
# Link executable target pcbnew with correct libraries
|
|
|
|
###
|
2012-01-23 04:33:36 +00:00
|
|
|
target_link_libraries(pcbnew
|
|
|
|
3d-viewer
|
|
|
|
pcbcommon
|
|
|
|
common
|
|
|
|
bitmaps
|
2012-01-25 14:56:52 +00:00
|
|
|
polygon
|
2012-01-23 04:33:36 +00:00
|
|
|
kbool
|
|
|
|
${wxWidgets_LIBRARIES}
|
2012-01-25 14:56:52 +00:00
|
|
|
${OPENGL_LIBRARIES}
|
2012-01-23 04:33:36 +00:00
|
|
|
${GDI_PLUS_LIBRARIES}
|
2012-02-28 21:30:46 +00:00
|
|
|
${PYTHON_LIBRARIES}
|
2012-01-23 04:33:36 +00:00
|
|
|
)
|
2008-03-31 01:32:15 +00:00
|
|
|
|
2010-05-16 18:18:38 +00:00
|
|
|
###
|
|
|
|
# Add pcbnew as install target
|
|
|
|
###
|
|
|
|
install(TARGETS pcbnew
|
2012-01-23 04:33:36 +00:00
|
|
|
DESTINATION ${KICAD_BIN}
|
|
|
|
COMPONENT binary)
|
2008-03-31 01:32:15 +00:00
|
|
|
|
2012-03-17 15:17:13 +00:00
|
|
|
if (KICAD_SCRIPTING_MODULES)
|
|
|
|
install(FILES ${CMAKE_BINARY_DIR}/pcbnew/pcbnew.py
|
|
|
|
DESTINATION share/python)
|
|
|
|
|
|
|
|
install(FILES ${CMAKE_BINARY_DIR}/pcbnew/_pcbnew.so
|
|
|
|
DESTINATION share/python)
|
|
|
|
endif(KICAD_SCRIPTING_MODULES)
|
|
|
|
|
2008-03-31 01:32:15 +00:00
|
|
|
|
2010-01-13 21:15:54 +00:00
|
|
|
# The specctra test fails to build properly using MS Visual Studio.
|
|
|
|
if(NOT MSVC)
|
|
|
|
# This one gets made only when testing.
|
2010-05-15 11:30:57 +00:00
|
|
|
add_executable(specctra_test EXCLUDE_FROM_ALL specctra_test.cpp specctra.cpp)
|
2010-01-13 21:15:54 +00:00
|
|
|
target_link_libraries(specctra_test common ${wxWidgets_LIBRARIES})
|
|
|
|
endif(NOT MSVC)
|
2010-01-05 17:45:38 +00:00
|
|
|
|
|
|
|
# This one gets made only when testing.
|
2010-01-13 21:15:54 +00:00
|
|
|
add_executable(layer_widget_test WIN32 EXCLUDE_FROM_ALL
|
2010-01-05 17:45:38 +00:00
|
|
|
layer_widget.cpp
|
|
|
|
)
|
2010-01-07 02:18:25 +00:00
|
|
|
target_link_libraries(layer_widget_test common ${wxWidgets_LIBRARIES})
|