April 08, 2021
On Thursday, 8 April 2021 at 02:13:10 UTC, Preetpal wrote:
> On Wednesday, 7 April 2021 at 23:01:41 UTC, Imperatorn wrote:
>> On Wednesday, 7 April 2021 at 22:37:33 UTC, Preetpal wrote:
>>> On Tuesday, 6 April 2021 at 05:49:16 UTC, Imperatorn wrote:
>>>> Just FYI, we're getting closer, but have some stuff not working properly with std.stdio.
>>>>
>>>> You can use it now but with printf:
>>>> https://gofile.io/d/mdCW2c
>>>
>>> That's great. Thanks for the progress update.
>>
>> Just got a version working with std.stdio as well. Try it out and report any bugs:
>> https://github.com/Imperatorn/gcc/releases
>
> How are you building this on Windows? Are you doing anything beyond running ./configure in the repo from the mingw-w64 command line and running the build process?
>
> I think there probably were some other artifacts related to your build environment that were on your path that were necessary to run the GDC build that you did not package in the release.

Sorry, I forgot to say, you cannot currently build it without special configuration. I'll upload a build script later.

I just meant running the executables and see what errors you get. I see that I missed to upload some files, I'll fix that.

I also want to take the opportunity to thank Iain Buclaw and Adam D Ruppe for making this possible!

Stay tuned
April 08, 2021
On Thursday, 8 April 2021 at 02:29:41 UTC, Preetpal wrote:
> On Thursday, 8 April 2021 at 02:22:41 UTC, Preetpal wrote:
>> On Thursday, 8 April 2021 at 02:18:13 UTC, Adam D. Ruppe wrote:
>>> On Thursday, 8 April 2021 at 02:05:56 UTC, Preetpal wrote:
>>>> gdc.exe: fatal error: cannot execute 'd21': CreateProcess: No such file or directory
>>>> compilation terminated.
>>>
>>> The PATH needs to include the normal mingw64 bin path as well as the path for gdc.
>>
>> Well I do have mingw64 on my path, but his build does not work. I might try to build GDC from source at a later time to test the release.
>
> To be clear, I tried it with mingw64 on my path and with a clean environment (running command prompt without mingw64 on my path).

These are the steps you need to follow:

1. Download MSYS2 (https://www.msys2.org/) or "choco install msys2" if you have chocolatey

2. Start msys2 and paste the following:
wget https://gist.githubusercontent.com/Imperatorn/7d37f22140ea5b2c80dee5a86ffff2a3/raw/761ea945c28586f5c6bbc2e09d93a27383701da8/build.sh && ./build.sh

3. Wait :)

4. Pray...

5. Celebrate!? The build script has hopefully run and will open the bin directory with explorer
April 09, 2021
On Thursday, 8 April 2021 at 19:10:03 UTC, Imperatorn wrote:
> On Thursday, 8 April 2021 at 02:29:41 UTC, Preetpal wrote:
>> On Thursday, 8 April 2021 at 02:22:41 UTC, Preetpal wrote:
>>> [...]
>>
>> To be clear, I tried it with mingw64 on my path and with a clean environment (running command prompt without mingw64 on my path).
>
> These are the steps you need to follow:
>
> 1. Download MSYS2 (https://www.msys2.org/) or "choco install msys2" if you have chocolatey
>
> 2. Start msys2 and paste the following:
> wget https://gist.githubusercontent.com/Imperatorn/7d37f22140ea5b2c80dee5a86ffff2a3/raw/761ea945c28586f5c6bbc2e09d93a27383701da8/build.sh && ./build.sh
>
> 3. Wait :)
>
> 4. Pray...
>
> 5. Celebrate!? The build script has hopefully run and will open the bin directory with explorer

Very good job. I am playing around with it. I am not so much familiar with GDC. Looks like there is no something like "rdmd" in /opt/mingw64/bin? I want to test it to build dub.
April 09, 2021
On Friday, 9 April 2021 at 17:32:51 UTC, Ferhat Kurtulmuş wrote:
> On Thursday, 8 April 2021 at 19:10:03 UTC, Imperatorn wrote:
>> On Thursday, 8 April 2021 at 02:29:41 UTC, Preetpal wrote:
>>> [...]
>>
>> These are the steps you need to follow:
>>
>> 1. Download MSYS2 (https://www.msys2.org/) or "choco install msys2" if you have chocolatey
>>
>> 2. Start msys2 and paste the following:
>> wget https://gist.githubusercontent.com/Imperatorn/7d37f22140ea5b2c80dee5a86ffff2a3/raw/761ea945c28586f5c6bbc2e09d93a27383701da8/build.sh && ./build.sh
>>
>> 3. Wait :)
>>
>> 4. Pray...
>>
>> 5. Celebrate!? The build script has hopefully run and will open the bin directory with explorer
>
> Very good job. I am playing around with it. I am not so much familiar with GDC. Looks like there is no something like "rdmd" in /opt/mingw64/bin? I want to test it to build dub.

I think there should be a gdmd executable. My compilations process did not yield one.
April 09, 2021
On Friday, 9 April 2021 at 17:45:12 UTC, Ferhat Kurtulmuş wrote:
> On Friday, 9 April 2021 at 17:32:51 UTC, Ferhat Kurtulmuş wrote:
>> On Thursday, 8 April 2021 at 19:10:03 UTC, Imperatorn wrote:
>>> [...]
>>
>> Very good job. I am playing around with it. I am not so much familiar with GDC. Looks like there is no something like "rdmd" in /opt/mingw64/bin? I want to test it to build dub.
>
> I think there should be a gdmd executable. My compilations process did not yield one.

Did you succeed in building?
April 09, 2021

On Friday, 9 April 2021 at 18:13:31 UTC, Imperatorn wrote:

>

On Friday, 9 April 2021 at 17:45:12 UTC, Ferhat Kurtulmuş wrote:

>

On Friday, 9 April 2021 at 17:32:51 UTC, Ferhat Kurtulmuş wrote:

>

On Thursday, 8 April 2021 at 19:10:03 UTC, Imperatorn wrote:

>

[...]

Very good job. I am playing around with it. I am not so much familiar with GDC. Looks like there is no something like "rdmd" in /opt/mingw64/bin? I want to test it to build dub.

I think there should be a gdmd executable. My compilations process did not yield one.

Did you succeed in building?

Yes. "hello world" compiles and runs. Now I am trying to compile dub. I found https://github.com/D-Programming-GDC/GDMD. but I decided to use dub for building dub with
somefolder/bin/dub.exe build --compiler=gdc which is easier for me.

it complained about missing d21 executable. So, I copied it (~430 mb) from gcc-source/build/gcc into /opt/mingw64/bin which is in my $PATH.

Now it says:

dub 1.25.0+commit.17.g79e312d0: building configuration "application"...
d:/msys64/opt/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/11.0.1/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lcurl
collect2.exe: error: ld returned 1 exit status

I have curl, libcurl, libcurl-devel, etc. installed though:

$ pacman -Ss curl
mingw32/mingw-w64-i686-curl 7.74.0-2
    Command line tool and library for transferring data with URLs. (mingw-w64)
mingw32/mingw-w64-i686-flickcurl 1.26-2
    Flickcurl is a C library for the Flickr API (mingw-w64)
mingw64/mingw-w64-x86_64-curl 7.74.0-2 [installed]
    Command line tool and library for transferring data with URLs. (mingw-w64)
mingw64/mingw-w64-x86_64-flickcurl 1.26-2
    Flickcurl is a C library for the Flickr API (mingw-w64)
msys/curl 7.74.0-4 [installed]
    Multi-protocol file transfer utility
msys/libcurl 7.74.0-4 (libraries) [installed]
    Multi-protocol file transfer library (runtime)
msys/libcurl-devel 7.74.0-4 (development) [installed]
    Libcurl headers and libraries
April 09, 2021
On Friday, 9 April 2021 at 18:37:23 UTC, Ferhat Kurtulmuş wrote:
> On Friday, 9 April 2021 at 18:13:31 UTC, Imperatorn wrote:
>> [...]
>
> Yes. "hello world" compiles and runs. Now I am trying to compile dub. I found https://github.com/D-Programming-GDC/GDMD. but I decided to use dub for building dub with
> ```somefolder/bin/dub.exe build --compiler=gdc ``` which is easier for me.
>
> [...]

I can take a look in a couple of hours, in the meantime, read this:
https://stackoverflow.com/questions/335928/ld-cannot-find-an-existing-library
April 10, 2021

On Friday, 9 April 2021 at 18:42:21 UTC, Imperatorn wrote:

>

On Friday, 9 April 2021 at 18:37:23 UTC, Ferhat Kurtulmuş wrote:

>

On Friday, 9 April 2021 at 18:13:31 UTC, Imperatorn wrote:

>

[...]

Yes. "hello world" compiles and runs. Now I am trying to compile dub. I found https://github.com/D-Programming-GDC/GDMD. but I decided to use dub for building dub with
somefolder/bin/dub.exe build --compiler=gdc which is easier for me.

[...]

I can take a look in a couple of hours, in the meantime, read this:
https://stackoverflow.com/questions/335928/ld-cannot-find-an-existing-library

The below is the output of "gdc -print-search-dirs" command. As you can see, there are search paths beginning with "d:/msys64". I think they should be /d/msys64 or just /msys64 in msys2. That is the problem.


libraries:
  d:/msys64/opt/mingw64/lib/gcc/x86_64-w64-mingw32/11.0.1/
  d:/msys64/opt/mingw64/lib/gcc/
  d:/msys64/opt/mingw64/x86_64-w64-mingw32/lib/x86_64-w64-mingw32/11.0.1/
  d:/msys64/opt/mingw64/x86_64-w64-mingw32/lib/
  d:/msys64/opt/mingw64/lib/x86_64-w64-mingw32/11.0.1/
  d:/msys64/opt/mingw64/lib/
  /mingw/lib/x86_64-w64-mingw32/11.0.1/
  /mingw/lib/
  d:/msys64/opt/mingw64/x86_64-w64-mingw32/lib/
  d:/msys64/opt/mingw64/lib/
  /mingw/lib/
April 10, 2021

On Saturday, 10 April 2021 at 10:59:58 UTC, Ferhat Kurtulmuş wrote:

>

On Friday, 9 April 2021 at 18:42:21 UTC, Imperatorn wrote:

>

[...]

The below is the output of "gdc -print-search-dirs" command. As you can see, there are search paths beginning with "d:/msys64". I think they should be /d/msys64 or just /msys64 in msys2. That is the problem.

[...]

Did you install msys on D:? Does it work if you manually supply -L?

April 10, 2021

On Saturday, 10 April 2021 at 12:31:27 UTC, Imperatorn wrote:

>

On Saturday, 10 April 2021 at 10:59:58 UTC, Ferhat Kurtulmuş wrote:

>

On Friday, 9 April 2021 at 18:42:21 UTC, Imperatorn wrote:

>

[...]

The below is the output of "gdc -print-search-dirs" command. As you can see, there are search paths beginning with "d:/msys64". I think they should be /d/msys64 or just /msys64 in msys2. That is the problem.

[...]

Did you install msys on D:? Does it work if you manually supply -L?

Actually, I did a workaround by supplying the LIBRARY_PATH manually. Now curl is found. But I am having some linker errors related to winsockets (missing symbols). I will share the linker errors when I back home.