summarylogtreecommitdiffstats
path: root/mingw-cmake.sh
diff options
context:
space:
mode:
authorMichel Zou2019-12-02 21:47:04 +0100
committerMichel Zou2019-12-02 21:47:04 +0100
commit38d82386d30186290e5ee2303029fbfb10b71485 (patch)
tree0602a186bfec20f445f62fef36a67f4b24243414 /mingw-cmake.sh
parent24fca81db6e22abeb5f8b5d05a5605e5e1fbd585 (diff)
downloadaur-38d82386d30186290e5ee2303029fbfb10b71485.tar.gz
mingw-w64-environment
Diffstat (limited to 'mingw-cmake.sh')
-rw-r--r--mingw-cmake.sh10
1 files changed, 3 insertions, 7 deletions
diff --git a/mingw-cmake.sh b/mingw-cmake.sh
index adb9dd7e7327..886f0a126ccf 100644
--- a/mingw-cmake.sh
+++ b/mingw-cmake.sh
@@ -1,14 +1,10 @@
#!/bin/sh
-mingw_prefix=/usr/@TRIPLE@
-export PKG_CONFIG_LIBDIR="${mingw_prefix}/lib/pkgconfig"
+source mingw-env @TRIPLE@
-default_mingw_compiler_flags="-D_FORTIFY_SOURCE=2 -O2 -pipe -fno-plt -fexceptions --param=ssp-buffer-size=4"
-default_mingw_linker_flags="-Wl,-O1,--sort-common,--as-needed -fstack-protector"
+mingw_prefix=/usr/@TRIPLE@
-export CFLAGS="${MINGW_CFLAGS:-$default_mingw_compiler_flags $CFLAGS}"
-export CXXFLAGS="${MINGW_CXXFLAGS:-$default_mingw_compiler_flags $CXXFLAGS}"
-export LDFLAGS="${MINGW_LDFLAGS:-$default_mingw_linker_flags $LDFLAGS}"
+export PKG_CONFIG_LIBDIR="${mingw_prefix}/lib/pkgconfig"
PATH=${mingw_prefix}/bin:$PATH cmake \
-DCMAKE_INSTALL_PREFIX:PATH=${mingw_prefix} \