source: branches/dev-5693/external/build_externals/Jenkins/ci/vars/buildAssimulo.groovy @ 12102

Last change on this file since 12102 was 12102, checked in by randersson, 12 months ago

#5693 Added windows tests for assimulo to its groovy script, now working with 64 bit.

File size: 2.3 KB
Line 
1def call(JM_CHECKOUT_PATH, JM_BRANCH, INSTALL_PATH, TARGET, bitness=["32", "64"], BLAS_HOME_BASE=null, LAPACK_HOME_BASE=null, SUPERLU_HOME_BASE=null, SUNDIALS_HOME_BASE=null,stash=false, archive=true) {
2    if (JM_CHECKOUT_PATH != null) {
3        checkoutJM(${JM_BRANCH})
4    }
5    INSTALL_PATH_UNIX=unixpath("${INSTALL_PATH}")
6    if (BLAS_HOME_BASE == null) {
7        BLAS_HOME_BASE="${INSTALL_PATH_UNIX}/blas_install"
8    }
9
10    if (LAPACK_HOME_BASE == null) {
11        LAPACK_HOME_BASE="${INSTALL_PATH_UNIX}/lapack_install"
12    }
13
14    if (SUPERLU_HOME_BASE == null) {
15        SUPERLU_HOME_BASE="${INSTALL_PATH_UNIX}/superlu_install"
16    }
17
18    if (SUNDIALS_HOME_BASE == null) {
19        SUNDIALS_HOME_BASE="${INSTALL_PATH_UNIX}/sundials_install"
20    }
21    for (bit in bitness) {
22        stage ("assimulo_${TARGET} ${bit} bit") {
23            runMSYSWithEnv("""\
24            export JM_HOME="\$(pwd)/JModelica/"
25            JENKINS_BUILD_DIR="\$(pwd)/build"
26            cd \${JM_HOME}/external/build_externals/build/assimulo
27           
28            make clean BUILD_DIR=\${JENKINS_BUILD_DIR}/assimulo* BITNESS=${bit}
29            make ${TARGET} USER_CONFIG=\${JM_HOME}/external/build_externals/configurations/Assimulo/windows/win${bit} JM_HOME=\${JM_HOME} BUILD_DIR=\${JENKINS_BUILD_DIR} BLAS_HOME=${BLAS_HOME_BASE}${bit} SUNDIALS_HOME=${SUNDIALS_HOME_BASE}${bit} LAPACK_HOME=${LAPACK_HOME_BASE}${bit} SUPERLU_HOME=${SUPERLU_HOME_BASE}${bit} INSTALL_DIR_FOLDER=${INSTALL_PATH_UNIX}/assimulo/${TARGET}/Python_${bit}
30            """);
31            if ("${TARGET}" == "folder") {
32                runMSYSWithEnv("""\
33                export JM_HOME="\$(pwd)/JModelica/"
34                nosetests ${INSTALL_PATH_UNIX}/assimulo/${TARGET}/Python_${bit}/folder/assimulo/tests/*.py
35                """, "", false, bit);
36            }
37            if (stash || archive) {
38                dir("${INSTALL_PATH}/assimulo/${TARGET}") {
39                    if (stash) {
40                        stash includes: "Python_${bit}/**", name: "Python_${bit}_assimulo_${TARGET}"
41                    }
42                    if (archive) {
43                        archiveArtifacts artifacts: "Python_${bit}/**", fingerprint: false
44                    }
45                }
46            }
47        }
48    }
49}
Note: See TracBrowser for help on using the repository browser.