Thread overview | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
November 05, 2015 Trying to generate gdc for mingw-w64(x86 and x64) using msys2 | ||||
---|---|---|---|---|
| ||||
Hi, I would like to generate a d compiler targeting mingw-w64 using the msys2 build system. So I have installed msys2 (posix emulation like cygwin) as shown here: http://msys2.github.io/ and I have installed necessary packages: $ pacman -S base-devel $ pacman -S mingw-w64-x86_64-toolchain optionally you can also installed mingw-w64-i686-toolchain if you want to build mingw32 packages but for now I am only interested in mingw64 (64 bits). Then I have forked MINGW-packages repository (https://github.com/vrichomme/MINGW-packages) to make my experiments. $ git clone https://github.com/vrichomme/MINGW-packages.git $ cd MINGW-packages/mingw-w64-gcc Inside mingw-w64-gcc I have used the 4 patches and renamed them to be more compliant with msys2 build system: gdc-patch-gcc-5.patch gdc-patch-toplev-5.patch gdc-patch-versym-cpu-5.patch gdc-patch-versym-os-5.patch Then we are ready to start compilation: $ MINGW_INSTALLS=mingw64 makepkg-mingw -sLf ... /home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/gdc -B/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/ -L/mingw64/x86_64-w64-mingw32/lib -L/mingw64/lib -isystem /mingw64/x86_64-w64-mingw32/include -isystem /mingw64/include -B/mingw64/x86_64-w64-mingw32/bin/ -B/mingw64/x86_64-w64-mingw32/lib/ -isystem /mingw64/x86_64-w64-mingw32/include -isystem /mingw64/x86_64-w64-mingw32/sys-include -o gcc/gthreads/posix.o -Wall -g -frelease -O2 -nostdinc -pipe -Wno-deprecated -I ../../../../gcc-5.2.0/libphobos/libdruntime -I ./x86_64-w64-mingw32 -I . -c ../../../../gcc-5.2.0/libphobos/libdruntime/gcc/gthreads/posix.d ../../../../gcc-5.2.0/libphobos/libdruntime/gcc/gthreads/posix.d:29:1: error: undefined identifier pthread_key_t, did you mean alias gthread_key_t? alias gthread_key_t = pthread_key_t; ^ ... I am quite new to D language but I can see that posix.d imports core.sys.posix.pthread and I thought that on Windows Version(Posix) is not defined so how can it compile ? Do I need to add a -DPosix or something like that ? Do I need to add a Version(Mingw64) inside core.sys.posix.pthread ? Thanks |
November 05, 2015 Re: Trying to generate gdc for mingw-w64(x86 and x64) using msys2 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Vincent R | Am Thu, 05 Nov 2015 12:42:08 +0000 schrieb Vincent R <lol@dlang.org>: > Hi, > > I would like to generate a d compiler targeting mingw-w64 using > the msys2 build system. > So I have installed msys2 (posix emulation like cygwin) as shown > here: http://msys2.github.io/ and I have installed necessary > packages: > > $ pacman -S base-devel > $ pacman -S mingw-w64-x86_64-toolchain > > optionally you can also installed mingw-w64-i686-toolchain if you want to build mingw32 packages but for now I am only interested in mingw64 (64 bits). > > Then I have forked MINGW-packages repository (https://github.com/vrichomme/MINGW-packages) to make my experiments. > > $ git clone https://github.com/vrichomme/MINGW-packages.git $ cd MINGW-packages/mingw-w64-gcc > > Inside mingw-w64-gcc I have used the 4 patches and renamed them to be more compliant with msys2 build system: > > gdc-patch-gcc-5.patch > gdc-patch-toplev-5.patch > gdc-patch-versym-cpu-5.patch > gdc-patch-versym-os-5.patch > > Then we are ready to start compilation: > > $ MINGW_INSTALLS=mingw64 makepkg-mingw -sLf > ... > /home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/gdc > -B/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/ > -L/mingw64/x86_64-w64-mingw32/lib -L/mingw64/lib > -isystem /mingw64/x86_64-w64-mingw32/include > -isystem /mingw64/include -B/mingw64/x86_64-w64-mingw32/bin/ > -B/mingw64/x86_64-w64-mingw32/lib/ > -isystem /mingw64/x86_64-w64-mingw32/include > -isystem /mingw64/x86_64-w64-mingw32/sys-include -o > gcc/gthreads/posix.o -Wall -g -frelease -O2 -nostdinc -pipe > -Wno-deprecated -I ../../../../gcc-5.2.0/libphobos/libdruntime > -I ./x86_64-w64-mingw32 -I . > -c ../../../../gcc-5.2.0/libphobos/libdruntime/gcc/gthreads/posix.d ../../../../gcc-5.2.0/libphobos/libdruntime/gcc/gthreads/posix.d:29:1: > error: undefined identifier pthread_key_t, did you mean alias > gthread_key_t? alias gthread_key_t = pthread_key_t; ^ ... > > I am quite new to D language but I can see that posix.d imports > core.sys.posix.pthread and I thought that on Windows > Version(Posix) is not defined so how can it compile ? > Do I need to add a -DPosix or something like that ? > Do I need to add a Version(Mingw64) inside core.sys.posix.pthread > ? > > Thanks > > > > > > > > > > Do you use winpthreads? It seems the thread model is 'wrong': https://github.com/D-Programming-GDC/GDC/blob/master/libphobos/configure.ac#L299 Please post the output of /home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/gdc -v (I guess threadmodel is posix for winpthreads. But druntime doesn't really understand winpthreads. We'd have to modify core/sys/posix/pthread.d and adjust the version(Posix) block. But it's hard to estimate how many headers we need to change to support this.) |
November 05, 2015 Re: Trying to generate gdc for mingw-w64(x86 and x64) using msys2 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Johannes Pfau | On Thursday, 5 November 2015 at 13:15:45 UTC, Johannes Pfau wrote: > Am Thu, 05 Nov 2015 12:42:08 +0000 > schrieb Vincent R <lol@dlang.org>: > >> Hi, >> >> I would like to generate a d compiler targeting mingw-w64 using >> the msys2 build system. >> So I have installed msys2 (posix emulation like cygwin) as shown >> here: http://msys2.github.io/ and I have installed necessary >> packages: >> >> $ pacman -S base-devel >> $ pacman -S mingw-w64-x86_64-toolchain >> >> optionally you can also installed mingw-w64-i686-toolchain if you want to build mingw32 packages but for now I am only interested in mingw64 (64 bits). >> >> Then I have forked MINGW-packages repository (https://github.com/vrichomme/MINGW-packages) to make my experiments. >> >> $ git clone https://github.com/vrichomme/MINGW-packages.git $ cd MINGW-packages/mingw-w64-gcc >> >> Inside mingw-w64-gcc I have used the 4 patches and renamed them to be more compliant with msys2 build system: >> >> gdc-patch-gcc-5.patch >> gdc-patch-toplev-5.patch >> gdc-patch-versym-cpu-5.patch >> gdc-patch-versym-os-5.patch >> >> Then we are ready to start compilation: >> >> $ MINGW_INSTALLS=mingw64 makepkg-mingw -sLf >> ... >> /home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/gdc >> -B/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/ >> -L/mingw64/x86_64-w64-mingw32/lib -L/mingw64/lib >> -isystem /mingw64/x86_64-w64-mingw32/include >> -isystem /mingw64/include -B/mingw64/x86_64-w64-mingw32/bin/ >> -B/mingw64/x86_64-w64-mingw32/lib/ >> -isystem /mingw64/x86_64-w64-mingw32/include >> -isystem /mingw64/x86_64-w64-mingw32/sys-include -o >> gcc/gthreads/posix.o -Wall -g -frelease -O2 -nostdinc -pipe >> -Wno-deprecated -I ../../../../gcc-5.2.0/libphobos/libdruntime >> -I ./x86_64-w64-mingw32 -I . >> -c ../../../../gcc-5.2.0/libphobos/libdruntime/gcc/gthreads/posix.d ../../../../gcc-5.2.0/libphobos/libdruntime/gcc/gthreads/posix.d:29:1: >> error: undefined identifier pthread_key_t, did you mean alias >> gthread_key_t? alias gthread_key_t = pthread_key_t; ^ ... >> >> I am quite new to D language but I can see that posix.d imports >> core.sys.posix.pthread and I thought that on Windows >> Version(Posix) is not defined so how can it compile ? >> Do I need to add a -DPosix or something like that ? >> Do I need to add a Version(Mingw64) inside core.sys.posix.pthread >> ? >> >> Thanks >> >> >> >> >> >> >> >> >> >> > > Do you use winpthreads? > It seems the thread model is 'wrong': > https://github.com/D-Programming-GDC/GDC/blob/master/libphobos/configure.ac#L299 > > Please post the output of /home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/gdc -v > > > (I guess threadmodel is posix for winpthreads. But druntime doesn't really understand winpthreads. We'd have to modify core/sys/posix/pthread.d and adjust the version(Posix) block. But it's hard to estimate how many headers we need to change to support this.) 19013692@MLVD0032 MINGW64 ~/MINGW-packages/mingw-w64-gcc $ /home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/gdc -v Using built-in specs. COLLECT_GCC=C:\DEV\msys64\home\19013692\MINGW-packages\mingw-w64-gcc\src\build-x86_64-w64-mingw32\gcc\gdc.exe Target: x86_64-w64-mingw32 Configured with: ../gcc-5.2.0/configure --prefix=/mingw64 --with-local-prefix=/mingw64/local --build=x86_64-w64-mingw32 --host=x86_64-w64-mingw32 --target=x86_64-w64-mingw32 --with-native-system-header-dir=/mingw64/x86_64-w64-mingw32/include --libexecdir=/mingw64/lib --with-gxx-include-dir=/mingw64/include/c++/5.2.0 --disable-bootstrap --with-arch=x86-64 --with-tune=generic --enable-languages=c,d --enable-shared --enable-static --enable-libatomic --enable-threads=posix --enable-graphite --enable-fully-dynamic-string --enable-libstdcxx-time=yes --disable-libstdcxx-pch --disable-libstdcxx-debug --enable-version-specific-runtime-libs --disable-isl-version-check --enable-lto --enable-libgomp --disable-multilib --enable-checking=release --disable-rpath --disable-win32-registry --disable-nls --disable-werror --disable-symvers --with-libiconv --with-system-zlib --with-gmp=/mingw64 --with-mpfr=/mingw64 --with-mpc=/mingw64 --with-isl=/mingw64 --with-pkgversion='Rev4, Built by MSYS2 project' --with-bugurl=http://sourceforge.net/projects/msys2 --with-gnu-as --with-gnu-ld Thread model: posix gcc version 5.2.0 (Rev4, Built by MSYS2 project) |
November 05, 2015 Re: Trying to generate gdc for mingw-w64(x86 and x64) using msys2 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Vincent R | On Thursday, 5 November 2015 at 14:27:20 UTC, Vincent R wrote:
> [...]
I tried to add a version(MinGW) inside core.sys.posix.sys.types to just declare pthread_key_t but it didn't work because I still have exactly the same error.
So am I supposed to do ?
|
November 05, 2015 Re: Trying to generate gdc for mingw-w64(x86 and x64) using msys2 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Vincent R | Am Thu, 05 Nov 2015 18:42:32 +0000
schrieb Vincent R <lol@dlang.org>:
> On Thursday, 5 November 2015 at 14:27:20 UTC, Vincent R wrote:
> > [...]
>
> I tried to add a version(MinGW) inside core.sys.posix.sys.types
> to just declare pthread_key_t but it didn't work because I still
> have exactly the same error.
> So am I supposed to do ?
Porting druntime to use the posix thread model for MinGW could be quite some work.
A simpler option is to simply build with the win32 thread model. Try to configure gcc with --enable-threads=win32
|
November 06, 2015 Re: Trying to generate gdc for mingw-w64(x86 and x64) using msys2 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Johannes Pfau | On Thursday, 5 November 2015 at 20:26:27 UTC, Johannes Pfau wrote: > Am Thu, 05 Nov 2015 18:42:32 +0000 > schrieb Vincent R <lol@dlang.org>: > >> On Thursday, 5 November 2015 at 14:27:20 UTC, Vincent R wrote: >> > [...] >> >> I tried to add a version(MinGW) inside core.sys.posix.sys.types >> to just declare pthread_key_t but it didn't work because I still >> have exactly the same error. >> So am I supposed to do ? > > Porting druntime to use the posix thread model for MinGW could be quite some work. > > A simpler option is to simply build with the win32 thread model. Try to configure gcc with --enable-threads=win32 I tried with win32 and compilation stopped but don't know why: ... config.status: executing gstdint.h commands /mingw64/x86_64-w64-mingw32/bin/ranlib libgphobos2.a make[4]: Leaving directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/x86_64-w64-mingw32/libphobos/src' make[4]: Entering directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/x86_64-w64-mingw32/libphobos' true "AR_FLAGS=rc" "CC_FOR_BUILD=x86_64-w64-mingw32-gcc" "CC_FOR_TARGET=/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/xgcc -B/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/" "CFLAGS=-g -march=x86-64 -mtune=generic -O2 -pipe" "CXXFLAGS=-g -march=x86-64 -mtune=generic -O2 -pipe" "CFLAGS_FOR_BUILD=-march=x86-64 -mtune=generic -O2 -pipe" "CFLAGS_FOR_TARGET=-g -march=x86-64 -mtune=generic -O2 -pipe" "GDC_FOR_TARGET=/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/gdc -B/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/" "GDC=/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/gdc -B/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/ -L/mingw64/x86_64-w64-mingw32/lib -L/mingw64/lib -isystem /mingw64/x86_64-w64-mingw32/include -isystem /mingw64/include -B/mingw64/x86_64-w64-mingw32/bin/ -B/mingw64/x86_64-w64-mingw32/lib/ -isystem /mingw64/x86_64-w64-mingw32/include -isystem /mingw64/x86_64-w64-mingw32/sys-include " "INSTALL=/usr/bin/install -c" "INSTALL_DATA=/usr/bin/install -c -m 644" "INSTALL_PROGRAM=/usr/bin/install -c" "INSTALL_SCRIPT=/usr/bin/install -c" "LDFLAGS=" "LIBCFLAGS=-g -march=x86-64 -mtune=generic -O2 -pipe" "LIBCFLAGS_FOR_TARGET=-g -march=x86-64 -mtune=generic -O2 -pipe" "MAKE=make" "MAKEINFO=makeinfo --split-size=5000000 --split-size=5000000 " "PICFLAG=" "PICFLAG_FOR_TARGET=" "SHELL=/bin/sh" "RUNTESTFLAGS=" "exec_prefix=/mingw64" "infodir=/mingw64/share/info" "libdir=/mingw64/lib" "includedir=/mingw64/include" "prefix=/mingw64" "tooldir=/mingw64/x86_64-w64-mingw32" "gdc_include_dir=/mingw64/lib/gcc/x86_64-w64-mingw32/5.2.0/include/d" "AR=/mingw64/x86_64-w64-mingw32/bin/ar" "AS=/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/as" "LD=/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/collect-ld" "RANLIB=/mingw64/x86_64-w64-mingw32/bin/ranlib" "NM=/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/nm" "NM_FOR_BUILD=" "NM_FOR_TARGET=/mingw64/x86_64-w64-mingw32/bin/nm" "DESTDIR=" "WERROR=" DO=all multi-do # make make[4]: Leaving directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/x86_64-w64-mingw32/libphobos' make[3]: Leaving directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/x86_64-w64-mingw32/libphobos' make[2]: Leaving directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/x86_64-w64-mingw32/libphobos' make[1]: Leaving directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32' Makefile:871: recipe for target 'all' failed make: *** [all] Error 2 ==> ERROR: A failure occurred in build(). Aborting... |
November 06, 2015 Re: Trying to generate gdc for mingw-w64(x86 and x64) using msys2 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Vincent R | On Friday, 6 November 2015 at 09:37:31 UTC, Vincent R wrote: > On Thursday, 5 November 2015 at 20:26:27 UTC, Johannes Pfau wrote: >> Am Thu, 05 Nov 2015 18:42:32 +0000 >> schrieb Vincent R <lol@dlang.org>: >> >>> On Thursday, 5 November 2015 at 14:27:20 UTC, Vincent R wrote: >>> > [...] >>> >>> I tried to add a version(MinGW) inside core.sys.posix.sys.types >>> to just declare pthread_key_t but it didn't work because I still >>> have exactly the same error. >>> So am I supposed to do ? >> >> Porting druntime to use the posix thread model for MinGW could be quite some work. >> >> A simpler option is to simply build with the win32 thread model. Try to configure gcc with --enable-threads=win32 > > I tried with win32 and compilation stopped but don't know why: > > ... > config.status: executing gstdint.h commands > /mingw64/x86_64-w64-mingw32/bin/ranlib libgphobos2.a > make[4]: Leaving directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/x86_64-w64-mingw32/libphobos/src' > make[4]: Entering directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/x86_64-w64-mingw32/libphobos' > true "AR_FLAGS=rc" "CC_FOR_BUILD=x86_64-w64-mingw32-gcc" "CC_FOR_TARGET=/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/xgcc -B/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/" "CFLAGS=-g -march=x86-64 -mtune=generic -O2 -pipe" "CXXFLAGS=-g -march=x86-64 -mtune=generic -O2 -pipe" "CFLAGS_FOR_BUILD=-march=x86-64 -mtune=generic -O2 -pipe" "CFLAGS_FOR_TARGET=-g -march=x86-64 -mtune=generic -O2 -pipe" "GDC_FOR_TARGET=/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/gdc -B/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/" "GDC=/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/gdc -B/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/ -L/mingw64/x86_64-w64-mingw32/lib -L/mingw64/lib -isystem /mingw64/x86_64-w64-mingw32/include -isystem /mingw64/include -B/mingw64/x86_64-w64-mingw32/bin/ -B/mingw64/x86_64-w64-mingw32/lib/ -isystem /mingw64/x86_64-w64-mingw32/include -isystem /mingw64/x86_64-w64-mingw32/sys-include " "INSTALL=/usr/bin/install -c" "INSTALL_DATA=/usr/bin/install -c -m 644" "INSTALL_PROGRAM=/usr/bin/install -c" "INSTALL_SCRIPT=/usr/bin/install -c" "LDFLAGS=" "LIBCFLAGS=-g -march=x86-64 -mtune=generic -O2 -pipe" "LIBCFLAGS_FOR_TARGET=-g -march=x86-64 -mtune=generic -O2 -pipe" "MAKE=make" "MAKEINFO=makeinfo --split-size=5000000 --split-size=5000000 " "PICFLAG=" "PICFLAG_FOR_TARGET=" "SHELL=/bin/sh" "RUNTESTFLAGS=" "exec_prefix=/mingw64" "infodir=/mingw64/share/info" "libdir=/mingw64/lib" "includedir=/mingw64/include" "prefix=/mingw64" "tooldir=/mingw64/x86_64-w64-mingw32" "gdc_include_dir=/mingw64/lib/gcc/x86_64-w64-mingw32/5.2.0/include/d" "AR=/mingw64/x86_64-w64-mingw32/bin/ar" "AS=/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/as" "LD=/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/collect-ld" "RANLIB=/mingw64/x86_64-w64-mingw32/bin/ranlib" "NM=/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/nm" "NM_FOR_BUILD=" "NM_FOR_TARGET=/mingw64/x86_64-w64-mingw32/bin/nm" "DESTDIR=" "WERROR=" DO=all multi-do # make > make[4]: Leaving directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/x86_64-w64-mingw32/libphobos' > make[3]: Leaving directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/x86_64-w64-mingw32/libphobos' > make[2]: Leaving directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/x86_64-w64-mingw32/libphobos' > make[1]: Leaving directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32' > Makefile:871: recipe for target 'all' failed > make: *** [all] Error 2 > ==> ERROR: A failure occurred in build(). > Aborting... When lookint a bit more to log file I think I found the reason: libtool: compile: /home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/xgcc -B/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/ -L/mingw64/x86_64-w64-mingw32/lib -L/mingw64/lib -isystem /mingw64/x86_64-w64-mingw32/include -isystem /mingw64/include -B/mingw64/x86_64-w64-mingw32/bin/ -B/mingw64/x86_64-w64-mingw32/lib/ -isystem /mingw64/x86_64-w64-mingw32/include -isystem /mingw64/x86_64-w64-mingw32/sys-include -DHAVE_CONFIG_H -I. -I../../../gcc-5.2.0/libbacktrace -I ../../../gcc-5.2.0/libbacktrace/../include -I ../../../gcc-5.2.0/libbacktrace/../libgcc -I ../libgcc -funwind-tables -frandom-seed=atomic.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Werror -fPIC -g -march=x86-64 -mtune=generic -O2 -pipe -c ../../../gcc-5.2.0/libbacktrace/atomic.c -DDLL_EXPORT -DPIC -o .libs/atomic.o ../../../gcc-5.2.0/libbacktrace/atomic.c:1:0: error: -fPIC ignored for target (all code is position independent) [-Werror] /* atomic.c -- Support for atomic functions if not present. ^ /home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/gdc -B/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/./gcc/ -L/mingw64/x86_64-w64-mingw32/lib -L/mingw64/lib -isystem /mingw64/x86_64-w64-mingw32/include -isystem /mingw64/include -B/mingw64/x86_64-w64-mingw32/bin/ -B/mingw64/x86_64-w64-mingw32/lib/ -isystem /mingw64/x86_64-w64-mingw32/include -isystem /mingw64/x86_64-w64-mingw32/sys-include -o std/socketstream.o -Wall -g -frelease -O2 -nostdinc -pipe -Wno-deprecated -I../../../../gcc-5.2.0/libphobos/src -I../../../../gcc-5.2.0/libphobos/src/../libdruntime -I./libdruntime/x86_64-w64-mingw32 -c ../../../../gcc-5.2.0/libphobos/src/std/socketstream.d cc1.exe: all warnings being treated as errors config.status: executing libtool commands Makefile:420: recipe for target 'atomic.lo' failed make[3]: *** [atomic.lo] Error 1 make[3]: Leaving directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/x86_64-w64-mingw32/libbacktrace' Makefile:323: recipe for target 'all' failed make[2]: *** [all] Error 2 make[2]: Leaving directory '/home/19013692/MINGW-packages/mingw-w64-gcc/src/build-x86_64-w64-mingw32/x86_64-w64-mingw32/libbacktrace' Makefile:11495: recipe for target 'all-target-libbacktrace' failed make[1]: *** [all-target-libbacktrace] Error 2 make[1]: *** Waiting for unfinished jobs.... I saw a patch talking about that https://github.com/venix1/MinGW-GDC/blob/master/patches/gcc/0001-Remove-fPIC-for-MinGW.patch so I am going to apply it and start again. |
November 06, 2015 Re: Trying to generate gdc for mingw-w64(x86 and x64) using msys2 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Vincent R | On Friday, 6 November 2015 at 10:07:53 UTC, Vincent R wrote:
> [...]
Ok I was able to generate a gdc compiler(x64) so now I need to test it and I will keep you informed.
|
November 07, 2015 Re: Trying to generate gdc for mingw-w64(x86 and x64) using msys2 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Vincent R | On Friday, 6 November 2015 at 18:15:06 UTC, Vincent R wrote:
> On Friday, 6 November 2015 at 10:07:53 UTC, Vincent R wrote:
>> [...]
>
> Ok I was able to generate a gdc compiler(x64) so now I need to test it and I will keep you informed.
It doesn't work...
$ gdc main.d
gdc.exe: error: CreateProcess: No such file or directory
|
November 07, 2015 Re: Trying to generate gdc for mingw-w64(x86 and x64) using msys2 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Vincent R | On Saturday, 7 November 2015 at 13:43:52 UTC, Vincent R wrote: > On Friday, 6 November 2015 at 18:15:06 UTC, Vincent R wrote: >> On Friday, 6 November 2015 at 10:07:53 UTC, Vincent R wrote: >>> [...] >> >> Ok I was able to generate a gdc compiler(x64) so now I need to test it and I will keep you informed. > > It doesn't work... > $ gdc main.d > gdc.exe: error: CreateProcess: No such file or directory Maybe it has something to do with missing files or something like that because when I run the gdc binary from the output folder (and before being packaged) I don'' have this error but on the other hand nothing happens: $ export PATH=~/MINGW-packages/mingw-w64-gcc/src/mingw64/bin:$PATH $ cd "C:\Developer\cygwin64\home\Vincent\projects\dlang\BonjourProvider\src" $ gdc main.d -o toto.exe $ ls toto.exe ls: cannot access toto.Exe: No such file or directory ok so end of story I am going back to c++, I already lost too much time with this. |
Copyright © 1999-2021 by the D Language Foundation