[openssl-users] MinGW64 / MSYS2 and ./Configure : use of Windows style path causing failures to 'make'
noloader at gmail.com
Tue Dec 27 05:40:15 UTC 2016
On Tue, Dec 27, 2016 at 12:24 AM, Ron Gaw <ronmlgaw at yahoo dot com>
via openssl-users <openssl-users at openssl.org> wrote:
> I am using a MinGW64 / MSYS2 environment to compile OpenSSL1.1.0c, but
> failing consistently after multiple attempts with a few variations each
> attempt (including deleting entire source directory and
> re-untar/ungzipping). I believe there's something wrong either with my
> environment settings or ./Configure options. This is the output of
> ./Configure after setting only the CFLAGS env var:
> $ export "CFLAGS=-03"
> $ ./Configure mingw64 --prefix=/usr/local zlib shared
> Configuring OpenSSL version 1.1.0c (0x1010003fL)
> PERL =C:\msys64\mingw64\bin\perl.exe
> SIXTY_FOUR_BIT mode
> Configured for mingw64.
> $ make
> C:\msys64\mingw64\bin\perl.exe "-I." -Mconfigdata "util\dofile.pl" \
> "-oMakefile" crypto\include\internal\bn_conf.h.in >
> /bin/sh: C:msys64mingw64binperl.exe: command not found
> make: *** [Makefile:701: crypto\include\internal\bn_conf.h] Error 127
> It seems the "\" is the culprit here, since the execution of the make
> command appears to strip those out and then (as expected) the /bin/sh cannot
> recognize that large hash of what should have been the path to Perl. I did
> edit the first Makefile above to :
> Change the base PERL to "C:/msys64/mingw64/bin/perl.exe", *and*
> crypto/include/internal/bin_conf.h.in >
> The above worked, but *only* for that line of the make file (as I expected).
> It then fails at the very next line because I didn't edit every "\" to
> become "/" instead. I'm not sure I'm willing to do that much editing...
> seems there's got to be a better way to make this work.
> I realize this has something to do with specifying ./Configure mingw64 ....
> and how it's populating the Makefiles using Windows-style paths, but I'm not
> sure it's safe / okay to fake having a Unix build target instead, since this
> will likely create new / other problems with libraries, etc.
> Am I missing a ./Configure option, an environment variable I should preset,
> or something else altogether?
More information about the openssl-users