Merge branch 'master' of gitlab.psi.ch:Pmodules/buildblocks

This commit is contained in:
2017-04-24 08:31:17 +02:00
9 changed files with 48 additions and 3 deletions

View File

@@ -1,2 +1,3 @@
gcc/6.1.0 stable b:gmp/6.1.0 b:mpfr/3.1.4 b:mpc/1.0.3
gcc/6.2.0 stable b:gmp/6.1.1 b:mpfr/3.1.4 b:mpc/1.0.3
gcc/6.3.0 stable b:gmp/6.1.2 b:mpfr/3.1.5 b:mpc/1.0.3

View File

@@ -0,0 +1 @@
gtest/1.7.0 unstable b:cmake

View File

@@ -1,7 +1,36 @@
#!/usr/bin/env modbuild
declare -a config_args=()
pbuild::set_docfiles \
CHANGES \
CONTRIBUTORS \
LICENSE \
README
pbuild::configure() {
cmake \
-DCMAKE_INSTALL_PREFIX="${PREFIX}" \
-DCMAKE_BUILD_TYPE=RELEASE \
"${config_args[@]}" \
"${MODULE_SRCDIR}"
}
pbuild::install() {
local -r _include_srcdir="${MODULE_SRCDIR}/include/gtest"
local -r _include_dstdir="${PREFIX}/include"
if [[ -e "${_include_dstdir}" ]]; then
chmod -R u+w "${_include_dstdir}"
fi
mkdir -p "${_include_dstdir}"
cp -rv "${_include_srcdir}"/* "${_include_dstdir}"
local -r _lib_dstdir="${PREFIX}/lib"
mkdir -p "${_lib_dstdir}"
cp -v *.a "${_lib_dstdir}"
}
pbuild::add_to_group 'Programming'
pbuild::set_runtime_dependencies ""
pbuild::set_build_dependencies "${COMPILER}"
pbuild::make_all

View File

@@ -0,0 +1,10 @@
#%Module1.0
module-whatis "Google's C++ test framework"
module-url "https://github.com/google/googletest/"
module-license "See ${PREFIX}/share/doc/gtest/LICENSE"
module-maintainer "Achim Gsell <achim.gsell@psi.ch>"
module-help "
See https://github.com/google/googletest/blob/master/googletest/docs/Primer.md
"