Skip to content
GitLab
About GitLab
GitLab: the DevOps platform
Explore GitLab
Install GitLab
How GitLab compares
Get started
GitLab docs
GitLab Learn
Pricing
Talk to an expert
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Projects
Groups
Snippets
Sign up now
Login
Sign in / Register
Toggle navigation
Menu
Open sidebar
EIC
NPDet
Commits
2a6c6773
Commit
2a6c6773
authored
Dec 06, 2017
by
Whitney Armstrong
Browse files
Added proper library check for npdet_to_step
modified: CMakeLists.txt modified: src/npdet_to_step.cxx
parent
76056ca3
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/tools/CMakeLists.txt
View file @
2a6c6773
...
...
@@ -10,25 +10,34 @@ find_package( DD4hep REQUIRED COMPONENTS DDCore DDG4 )
find_package
(
ROOT REQUIRED COMPONENTS Geom GenVector MathCore
)
include
(
${
ROOT_USE_FILE
}
)
set
(
exe_name npdet_to_step
)
set
(
exe_name npdet_fields
)
add_executable
(
${
exe_name
}
src/
${
exe_name
}
.cxx
)
target_include_directories
(
${
exe_name
}
PUBLIC
PRIVATE include
)
PRIVATE include
)
target_compile_features
(
${
exe_name
}
PUBLIC cxx_auto_type
PUBLIC cxx_trailing_return_types
PRIVATE cxx_variadic_templates
)
target_link_libraries
(
${
exe_name
}
PUBLIC DDCore DDG4 ROOT::Core ROOT::Hist ROOT::GenVector ROOT::Gpad
)
install
(
TARGETS
${
exe_name
}
EXPORT NPDetTargets
RUNTIME DESTINATION bin
)
# npdet_to_step needs ROOT's GeoCad library
if
(
TARGET ROOT::GeoCad
)
set
(
exe_name npdet_to_step
)
add_executable
(
${
exe_name
}
src/
${
exe_name
}
.cxx
)
target_include_directories
(
${
exe_name
}
PUBLIC
PRIVATE include
)
target_compile_features
(
${
exe_name
}
PUBLIC cxx_auto_type
PUBLIC cxx_trailing_return_types
PRIVATE cxx_variadic_templates
)
PRIVATE cxx_variadic_templates
)
target_link_libraries
(
${
exe_name
}
PUBLIC DDCore DDG4 ROOT::Core ROOT::Hist ROOT::GenVector ROOT::Gpad ROOT::GeoCad
)
install
(
TARGETS
${
exe_name
}
install
(
TARGETS
${
exe_name
}
EXPORT NPDetTargets
RUNTIME DESTINATION bin
)
RUNTIME DESTINATION bin
)
endif
(
TARGET ROOT::GeoCad
)
src/tools/src/npdet_to_step.cxx
View file @
2a6c6773
...
...
@@ -161,9 +161,8 @@ int main (int argc, char *argv[]) {
detector
.
fromCompact
(
s
.
infile
);
TGeoToStep
*
mygeom
=
new
TGeoToStep
(
&
(
detector
.
manager
())
);
//mygeom->CreateGeometry();
detector
.
manager
().
Export
(
"geometry.gdml"
);
mygeom
->
CreateGeometry
();
//detector.manager().Export("geometry.gdml");
std
::
cout
<<
"saved as geometry.stp
\n
"
;
return
0
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment