#19889 closed defect (fixed)

ncftp-3.2.7 FTBFS with gcc14

Reported by: Joe Locash Owned by: Douglas R. Reno
Priority: normal Milestone: 12.2
Component: BOOK Version: git
Severity: normal Keywords:
Cc:

Description

Use CFLAGS+="-std=gnu89" when building

Change History (9)

comment:1 by Xi Ruoyao, 10 months ago

But Fedora builds it fine with GCC 14.

And generally using -std=gnu89 is a bad thing unless the package is abandoned or the upstream explicitly uses it.

Last edited 10 months ago by Xi Ruoyao (previous) (diff)

comment:2 by Xi Ruoyao, 10 months ago

Alright, Fedora do use -std=gnu89 but in a cryptic way I didn't recognized.

comment:3 by Xi Ruoyao, 10 months ago

It seems a better workaround is

sed 's/def HAVE_STDLIB_H/ 1/' -i configure

It seems HAVE_STDLIB_H comes nowhere.

comment:4 by Xi Ruoyao, 10 months ago

sed '/extern select/extern int select/' -i configure
CPPFLAGS=-DHAVE_STDLIB_H CC=gcc ./configure --prefix=/usr --sysconfdir=/etc

works for me.

comment:5 by Xi Ruoyao, 10 months ago

I've sent a report to the upstream but they don't have a public bug tracker.

comment:6 by Douglas R. Reno, 10 months ago

Owner: changed from blfs-book to Douglas R. Reno
Status: newassigned

in reply to:  4 ; comment:7 by Joe Locash, 10 months ago

Replying to Xi Ruoyao:

sed '/extern select/extern int select/' -i configure
CPPFLAGS=-DHAVE_STDLIB_H CC=gcc ./configure --prefix=/usr --sysconfdir=/etc

works for me.

hmm, not for me:

$ sed '/extern select/extern int select/' -i configure
sh: line 1: xtern: command not found

a better sed might be:

sed -i 's/def HAVE_STDLIB_H/ 1/;s/extern select/extern int select/' configure

no other changes needed

in reply to:  7 comment:8 by Xi Ruoyao, 10 months ago

Replying to Joe Locash:

Replying to Xi Ruoyao:

sed '/extern select/extern int select/' -i configure
CPPFLAGS=-DHAVE_STDLIB_H CC=gcc ./configure --prefix=/usr --sysconfdir=/etc

works for me.

hmm, not for me:

$ sed '/extern select/extern int select/' -i configure
sh: line 1: xtern: command not found

Oops, missing a "s".

comment:9 by Douglas R. Reno, 10 months ago

Resolution: fixed
Status: assignedclosed
Note: See TracTickets for help on using tickets.