mirror of
https://github.com/triqs/dft_tools
synced 2024-11-18 12:03:50 +01:00
Merge remote-tracking branch 'app4triqs-remote/unstable' into py3
This commit is contained in:
commit
e9d06414af
@ -93,10 +93,7 @@ set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
|
||||
|
||||
# Global compiler options
|
||||
option(BUILD_SHARED_LIBS "Enable compilation of shared libraries" OFF)
|
||||
add_compile_options(
|
||||
$<$<CONFIG:Debug>:-Og>
|
||||
$<$<CONFIG:Debug>:-ggdb3>
|
||||
)
|
||||
add_compile_options($<$<CONFIG:Debug>:-ggdb3>)
|
||||
|
||||
# Create an Interface target for compiler warnings
|
||||
add_library(${PROJECT_NAME}_warnings INTERFACE)
|
||||
|
@ -10,6 +10,7 @@ WORKDIR $BUILD/$APPNAME
|
||||
RUN chown build .
|
||||
USER build
|
||||
ARG BUILD_DOC=0
|
||||
RUN cmake $SRC/$APPNAME -DTRIQS_ROOT=${INSTALL} -DBuild_Documentation=${BUILD_DOC} && make -j2 || make -j1 VERBOSE=1
|
||||
ARG BUILD_ID
|
||||
RUN cmake $SRC/$APPNAME -DTRIQS_ROOT=${INSTALL} -DBuild_Documentation=${BUILD_DOC} -DBuild_Deps=Always && make -j2 || make -j1 VERBOSE=1
|
||||
USER root
|
||||
RUN make install
|
||||
|
22
Jenkinsfile
vendored
22
Jenkinsfile
vendored
@ -38,7 +38,7 @@ for (int i = 0; i < dockerPlatforms.size(); i++) {
|
||||
mv -f Dockerfile.jenkins Dockerfile
|
||||
"""
|
||||
/* build and tag */
|
||||
def img = docker.build("flatironinstitute/${dockerName}:${env.BRANCH_NAME}-${env.STAGE_NAME}", "--build-arg APPNAME=${projectName} --build-arg BUILD_DOC=${platform==documentationPlatform} .")
|
||||
def img = docker.build("flatironinstitute/${dockerName}:${env.BRANCH_NAME}-${env.STAGE_NAME}", "--build-arg APPNAME=${projectName} --build-arg BUILD_DOC=${platform==documentationPlatform} --build-arg BUILD_ID=${env.BUILD_TAG} .")
|
||||
catchError(buildResult: 'UNSTABLE', stageResult: 'UNSTABLE') {
|
||||
img.inside() {
|
||||
sh "make -C \$BUILD/${projectName} test CTEST_OUTPUT_ON_FAILURE=1"
|
||||
@ -64,22 +64,30 @@ for (int i = 0; i < osxPlatforms.size(); i++) {
|
||||
def srcDir = pwd()
|
||||
def tmpDir = pwd(tmp:true)
|
||||
def buildDir = "$tmpDir/build"
|
||||
/* install real branches in a fixed predictable place so apps can find them */
|
||||
def installDir = keepInstall ? "${env.HOME}/install/${projectName}/${env.BRANCH_NAME}/${platform}" : "$tmpDir/install"
|
||||
def triqsDir = "${env.HOME}/install/triqs/${triqsBranch}/${platform}"
|
||||
def venv = triqsDir
|
||||
dir(installDir) {
|
||||
deleteDir()
|
||||
}
|
||||
|
||||
checkout scm
|
||||
|
||||
def hdf5 = "${env.BREW}/opt/hdf5@1.10"
|
||||
dir(buildDir) { withEnv(platformEnv[1].collect { it.replace('\$BREW', env.BREW) } + [
|
||||
"PATH=$triqsDir/bin:${env.BREW}/bin:/usr/bin:/bin:/usr/sbin",
|
||||
"CPLUS_INCLUDE_PATH=$triqsDir/include:${env.BREW}/include",
|
||||
"LIBRARY_PATH=$triqsDir/lib:${env.BREW}/lib",
|
||||
"CMAKE_PREFIX_PATH=$triqsDir/lib/cmake/triqs"]) {
|
||||
"PATH=$venv/bin:${env.BREW}/bin:/usr/bin:/bin:/usr/sbin",
|
||||
"HDF5_ROOT=$hdf5",
|
||||
"C_INCLUDE_PATH=$hdf5/include:${env.BREW}/include",
|
||||
"CPLUS_INCLUDE_PATH=$venv/include:$hdf5/include:${env.BREW}/include",
|
||||
"LIBRARY_PATH=$venv/lib:$hdf5/lib:${env.BREW}/lib",
|
||||
"LD_LIBRARY_PATH=$hdf5/lib",
|
||||
"PYTHONPATH=$installDir/lib/python3.7/site-packages",
|
||||
"CMAKE_PREFIX_PATH=$venv/lib/cmake/triqs"]) {
|
||||
deleteDir()
|
||||
/* note: this is installing into the parent (triqs) venv (install dir), which is thus shared among apps and so not be completely safe */
|
||||
sh "pip3 install -r $srcDir/requirements.txt"
|
||||
sh "cmake $srcDir -DCMAKE_INSTALL_PREFIX=$installDir -DTRIQS_ROOT=$triqsDir"
|
||||
sh "pip3 install -U -r $srcDir/requirements.txt"
|
||||
sh "cmake $srcDir -DCMAKE_INSTALL_PREFIX=$installDir -DTRIQS_ROOT=$triqsDir -DBuild_Deps=Always"
|
||||
sh "make -j2"
|
||||
catchError(buildResult: 'UNSTABLE', stageResult: 'UNSTABLE') { try {
|
||||
sh "make test CTEST_OUTPUT_ON_FAILURE=1"
|
||||
|
@ -14,7 +14,8 @@ macro(generate_docs header_file)
|
||||
COMMAND rm -rf ${CMAKE_CURRENT_SOURCE_DIR}/cpp2rst_generated
|
||||
COMMAND
|
||||
PYTHONPATH=${CPP2PY_BINARY_DIR}:$ENV{PYTHONPATH}
|
||||
${CPP2PY_BINARY_DIR}/bin/c++2rst
|
||||
PATH=${CPP2PY_BINARY_DIR}/bin:${CPP2PY_ROOT}/bin:$ENV{PATH}
|
||||
c++2rst
|
||||
${header_file}
|
||||
-N ${PROJECT_NAME}
|
||||
--output_directory ${CMAKE_CURRENT_SOURCE_DIR}/cpp2rst_generated
|
||||
|
Loading…
Reference in New Issue
Block a user