Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
R
Root
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Admin message
为了安全,强烈建议开启2FA双因子认证:User Settings -> Account -> Enable two-factor authentication!!!
Show more breadcrumbs
cxwx
Root
Commits
f57129de
Commit
f57129de
authored
10 years ago
by
Pere Mato Vila
Browse files
Options
Downloads
Patches
Plain Diff
Fix for ROOT-6208
parent
9eae007b
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
cmake/modules/FindPythia8.cmake
+46
-30
46 additions, 30 deletions
cmake/modules/FindPythia8.cmake
montecarlo/pythia8/CMakeLists.txt
+1
-1
1 addition, 1 deletion
montecarlo/pythia8/CMakeLists.txt
with
47 additions
and
31 deletions
cmake/modules/FindPythia8.cmake
+
46
−
30
View file @
f57129de
# Find the Pythia8 includes and library.
#
# This module defines
# PYTHIA8_INCLUDE_DIR, where to locate Pythia.h file
# PYTHIA8_LIBRARIES, the libraries to link against to use Pythia6
# PYTHIA8_FOUND. If false, you cannot build anything that requires Pythia6.
# PYTHIA8_LIBRARY, where to find the libpythia8 library.
set
(
PYTHIA8_FOUND 0
)
find_path
(
PYTHIA8_INCLUDE_DIR Pythia.h
$ENV{PYTHIA8_DIR}/include
/opt/pythia8/include
/usr/local/include
/usr/include
/usr/include/pythia
DOC
"Specify the directory containing Pythia.h."
)
find_library
(
PYTHIA8_LIBRARY NAMES Pythia8 pythia8 PATHS
$ENV{PYTHIA8_DIR}/lib
/opt/pythia8/lib
/usr/local/lib
/usr/lib
DOC
"Specify the Pythia8 library here."
)
if
(
PYTHIA8_INCLUDE_DIR AND PYTHIA8_LIBRARY
)
set
(
PYTHIA8_FOUND 1
)
message
(
STATUS
"Found Pythia8 library at
${
PYTHIA8_LIBRARY
}
"
)
endif
()
# PYTHIA8_INCLUDE_DIR where to locate Pythia.h file
# PYTHIA8_LIBRARY where to find the libpythia8 library
# PYTHIA8_<lib>_LIBRARY Addicional libraries
# PYTHIA8_LIBRARIES (not cached) the libraries to link against to use Pythia8
# PYTHIA8_FOUND if false, you cannot build anything that requires Pythia8
# PYTHIA8_VERSION version of Pythia8 if found
set
(
_pythia8dirs
${
PYTHIA8_DIR
}
$ENV{PYTHIA8_DIR} /usr /opt/pythia8
)
find_path
(
PYTHIA8_INCLUDE_DIR
NAMES Pythia.h Pythia8/Pythia.h
PATHS
${
_pythia8dirs
}
PATH_SUFFIXES include
DOC
"Specify the directory containing Pythia.h."
)
find_library
(
PYTHIA8_LIBRARY
NAMES pythia8 Pythia8
PATHS
${
_pythia8dirs
}
PATH_SUFFIXES lib
DOC
"Specify the Pythia8 library here."
)
find_library
(
PYTHIA8_hepmcinterface_LIBRARY
NAMES hepmcinterface pythia8tohepmc
PATHS
${
_pythia8dirs
}
PATH_SUFFIXES lib
)
find_library
(
PYTHIA8_lhapdfdummy_LIBRARY
NAMES lhapdfdummy
PATHS
${
_pythia8dirs
}
PATH_SUFFIXES lib
)
set
(
PYTHIA8_LIBRARIES
${
PYTHIA8_LIBRARY
}
)
foreach
(
_lib PYTHIA8_LIBRARY PYTHIA8_hepmcinterface_LIBRARY PYTHIA8_lhapdfdummy_LIBRARY
)
if
(
${
_lib
}
)
set
(
PYTHIA8_LIBRARIES
${
PYTHIA8_LIBRARIES
}
${${
_lib
}}
)
endif
()
endforeach
()
# handle the QUIETLY and REQUIRED arguments and set PYTHIA8_FOUND to TRUE if
# all listed variables are TRUE
include
(
FindPackageHandleStandardArgs
)
find_package_handle_standard_args
(
Pythia8 DEFAULT_MSG PYTHIA8_INCLUDE_DIR PYTHIA8_LIBRARY
)
mark_as_advanced
(
PYTHIA8_INCLUDE_DIR PYTHIA8_LIBRARY PYTHIA8_hepmcinterface_LIBRARY PYTHIA8_lhapdfdummy_LIBRARY
)
if
(
PYTHIA8_FOUND
)
file
(
READ
${
PYTHIA8_INCLUDE_DIR
}
/../xmldoc/Version.xml versionstr
)
string
(
REGEX REPLACE
".*Pythia:versionNumber.*default.*[0-9][.]([0-9]+).*"
"
\\
1"
PYTHIA8_VERSION
"
${
versionstr
}
"
)
endif
()
MARK_AS_ADVANCED
(
PYTHIA8_FOUND PYTHIA8_LIBRARY PYTHIA8_INCLUDE_DIR
)
This diff is collapsed.
Click to expand it.
montecarlo/pythia8/CMakeLists.txt
+
1
−
1
View file @
f57129de
...
...
@@ -7,7 +7,7 @@ ROOT_USE_PACKAGE(montecarlo/eg)
ROOT_USE_PACKAGE
(
math/physics
)
include_directories
(
${
PYTHIA8_INCLUDE_DIR
}
)
ROOT_GENERATE_DICTIONARY
(
G__Pythia8 *.h
module
EGPythia8 LINKDEF LinkDef.h
)
ROOT_GENERATE_DICTIONARY
(
G__Pythia8 *.h
MODULE
EGPythia8 LINKDEF LinkDef.h
)
ROOT_LINKER_LIBRARY
(
EGPythia8 *.cxx G__Pythia8.cxx LIBRARIES Core
${
PYTHIA8_LIBRARIES
}
DEPENDENCIES EG Graf VMC Physics
)
ROOT_INSTALL_HEADERS
()
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment