CMake files cleaning.
This commit is contained in:
parent
1e1a1bb620
commit
6bb111cb8e
|
@ -78,11 +78,9 @@ include(${wxWidgets_USE_FILE})
|
|||
# Include MinGW resource compiler.
|
||||
include(MinGWResourceCompiler)
|
||||
|
||||
if(UNIX)
|
||||
# Automagically create version header file.
|
||||
include(CreateSVNVersionHeader)
|
||||
create_svn_version_header()
|
||||
endif(UNIX)
|
||||
# Automagically create version header file.
|
||||
include(CreateSVNVersionHeader)
|
||||
create_svn_version_header()
|
||||
|
||||
# Include paths.
|
||||
include_directories(
|
||||
|
|
|
@ -1,13 +1,10 @@
|
|||
|
||||
# Generate a static library target named "bitmaps"
|
||||
# (with filename libbitmaps.a on Linux)
|
||||
|
||||
|
||||
# Copy the *.xmp files to bitmaps/${XMP_CPP_DIR}/${basename}.cpp, on change only.
|
||||
# Copy the *.xmp files to bitmaps/${XMP_CPP_DIR}/${BASENAME}.cpp, on change only.
|
||||
# Compile those *.cpp files and put them into the library, then done.
|
||||
|
||||
|
||||
set( BITMAP_SRCS
|
||||
set(BITMAP_SRCS
|
||||
3d.xpm
|
||||
Add_Arc.xpm
|
||||
Add_Bus2Bus.xpm
|
||||
|
@ -386,25 +383,23 @@ set( BITMAP_SRCS
|
|||
viewlibs_icon.xpm
|
||||
)
|
||||
|
||||
|
||||
# the name of the directory to put the copied and renamed *.xpm files into
|
||||
# The name of the directory to put the copied and renamed *.xpm files into
|
||||
# just below the bitmaps directory. As files are copied they are renamed to *.cpp.
|
||||
set( XMP_CPP_DIR auto_renamed_to_cpp )
|
||||
set(XMP_CPP_DIR auto_renamed_to_cpp)
|
||||
|
||||
# get the path of the *.xpm files into "path"
|
||||
set( path ${CMAKE_CURRENT_SOURCE_DIR} )
|
||||
# message( path\ =\ ${path} )
|
||||
# Get the path of the *.xpm files into "PATH"
|
||||
set(PATH ${CMAKE_CURRENT_SOURCE_DIR})
|
||||
#message("PATH = ${PATH}")
|
||||
|
||||
foreach( loop_var ${BITMAP_SRCS} )
|
||||
get_filename_component( basename ${loop_var} NAME_WE )
|
||||
set( cpp_bitmap ${path}/${XMP_CPP_DIR}/${basename}.cpp )
|
||||
foreach(LOOP_VAR ${BITMAP_SRCS})
|
||||
get_filename_component(BASENAME ${LOOP_VAR} NAME_WE)
|
||||
set(CPP_BITMAP "${PATH}/${XMP_CPP_DIR}/${BASENAME}.cpp")
|
||||
add_custom_command(
|
||||
OUTPUT ${cpp_bitmap}
|
||||
COMMAND cmake -E copy '${path}/${basename}.xpm' '${cpp_bitmap}'
|
||||
DEPENDS ${basename}.xpm )
|
||||
list( APPEND cpp_bitmaps ${cpp_bitmap} )
|
||||
SET_SOURCE_FILES_PROPERTIES( ${cpp_bitmap} PROPERTIES COMPILE_FLAGS -DXPMMAIN )
|
||||
endforeach( loop_var )
|
||||
|
||||
add_library( bitmaps ${cpp_bitmaps} )
|
||||
OUTPUT ${CPP_BITMAP}
|
||||
COMMAND cmake -E copy '${PATH}/${BASENAME}.xpm' '${CPP_BITMAP}'
|
||||
DEPENDS ${BASENAME}.xpm)
|
||||
list(APPEND CPP_BITMAPS ${CPP_BITMAP})
|
||||
set_source_files_properties(${CPP_BITMAP} PROPERTIES COMPILE_FLAGS -DXPMMAIN)
|
||||
endforeach(LOOP_VAR)
|
||||
|
||||
add_library(bitmaps ${CPP_BITMAPS})
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
include_directories(bitmaps)
|
||||
|
||||
set(COMMON_SRCS
|
||||
base_screen.cpp
|
||||
base_struct.cpp
|
||||
|
@ -18,7 +16,6 @@ set(COMMON_SRCS
|
|||
edaappl.cpp
|
||||
eda_dde.cpp
|
||||
eda_doc.cpp
|
||||
# edamenu.cpp
|
||||
gestfich.cpp
|
||||
get_component_dialog.cpp
|
||||
gr_basic.cpp
|
||||
|
|
|
@ -2,7 +2,6 @@ add_definitions(-DCVPCB)
|
|||
|
||||
include_directories(
|
||||
${CMAKE_CURRENT_SOURCE_DIR}
|
||||
bitmaps
|
||||
../3d-viewer
|
||||
../pcbnew
|
||||
../polygon)
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
add_definitions(-DEESCHEMA)
|
||||
|
||||
include_directories(
|
||||
${CMAKE_CURRENT_SOURCE_DIR}
|
||||
bitmaps)
|
||||
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
|
||||
|
||||
set(EESCHEMA_SRCS
|
||||
affiche.cpp
|
||||
|
@ -27,6 +25,7 @@ set(EESCHEMA_SRCS
|
|||
database.cpp
|
||||
delete.cpp
|
||||
delsheet.cpp
|
||||
# dialog_backanno.cpp
|
||||
dialog_build_BOM.cpp
|
||||
# dialog_cmp_graphic_properties.cpp
|
||||
dialog_create_component.cpp
|
||||
|
|
|
@ -2,7 +2,6 @@ add_definitions(-DGERBVIEW -DPCBNEW)
|
|||
|
||||
include_directories(
|
||||
${CMAKE_CURRENT_SOURCE_DIR}
|
||||
bitmaps
|
||||
../3d-viewer
|
||||
../cvpcb
|
||||
../pcbnew
|
||||
|
@ -35,6 +34,7 @@ set(GERBVIEW_SRCS
|
|||
rs274x.cpp
|
||||
select_layers_to_pcb.cpp
|
||||
set_color.cpp
|
||||
# struct.cpp <-- not used
|
||||
tool_gerber.cpp
|
||||
tracepcb.cpp
|
||||
trpiste.cpp
|
||||
|
|
|
@ -1,7 +1,5 @@
|
|||
add_definitions(-DKICAD)
|
||||
|
||||
include_directories(bitmaps)
|
||||
|
||||
set(KICAD_SRCS
|
||||
buildmnu.cpp
|
||||
commandframe.cpp
|
||||
|
|
|
@ -3,7 +3,6 @@ add_definitions(-DPCBNEW)
|
|||
include_directories(
|
||||
${CMAKE_CURRENT_SOURCE_DIR}
|
||||
${Boost_INCLUDE_DIR}
|
||||
bitmaps
|
||||
../3d-viewer
|
||||
../polygon)
|
||||
|
||||
|
@ -163,7 +162,7 @@ endif(APPLE)
|
|||
|
||||
add_executable(pcbnew WIN32 MACOSX_BUNDLE ${PCBNEW_SRCS} ${PCBNEW_EXTRA_SRCS} ${PCBNEW_RESOURCES})
|
||||
|
||||
target_link_libraries(pcbnew 3d-viewer common polygon kbool bitmaps ${wxWidgets_LIBRARIES} ${OPENGL_LIBRARIES} )
|
||||
target_link_libraries(pcbnew 3d-viewer common polygon kbool bitmaps ${wxWidgets_LIBRARIES} ${OPENGL_LIBRARIES})
|
||||
|
||||
install(TARGETS pcbnew RUNTIME DESTINATION ${KICAD_BIN}
|
||||
COMPONENT binary)
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
PROJECT( kbool )
|
||||
|
||||
SUBDIRS( src samples )
|
||||
project(kbool)
|
||||
|
||||
subdirs(src samples)
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
ADD_EXECUTABLE(boolonly boolonly.cpp)
|
||||
add_executable(boolonly boolonly.cpp)
|
||||
|
||||
IF(WIN32)
|
||||
ADD_DEFINITIONS( -D_MSWVC_ )
|
||||
ELSE(WIN32)
|
||||
ADD_DEFINITIONS( -D__UNIX__ )
|
||||
ENDIF(WIN32)
|
||||
if(WIN32)
|
||||
add_definitions(-D_MSWVC_)
|
||||
else(WIN32)
|
||||
add_definitions(-D__UNIX__)
|
||||
endif(WIN32)
|
||||
|
||||
INCLUDE_DIRECTORIES( ${kbool_SOURCE_DIR}/.. )
|
||||
include_directories(${kbool_SOURCE_DIR}/..)
|
||||
|
||||
TARGET_LINK_LIBRARIES( boolonly kbool )
|
||||
target_link_libraries(boolonly kbool)
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
IF(WIN32)
|
||||
ADD_DEFINITIONS( -D_MSWVC_ )
|
||||
ELSE(WIN32)
|
||||
ADD_DEFINITIONS( -D__UNIX__ )
|
||||
ENDIF(WIN32)
|
||||
if(WIN32)
|
||||
add_definitions(-D_MSWVC_)
|
||||
else(WIN32)
|
||||
add_definitions(-D__UNIX__)
|
||||
endif(WIN32)
|
||||
|
||||
include_directories(${kbool_SOURCE_DIR}/include)
|
||||
|
||||
|
@ -17,5 +17,4 @@ set(KBOOL_SRCS
|
|||
record.cpp
|
||||
scanbeam.cpp)
|
||||
|
||||
ADD_LIBRARY( kbool ${KBOOL_SRCS})
|
||||
|
||||
add_library(kbool ${KBOOL_SRCS})
|
||||
|
|
Loading…
Reference in New Issue