Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[bug #58172] Precompiled header test broken with GCC >= 9

2 views
Skip to first unread message

Yavor Doganov

unread,
Apr 14, 2020, 7:17:22 AM4/14/20
to Yavor Doganov, bug-g...@gnu.org
URL:
<https://savannah.gnu.org/bugs/?58172>

Summary: Precompiled header test broken with GCC >= 9
Project: GNUstep
Submitted by: yavor
Submitted on: Tue 14 Apr 2020 02:17:13 PM EEST
Category: Makefiles
Severity: 3 - Normal
Item Group: Bug
Status: None
Privacy: Public
Assigned to: None
Open/Closed: Open
Discussion Lock: Any

_______________________________________________________

Details:

The script config-precomp-test/run-test.sh puts $LIBS before the program which
makes it fail with GCC 9 or later (where -Wl,--as-needed is implied):


$ LC_ALL=C gcc-8 -lobjc config-precomp-test.m
$ LC_ALL=C gcc-9 -lobjc config-precomp-test.m
/usr/bin/ld: /tmp/cczUhnH0.o: in function `main':
config-precomp-test.m:(.text+0x24): undefined reference to `objc_get_class'
/usr/bin/ld: config-precomp-test.m:(.text+0x36): undefined reference to
`objc_msg_lookup'
/usr/bin/ld: /tmp/cczUhnH0.o: in function `__objc_gnu_init':
config-precomp-test.m:(.text+0x59): undefined reference to
`__objc_exec_class'
collect2: error: ld returned 1 exit status
$ LC_ALL=C gcc-9 config-precomp-test.m -lobjc
$


Patch attached.



_______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Tue 14 Apr 2020 02:17:13 PM EEST Name:
0001-Amend-precompiled-header-test-so-that-it-works-with-.patch Size: 3KiB
By: yavor

<http://savannah.gnu.org/bugs/download.php?file_id=48832>

_______________________________________________________

Reply to this item at:

<https://savannah.gnu.org/bugs/?58172>

_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/


Fred Kiefer

unread,
May 9, 2020, 1:05:54 PM5/9/20
to Fred Kiefer, Yavor Doganov, bug-g...@gnu.org
Update of bug #58172 (project gnustep):

Status: None => Fixed
Assigned to: None => FredKiefer
Open/Closed: Open => Closed

_______________________________________________________

Follow-up Comment #1:

I committed your patch although it did not make any difference for me with gcc
9.3.1.

Yavor Doganov

unread,
Jun 11, 2020, 1:02:25 PM6/11/20
to Fred Kiefer, Yavor Doganov, bug-g...@gnu.org
Follow-up Comment #2, bug #58172 (project gnustep):

Thanks. It looks like this is a Debian-specific modification to GCC; sorry
for the misleading information.
0 new messages