Web lists-archives.com

Re: [Mingw-users] Internal compiler error with custom specs file




-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 24/05/17 11:10, John Brown wrote:
> I tried to follow the instructions at 
> http://www.mingw.org/wiki/HOWTO_Use_the_GCC_specs_file
> to let me link to msvcr80 ...
> 
> /mingw/lib/gcc/mingw32/5.3.0/msvcr80 looks like this:
> *msvcrt:
> msvcr80
> [SINGLE BLANK LINE] 
> *msvcrt_version:
> -D__MSVCRT_VERSION__=0x0800
> [SINGLE BLANK LINE] 
> *moldname:
> moldname80
> [SINGLE BLANK LINE]
> 
> At the top of /mingw/lib/gcc/mingw32/5.3.0/specs (created by
> gcc -dumpspecs) I inserted the following lines:
> *msvcrt:
> msvcrt
> [SINGLE BLANK LINE]
> *msvcrt_version:
> [1st BLANK LINE]
> [2nd BLANK LINE]
> *moldname:
> moldname
> [SINGLE BLANK LINE]
> *asm:
> [1st BLANK LINE]
> [2nd BLANK LINE]
> 
> and changed the *cpp and *libgcc definitions as follows:
> *cpp:
> %(msvcrt_version) %{posix:-D_POSIX_SOURCE} %{mthreads:-D_MT} %{pthread:-D_REENTRANT} %{!no-pthread: } 
> 
> *libgcc:
> %{mthreads:-lmingwthrd} -lmingw32      %{static|static-libgcc:-lgcc -lgcc_eh}  %{!static:    %{!static-libgcc:      %{!shared:        %{!shared-libgcc:-lgcc -lgcc_eh}        %{shared-libgcc:-lgcc_s -lgcc}       }      %{shared:-lgcc_s -lgcc}     }   }     -l%(moldname) -lmingwex -l%(msvcrt)
> 
> I am running the latest  MinGW (gcc 5.3.0). Am I doing something wrong?

I can't see anything obvious, but your hello.c compiles and links fine, 
for me, both with and without -specs=msvcr80, and with both my GCC-5.3.0 
mingw32-gcc cross-compiler, and the GCC-6.3.0 variant, with which I am 
currently experimenting.  Clutching at straws: check that your blank 
lines are REALLY blank ... no stray white space, and no rogue CR from 
CRLF line endings, (which I believe should be LF, as $DEITY mandates).

Did you try adding -v to the GCC command line, to verify that your specs 
file modifications are being interpreted correctly?

- -- 
Regards,
Keith.

Public key available from keys.gnupg.net
Key fingerprint: C19E C018 1547 DE50 E1D4 8F53 C0AD 36C6 347E 5A3F
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.20 (GNU/Linux)

iQIcBAEBAgAGBQJZJsNxAAoJEMCtNsY0flo/KesP/iP6qdXYQgV1koQhMGNMn+lA
oW35tnWqGwutVtlxFODP/zEATFhnNbJJ9dt0evMk1R8xoihWOFozsKY7AfYO5pKY
06Tbuqb/znyIeRkEA8Q0EK3VC300nq6STyVPLEwIPAIRf3GD3Wt8PEMW9n2QfAEC
ylsq4fcZT9SgDdewHuyt6OCmUyV2A8HsHXz82EApr3viIww3G2STWZzYC84ryYuq
ec0Jngir8kuIdaERtLcPIqBCm/nYB3bgo6sdmW3XEZr8KAPyA4w0TZ8rhWkutShI
2imIOg4yz7i+QEgR4mhIeJryKX+/oIPxWVvtYcb2ZNHFmS612Q22FOKulmG3CUs3
jpqT5t3S5qwRB1/7Xkyk7TUK2Z9xHRuDYUqSWEBXiBPgwhm3APsfzg06BaCtw9+U
68C0TN3dS9RcGlK8w2JsvHxOyB/kdtnKRIxo1qb8k6gwvmEVqLer3NrqdW+09cYo
Ubouj8iVV7RTj9HMqLKp8CQ0HH/ML5k7HCVIsrnNMeRtiqqQP01aQbVVPQ3u/z7b
DNn2bYs63V7c4sibVwgxy4KVnR+ox/A5cFKFVgvbHluDW6jlOpknBeY5kVzjJ1RY
JjK0oKE6WGgcm1JI4KmfB2HNkkP5nQ0S/mnG3uzLGSPyim7wEC+6FAgv3/O+TsOQ
ti1La7/CWYI5IhJ/0m1u
=2bQd
-----END PGP SIGNATURE-----

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
MinGW-users mailing list
MinGW-users@xxxxxxxxxxxxxxxxxxxxx

This list observes the Etiquette found at 
http://www.mingw.org/Mailing_Lists.
We ask that you be polite and do the same.  Disregard for the list etiquette may cause your account to be moderated.

_______________________________________________
You may change your MinGW Account Options or unsubscribe at:
https://lists.sourceforge.net/lists/listinfo/mingw-users
Also: mailto:mingw-users-request@xxxxxxxxxxxxxxxxxxxxx?subject=unsubscribe