Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fail to compile on GCC 7.2, glibc2.26 #21

Open
ghost opened this issue Aug 7, 2017 · 6 comments
Open

Fail to compile on GCC 7.2, glibc2.26 #21

ghost opened this issue Aug 7, 2017 · 6 comments

Comments

@ghost
Copy link

ghost commented Aug 7, 2017

gcc -I. -I/tmp/work/src/gpm/src -DHAVE_CONFIG_H -include headers/config.h -Wall -DSYSCONFDIR=""/etc"" -DSBINDIR=""/usr/sbin"" -D_GNU_SOURCE -O2 -pipe -O2 -pipe -c -o prog/gpm-root.o prog/gpm-root.c
/tmp/work/src/gpm/src/prog/gpm-root.y: In function 'postmenu':
/tmp/work/src/gpm/src/prog/gpm-root.y:1030:32: warning: pointer targets in assignment differ in signedness [-Wpointer-sign]
#define PUTS(s,f,b) for(curr2=s;curr2;PUTC((curr2++),f,b))
^
/tmp/work/src/gpm/src/prog/gpm-root.y:1045:10: note: in expansion of macro 'PUTS'
PUTS(draw->title,draw->head,draw->back);
^~~~
/tmp/work/src/gpm/src/prog/gpm-root.y:1030:32: warning: pointer targets in assignment differ in signedness [-Wpointer-sign]
#define PUTS(s,f,b) for(curr2=s;curr2;PUTC((curr2++),f,b))
^
/tmp/work/src/gpm/src/prog/gpm-root.y:1053:10: note: in expansion of macro 'PUTS'
PUTS(item->name,draw->fore,draw->back); i+=strlen(item->name);
^~~~
/tmp/work/src/gpm/src/prog/gpm-root.y: In function 'main':
/tmp/work/src/gpm/src/prog/gpm-root.y:1200:4: warning: implicit declaration of function '__sigemptyset'; did you mean 'sigemptyset'? [-Wimplicit-function-declaration]
__sigemptyset(&childaction.sa_mask);
^~~~~~~~~~~~~
sigemptyset
gcc -L/tmp/work/src/gpm/src -lm -o prog/gpm-root prog/gpm-root.o lib/libgpm.so.2
prog/gpm-root.o: In function main': gpm-root.c:(.text.startup+0x1fe): undefined reference to __sigemptyset'

@xtaran
Copy link

xtaran commented Aug 7, 2017

Doesn't fail to build with gcc 7.1.0 in Debian Unstable at least. But then again, Debian applies a bunch of patches and is not uptodate (has 1.20.4 packaged) as the package is currently orphaned.

@ghost
Copy link
Author

ghost commented Aug 10, 2017

Working proposal: http://downloads.nutyx.org/x86_64/development/base/gpm/gpm-1.20.7-glibc-2.26-1.patch

@renodr
Copy link

renodr commented Aug 16, 2017

I can confirm this issue under GCC-7.2.0 and glibc-2.26. Both of them have changes that cause the patch by @tnut to be needed. I can confirm this on LFS SVN-20170815-systemd, as this is our release candidate. Whether it was gcc-7.2.0 or glibc-2.26 that caused it to be required, I'm not sure, but what I do know is that modification is required.

@tnut http://wiki.linuxfromscratch.org/blfs/ticket/9616#ticket

@ghost
Copy link
Author

ghost commented Aug 16, 2017 via email

@xtaran
Copy link

xtaran commented Aug 19, 2017

Today, GCC 7.2.0 reached Debian Unstable and gpm still compiles fine on Debian Unstable, i.e. with all the patches shipped in Debian as mentioned before. But then again, Debian still has glibc 2.24. So I assume that either glibc 2.26 is the culprit or one of the patches in Debian fixed this issue preemptively.

(And JFTR as this also changed since my last comment on this ticket: I've adopted the Debian package of gpm together with Samuel Thibault and packaged 1.20.7.)

@ghost
Copy link
Author

ghost commented Aug 19, 2017

glibc is the issue, not gcc, look at my patch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants