GNU bug report logs - #18666
emacs-24.3.94: Debian GNU/kFreeBSD 7 (wheezy) build issue

Previous Next

Package: emacs;

Reported by: "Nelson H. F. Beebe" <beebe <at> math.utah.edu>

Date: Wed, 8 Oct 2014 15:47:01 UTC

Severity: important

Found in version 24.3.94

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 18666 in the body.
You can then email your comments to 18666 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#18666; Package emacs. (Wed, 08 Oct 2014 15:47:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to "Nelson H. F. Beebe" <beebe <at> math.utah.edu>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Wed, 08 Oct 2014 15:47:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: "Nelson H. F. Beebe" <beebe <at> math.utah.edu>
To: submit <at> debbugs.gnu.org
Subject: emacs-24.3.94: Debian GNU/kFreeBSD 7 (wheezy) build issue
Date: Wed, 8 Oct 2014 05:53:10 -0600 (MDT)
Package: emacs
Version: 24.3.94
Severity: important

An emacs-24.3.94 build on Debian GNU/kFreeBSD 7 (wheezy) x86-64 with
CC=c99 fails with this error:

    /usr/bin/c99 -c  -Demacs -I. -I. -I../lib -I./../lib \
        -I/usr/include/freetype2 \
	-I/usr/include/freetype2 -MMD -MF deps/process.d -MP \
	-I/usr/uumath/include  process.c
    process.c:177:1: error: static declaration of `accept4' follows
		     non-static declarationmake[1]: Leaving directory
		     `/local/build/c99/emacs-24.3.94/src'

The problem is this code in the indicated system header file:

    #ifdef __USE_GNU
    /* Similar to 'accept' but takes an additional parameter to specify flags.

       This function is a cancellation point and therefore not marked with
       __THROW.  */
    extern int accept4 (int __fd, __SOCKADDR_ARG __addr,
			socklen_t *__restrict __addr_len, int __flags);
    #endif

The solution was simple:

    % diff src/process.c.~1~ src/process.c
    176c176
    < static int
    ---
    > /* static */ int

I restarted the build, and it completed successfully, as did the final
"make install" step.

-------------------------------------------------------------------------------
- Nelson H. F. Beebe                    Tel: +1 801 581 5254                  -
- University of Utah                    FAX: +1 801 581 4148                  -
- Department of Mathematics, 110 LCB    Internet e-mail: beebe <at> math.utah.edu  -
- 155 S 1400 E RM 233                       beebe <at> acm.org  beebe <at> computer.org -
- Salt Lake City, UT 84112-0090, USA    URL: http://www.math.utah.edu/~beebe/ -
-------------------------------------------------------------------------------




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#18666; Package emacs. (Wed, 08 Oct 2014 16:53:02 GMT) Full text and rfc822 format available.

Message #8 received at 18666 <at> debbugs.gnu.org (full text, mbox):

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: "Nelson H. F. Beebe" <beebe <at> math.utah.edu>, 18666 <at> debbugs.gnu.org
Subject: Re: emacs-24.3.94: Debian GNU/kFreeBSD 7 (wheezy) build issue
Date: Wed, 08 Oct 2014 09:52:11 -0700
[Message part 1 (text/plain, inline)]
On 10/08/2014 04:53 AM, Nelson H. F. Beebe wrote:
> The solution was simple:
>
>      % diff src/process.c.~1~ src/process.c
>      176c176
>      < static int
>      ---
>      > /* static */ int
>

Thanks, but I'd rather not do that, as it might override some system's 
accept4 function which other parts of that system's library might depend on.

Does the attached alternative patch work for you?  Or, to save you some 
time, since I can log into the Utah VMs perhaps you can give me the 
current list of VMs so that I can try it out myself?  I don't know which 
VM is the one that illustrates the problem.

Thanks.

[kfreebsd.diff (text/x-patch, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#18666; Package emacs. (Wed, 08 Oct 2014 17:11:02 GMT) Full text and rfc822 format available.

Message #11 received at 18666 <at> debbugs.gnu.org (full text, mbox):

From: Wolfgang Jenkner <wjenkner <at> inode.at>
To: "Nelson H. F. Beebe" <beebe <at> math.utah.edu>
Cc: 18666 <at> debbugs.gnu.org
Subject: Re: bug#18666: emacs-24.3.94: Debian GNU/kFreeBSD 7 (wheezy) build
 issue
Date: Wed, 08 Oct 2014 19:10:13 +0200
On Wed, Oct 08 2014, Nelson H. F. Beebe wrote:

> An emacs-24.3.94 build on Debian GNU/kFreeBSD 7 (wheezy) x86-64 with

So it runs a FreeBSD 9 kernel[1].

> CC=c99 fails with this error:
>
>     /usr/bin/c99 -c  -Demacs -I. -I. -I../lib -I./../lib \
>         -I/usr/include/freetype2 \
> 	-I/usr/include/freetype2 -MMD -MF deps/process.d -MP \
> 	-I/usr/uumath/include  process.c
>     process.c:177:1: error: static declaration of `accept4' follows
> 		     non-static declarationmake[1]: Leaving directory
> 		     `/local/build/c99/emacs-24.3.94/src'
>
> The problem is this code in the indicated system header file:
>
>     #ifdef __USE_GNU
>     /* Similar to 'accept' but takes an additional parameter to specify flags.
>
>        This function is a cancellation point and therefore not marked with
>        __THROW.  */
>     extern int accept4 (int __fd, __SOCKADDR_ARG __addr,
> 			socklen_t *__restrict __addr_len, int __flags);
>     #endif

On FreeBSD 10, accept(2) states[2] in HISTORY

     The accept4() system call appeared in FreeBSD 10.0.

So I guess the bug is that the declaration is nevertheless visible in
the glibc header file used on your Debian system.

The other possibility is that the Debian developers implemented it on
their own, but it somehow fails the configure test (you could check
config.log).

I found a short mailing list thread about this[3].

[1] https://wiki.debian.org/Debian_GNU/kFreeBSD_FAQ#Q._What_version_of_kFreeBSD_is_supported.3F

[2] https://www.freebsd.org/cgi/man.cgi?query=accept4&apropos=0&sektion=0&manpath=FreeBSD+10.0-RELEASE&arch=default&format=html

[3] https://lists.debian.org/debian-bsd/2013/09/msg00157.html




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#18666; Package emacs. (Fri, 10 Oct 2014 16:16:01 GMT) Full text and rfc822 format available.

Message #14 received at 18666 <at> debbugs.gnu.org (full text, mbox):

From: Glenn Morris <rgm <at> gnu.org>
To: Paul Eggert <eggert <at> cs.ucla.edu>
Cc: 18666 <at> debbugs.gnu.org
Subject: Re: bug#18666: emacs-24.3.94: Debian GNU/kFreeBSD 7 (wheezy) build
 issue
Date: Fri, 10 Oct 2014 12:15:19 -0400
Experience suggests there might be no answer to your question (unless
you got one off-list), so if you think there is a safe way to solve this
in emacs-24, I suggest you just go for it and mark this as done.




Reply sent to Paul Eggert <eggert <at> cs.ucla.edu>:
You have taken responsibility. (Fri, 10 Oct 2014 18:05:02 GMT) Full text and rfc822 format available.

Notification sent to "Nelson H. F. Beebe" <beebe <at> math.utah.edu>:
bug acknowledged by developer. (Fri, 10 Oct 2014 18:05:03 GMT) Full text and rfc822 format available.

Message #19 received at 18666-done <at> debbugs.gnu.org (full text, mbox):

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: Glenn Morris <rgm <at> gnu.org>
Cc: 18666-done <at> debbugs.gnu.org
Subject: Re: bug#18666: emacs-24.3.94: Debian GNU/kFreeBSD 7 (wheezy) build
 issue
Date: Fri, 10 Oct 2014 11:03:52 -0700
Glenn Morris wrote:
> if you think there is a safe way to solve this
> in emacs-24, I suggest you just go for it and mark this as done

Thanks, done as emacs-24 bzr 117570.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 08 Nov 2014 12:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 9 years and 169 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.