build-blocks:
- use modbuild in shebang - refactore function calls
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
#!/bin/bash
|
||||
#!/usr/bin/env modbuild
|
||||
#
|
||||
# Notes:
|
||||
# On Mac OS X VTK does not compile out of the box with self-compiled GCC.
|
||||
@@ -6,11 +6,9 @@
|
||||
# and remove these strings.
|
||||
#
|
||||
|
||||
source "$(dirname $0)/../../../lib/libpmodules.bash"
|
||||
|
||||
case ${OS} in
|
||||
Darwin )
|
||||
pmodules.pre_configure() {
|
||||
pbuild::pre_configure() {
|
||||
# for the time being: on Mac OS X we need GL/gl.h from MacPorts:
|
||||
std::append_path C_INLCUDE_PATH '/opt/local/include'
|
||||
std::append_path CPLUS_INCLUDE_PATH '/opt/local/include'
|
||||
@@ -18,7 +16,7 @@ Darwin )
|
||||
;;
|
||||
esac
|
||||
|
||||
pmodules.configure() {
|
||||
pbuild::configure() {
|
||||
cmake -DCMAKE_INSTALL_PREFIX:PATH=$PREFIX \
|
||||
-DVTK_INSTALL_INCLUDE_DIR:PATH=include \
|
||||
-DVTK_INSTALL_LIB_DIR:PATH=lib \
|
||||
@@ -26,8 +24,8 @@ pmodules.configure() {
|
||||
"${MODULE_SRCDIR}"
|
||||
}
|
||||
|
||||
pmodules.add_to_group 'Compiler'
|
||||
pmodules.set_runtime_dependencies "${COMPILER}"
|
||||
pmodules.set_build_dependencies 'cmake' "${COMPILER}"
|
||||
pmodules.make_all
|
||||
pbuild::add_to_group 'Compiler'
|
||||
pbuild::set_runtime_dependencies "${COMPILER}"
|
||||
pbuild::set_build_dependencies 'cmake' "${COMPILER}"
|
||||
pbuild::make_all
|
||||
|
||||
|
||||
Reference in New Issue
Block a user