Package Details: mingw-w64-configure 0.1.1-9

Git Clone URL: https://aur.archlinux.org/mingw-w64-configure.git (read-only, click to copy)
Package Base: mingw-w64-configure
Description: configure wrapper for MinGW (mingw-w64)
Upstream URL: http://fedoraproject.org/wiki/MinGW
Licenses: GPL
Submitter: xantares
Maintainer: xantares
Last Packager: xantares
Votes: 42
Popularity: 0.35
First Submitted: 2014-10-20 08:56
Last Updated: 2019-12-02 20:50

Required by (231)

Sources (1)

Latest Comments

1 2 3 Next › Last »

NixUnderflow commented on 2020-06-09 19:21

Hello! I noticed that you use source in mingw-configure.sh. source is a bashism, but you use #!/bin/sh (POSIX sh) instead of #!/bin/bash.

This is an issue since if someone symlinks /bin/sh to DASH it can break the build for some packages.

I noticed that mingw-cmake.sh uses source in the same way. There are probably others too. I recommend using checkbashisms or ShellCheck for spotting issues such as these.

Here are some suggestions on how to deal with the issue:

Use the dot command

Since the dot command doesn't support supplying positional arguments when sourcing, you'll have to assign @TRIPLE@ to a variable:

_arch=@TRIPLE@ . mingw-env
# Instead of:
# source mingw-env @TRIPLE@

I took a quick look at mingw-env.sh as well and noticed that you set $_arch to $1. You'll gonna have to remove that so you don't override the one we set above.

Use bash

If you really want to use source, change the shebang to #!/bin/bash. This applies to all scripts, including mingw-env.sh, since it depends on Bash's source in order to work correctly.

Martchus commented on 2019-11-12 11:38

Apparently it doesn't work for Qt: https://github.com/Martchus/PKGBUILDs/issues/105#issuecomment-552651555

But I still haven't looked into this myself.

xantares commented on 2019-11-12 09:10

Yes, it seems like a better solution than disabling FORTIFY.

Martchus commented on 2019-11-11 22:03

I see that you've gone back to -D_FORTIFY_SOURCE=2 but also added -fstack-protector to the ld flags. So that's the way to go? It seems like I have to do the same for the mingw-w64-qt5-* packages then: https://github.com/Martchus/PKGBUILDs/issues/105

xantares commented on 2019-11-10 11:51

pingplug, I set FORTIFY_FOURCE=0 to fix missing link to libssp

pingplug commented on 2019-10-24 13:15

they use libssp when FORTIFY_SOURCE is on

links: https://sourceforge.net/p/mingw-w64/mailman/message/36747706/ https://sourceforge.net/p/mingw-w64/mailman/message/36764708/ https://sourceforge.net/p/mingw-w64/mailman/message/36770243/

xantares commented on 2019-10-24 12:45

we already have FORTIFY_SOURCE=2 here

libssp is only needed if you pass fstack-protector options, which is not enabled by default here (but supported as libssp is built)

pingplug commented on 2019-10-24 12:35

recently mingw-w64 adds FORTIFY_SOURCE support, which breaks most mingw-w64- packages as it needs _chk functions in libssp. should we add -U_FORTY_SOURCE in CPPFLAGS?

xantares commented on 2019-02-12 17:22

anyways they removed -fstack-protector-strong from latest makepkg.conf, I just didnt see it as my config file was backup'ed

Martchus commented on 2019-02-10 19:37

@pinplug is right, e.g. mingw-w64-freetype2 (https://github.com/Martchus/PKGBUILDs/issues/84#issuecomment-462163150)

I have no conclusion to fix this yet. Maybe -fstack-protector-strong needs to be added to ld flags, too.