From d27e779de30045f4a17acb2a79fcd714b9dbac33 Mon Sep 17 00:00:00 2001 From: Simon Sobisch Date: Fri, 6 Jan 2023 10:02:02 +0000 Subject: [PATCH] appveyor with more build options and binaries #280 --- .appveyor_msys_build.sh | 29 +++++++++++++++++++++++++++-- appveyor.yml | 14 ++++++++++---- 2 files changed, 37 insertions(+), 6 deletions(-) diff --git a/.appveyor_msys_build.sh b/.appveyor_msys_build.sh index 151483b4f..5595fd578 100644 --- a/.appveyor_msys_build.sh +++ b/.appveyor_msys_build.sh @@ -1,9 +1,27 @@ export PATH=/c/msys64/mingw$ABI/bin:/c/projects/mpir/bin/:$PATH cd /c/projects/mpir + echo && echo build: ./autogen.sh ./autogen.sh -echo && echo build: ./configure ABI=$ABI $LIB -./configure ABI=$ABI $LIB + +case "$LIBRARY" in + "static") CONFIGURE_FLAGS="--enable-static --disable-shared";; + "shared") CONFIGURE_FLAGS="--disable-static --enable-shared";; +esac +case "$FEATURE" in + *GMP*) CONFIGURE_FLAGS="$CONFIGURE_FLAGS --enable-gmpcompat" + MODE="$MODE-gmp" + ;; +esac +case "$FEATURE" in + *CXX*) CONFIGURE_FLAGS="$CONFIGURE_FLAGS --enable-cxx" + MODE="$MODE-cxx" + ;; +esac + +echo && echo build: ./configure ABI=$ABI $CONFIGURE_FLAGS +./configure ABI=$ABI $CONFIGURE_FLAGS --prefix=/usr/local + echo && echo build: make make # should work but falsely requires texlive ?!? @@ -11,5 +29,12 @@ make #DISTCHECK_CONFIGURE_FLAGS="ABI=$ABI $LIB" make distcheck echo && echo build: make check make check + echo && echo build: make dist make dist + +if test "x$FEATURE" != "x"; then + echo && echo build: make install DESTDIR=$(pwd)/package + make install DESTDIR=$(pwd)/package && cd package/usr/local && \ + zip -9 -r ../../../bin$ABI$MODE-$LIBRARY.zip * +fi diff --git a/appveyor.yml b/appveyor.yml index a83d12c0d..ec7dfc991 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -9,16 +9,20 @@ environment: matrix: - COMPILER: MinGW-w64 ABI: 32 - LIB: --enable-static --disable-shared + LIBRARY: static + FEATURE: CXX GMP - COMPILER: MinGW-w64 ABI: 32 - LIB: --disable-static --enable-shared + LIBRARY: shared + FEATURE: CXX GMP - COMPILER: MinGW-w64 ABI: 64 - LIB: --enable-static --disable-shared + LIBRARY: static + FEATURE: CXX GMP - COMPILER: MinGW-w64 ABI: 64 - LIB: --disable-static --enable-shared + LIBRARY: shared + FEATURE: CXX GMP install: - if [%COMPILER%]==[MinGW-w64] C:\msys64\usr\bin\bash -lc "pacman --noconfirm -S %MINGW_PREREQ%" @@ -34,3 +38,5 @@ cache: artifacts: - path: mpir-3.* name: source tarball + - path: bin* + name: binaries