source: trunk/source/interfaces/common/sources.cmake@ 1353

Last change on this file since 1353 was 1350, checked in by garnier, 15 years ago

update to last version 4.9.4

File size: 2.8 KB
RevLine 
[1350]1#------------------------------------------------------------------------------
2# sources.cmake
3# Module : G4UIcommon
4# Package: Geant4.src.G4interfaces.G4UIcommon
5#
6# Sources description for a library.
7# Lists the sources and headers of the code explicitely.
8# Lists include paths needed.
9# Lists the internal granular and global dependencies of the library.
10# Source specific properties should be added at the end.
11#
12# Generated on : 24/9/2010
13#
14# $Id: sources.cmake,v 1.4 2010/11/30 12:00:56 bmorgan Exp $
15# GEANT4 Tag $Name: $
16#
17#------------------------------------------------------------------------------
18
19# List external includes needed.
20include_directories(${CLHEP_INCLUDE_DIRS})
21
22# List internal includes needed.
23include_directories(${CMAKE_SOURCE_DIR}/source/global/management/include)
24include_directories(${CMAKE_SOURCE_DIR}/source/intercoms/include)
25#include_directories(${CMAKE_SOURCE_DIR}/source/interfaces/basic/include)
26
27#
28# Module has optional sources
29#
30# List those always built
31set(G4INTERFACES_COMMON_MODULE_HEADERS
32 G4InteractorMessenger.hh
33 G4VBasicShell.hh
34 G4VInteractiveSession.hh
35 G4VInteractorManager.hh)
36
37set(G4INTERFACES_COMMON_MODULE_SOURCES
38 G4InteractorMessenger.cc
39 G4VBasicShell.cc
40 G4VInteractiveSession.cc
41 G4VInteractorManager.cc)
42
43set(G4INTERFACES_COMMON_MODULE_LINK_LIBRARIES )
44
45#
46# Add Qt if required
47#
48if(GEANT4_USE_QT)
49 # Add the sources
50 list(APPEND G4INTERFACES_COMMON_MODULE_HEADERS G4Qt.hh)
51 list(APPEND G4INTERFACES_COMMON_MODULE_SOURCES G4Qt.cc)
52
53 # Stuff for Moc etc, plus LINK_LIBRARIES here
54 include(${QT_USE_FILE})
55
56 # Must enable Qt source with a def...
57 GEANT4_ADD_COMPILE_DEFINITIONS(SOURCES G4Qt.cc
58 COMPILE_DEFINITIONS G4INTY_BUILD_QT)
59
60 # It uses Qt core and gui(?) libs
61 list(APPEND G4INTERFACES_COMMON_MODULE_LINK_LIBRARIES
62 "${QT_QTGUI_LIBRARY};${QT_QTCORE_LIBRARY}")
63endif()
64
65#
66# Win32 option
67#
68if(MSVC AND GEANT4_USE_WIN32TERMINAL)
69 # Add the sources
70 list(APPEND G4INTERFACES_COMMON_MODULE_HEADERS G4Win32.hh)
71 list(APPEND G4INTERFACES_COMMON_MODULE_SOURCES G4Win32.cc)
72
73 # Any extra things here
74endif()
75
76#
77# X11/Xt options
78#
79if(UNIX AND GEANT4_USE_X11TERMINAL)
80 # Add the sources
81 list(APPEND G4INTERFACES_COMMON_MODULE_HEADERS G4Xt.hh)
82 list(APPEND G4INTERFACES_COMMON_MODULE_SOURCES G4Xt.cc)
83
84 # Any extra things here
85endif()
86
87
88#
89# Define the Geant4 Module.
90#
91include(Geant4MacroDefineModule)
92GEANT4_DEFINE_MODULE(NAME G4UIcommon
93 HEADERS
94 ${G4INTERFACES_COMMON_MODULE_HEADERS}
95 SOURCES
96 ${G4INTERFACES_COMMON_MODULE_SOURCES}
97 GRANULAR_DEPENDENCIES
98 G4globman
99 G4intercoms
100 GLOBAL_DEPENDENCIES
101 G4global
102 G4intercoms
103 LINK_LIBRARIES
104 ${G4INTERFACES_COMMON_MODULE_LINK_LIBRARIES}
105)
106
107# List any source specific properties here
108
Note: See TracBrowser for help on using the repository browser.