all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [PATCH] configure.ac: Fix FIONREAD check to work with gcc-14 on Solaris
@ 2024-10-08 20:58 Alan Coopersmith
  2024-10-12 13:20 ` Stefan Kangas
  0 siblings, 1 reply; 7+ messages in thread
From: Alan Coopersmith @ 2024-10-08 20:58 UTC (permalink / raw)
  To: emacs-devel; +Cc: Ali Bahrami

Before this fix, it would fail to build with gcc-14 with the error:
conftest.c: In function 'main':
conftest.c:265:11: error: implicit declaration of function 'ioctl'
 [-Wimplicit-function-declaration]
  265 | int foo = ioctl (0, FIONREAD, &foo);
      |           ^~~~~

Solaris documents ioctl() as being defined in <unistd.h>
---
 configure.ac | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/configure.ac b/configure.ac
index 8a5ba7db3d1..947c2827b8e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -7117,6 +7117,9 @@ AC_DEFUN
 			    #ifdef USG5_4
 			    # include <sys/filio.h>
 			    #endif
+			    #ifdef HAVE_UNISTD_H
+			    # include <unistd.h> /* defines ioctl() on Solaris */
+			    #endif
 			  ]],
 			  [[int foo = ioctl (0, FIONREAD, &foo);]])],
 	 [emacs_cv_usable_FIONREAD=yes],
-- 
2.45.2




^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH] configure.ac: Fix FIONREAD check to work with gcc-14 on Solaris
  2024-10-08 20:58 [PATCH] configure.ac: Fix FIONREAD check to work with gcc-14 on Solaris Alan Coopersmith
@ 2024-10-12 13:20 ` Stefan Kangas
  2024-10-12 14:28   ` Eli Zaretskii
  0 siblings, 1 reply; 7+ messages in thread
From: Stefan Kangas @ 2024-10-12 13:20 UTC (permalink / raw)
  To: Alan Coopersmith, emacs-devel; +Cc: Ali Bahrami, Eli Zaretskii

Alan Coopersmith <alan.coopersmith@oracle.com> writes:

> Before this fix, it would fail to build with gcc-14 with the error:
> conftest.c: In function 'main':
> conftest.c:265:11: error: implicit declaration of function 'ioctl'
>  [-Wimplicit-function-declaration]
>   265 | int foo = ioctl (0, FIONREAD, &foo);
>       |           ^~~~~
>
> Solaris documents ioctl() as being defined in <unistd.h>
> ---
>  configure.ac | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/configure.ac b/configure.ac
> index 8a5ba7db3d1..947c2827b8e 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -7117,6 +7117,9 @@ AC_DEFUN
>  			    #ifdef USG5_4
>  			    # include <sys/filio.h>
>  			    #endif
> +			    #ifdef HAVE_UNISTD_H
> +			    # include <unistd.h> /* defines ioctl() on Solaris */
> +			    #endif
>  			  ]],
>  			  [[int foo = ioctl (0, FIONREAD, &foo);]])],
>  	 [emacs_cv_usable_FIONREAD=yes],
> --
> 2.45.2

I guess this should be installed on emacs-30.  Eli, WDYT?



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] configure.ac: Fix FIONREAD check to work with gcc-14 on Solaris
  2024-10-12 13:20 ` Stefan Kangas
@ 2024-10-12 14:28   ` Eli Zaretskii
  2024-10-23 13:48     ` Stefan Kangas
  2024-10-23 14:56     ` Sam James
  0 siblings, 2 replies; 7+ messages in thread
From: Eli Zaretskii @ 2024-10-12 14:28 UTC (permalink / raw)
  To: Stefan Kangas; +Cc: alan.coopersmith, emacs-devel, Ali.Bahrami

> From: Stefan Kangas <stefankangas@gmail.com>
> Date: Sat, 12 Oct 2024 08:20:52 -0500
> Cc: Ali Bahrami <Ali.Bahrami@oracle.com>, Eli Zaretskii <eliz@gnu.org>
> 
> Alan Coopersmith <alan.coopersmith@oracle.com> writes:
> 
> > Before this fix, it would fail to build with gcc-14 with the error:
> > conftest.c: In function 'main':
> > conftest.c:265:11: error: implicit declaration of function 'ioctl'
> >  [-Wimplicit-function-declaration]
> >   265 | int foo = ioctl (0, FIONREAD, &foo);
> >       |           ^~~~~
> >
> > Solaris documents ioctl() as being defined in <unistd.h>
> > ---
> >  configure.ac | 3 +++
> >  1 file changed, 3 insertions(+)
> >
> > diff --git a/configure.ac b/configure.ac
> > index 8a5ba7db3d1..947c2827b8e 100644
> > --- a/configure.ac
> > +++ b/configure.ac
> > @@ -7117,6 +7117,9 @@ AC_DEFUN
> >  			    #ifdef USG5_4
> >  			    # include <sys/filio.h>
> >  			    #endif
> > +			    #ifdef HAVE_UNISTD_H
> > +			    # include <unistd.h> /* defines ioctl() on Solaris */
> > +			    #endif
> >  			  ]],
> >  			  [[int foo = ioctl (0, FIONREAD, &foo);]])],
> >  	 [emacs_cv_usable_FIONREAD=yes],
> > --
> > 2.45.2
> 
> I guess this should be installed on emacs-30.  Eli, WDYT?

I'd prefer on master.  Who knows what addition of unistd.h could cause
to this test?



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] configure.ac: Fix FIONREAD check to work with gcc-14 on Solaris
  2024-10-12 14:28   ` Eli Zaretskii
@ 2024-10-23 13:48     ` Stefan Kangas
  2024-10-23 14:56     ` Sam James
  1 sibling, 0 replies; 7+ messages in thread
From: Stefan Kangas @ 2024-10-23 13:48 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: alan.coopersmith, emacs-devel, Ali.Bahrami

Eli Zaretskii <eliz@gnu.org> writes:

> I'd prefer on master.  Who knows what addition of unistd.h could cause
> to this test?

Thanks.  The patch builds from bootstrap on this macOS machine so I
installed it on master (commit 5e5689a2a40).



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] configure.ac: Fix FIONREAD check to work with gcc-14 on Solaris
  2024-10-12 14:28   ` Eli Zaretskii
  2024-10-23 13:48     ` Stefan Kangas
@ 2024-10-23 14:56     ` Sam James
  2024-10-23 17:54       ` Eli Zaretskii
  1 sibling, 1 reply; 7+ messages in thread
From: Sam James @ 2024-10-23 14:56 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: Stefan Kangas, alan.coopersmith, emacs-devel, Ali.Bahrami

Eli Zaretskii <eliz@gnu.org> writes:

>> From: Stefan Kangas <stefankangas@gmail.com>
>> Date: Sat, 12 Oct 2024 08:20:52 -0500
>> Cc: Ali Bahrami <Ali.Bahrami@oracle.com>, Eli Zaretskii <eliz@gnu.org>
>> 
>> Alan Coopersmith <alan.coopersmith@oracle.com> writes:
>> 
>> > Before this fix, it would fail to build with gcc-14 with the error:
>> > conftest.c: In function 'main':
>> > conftest.c:265:11: error: implicit declaration of function 'ioctl'
>> >  [-Wimplicit-function-declaration]
>> >   265 | int foo = ioctl (0, FIONREAD, &foo);
>> >       |           ^~~~~
>> >
>> > Solaris documents ioctl() as being defined in <unistd.h>
>> > ---
>> >  configure.ac | 3 +++
>> >  1 file changed, 3 insertions(+)
>> >
>> > diff --git a/configure.ac b/configure.ac
>> > index 8a5ba7db3d1..947c2827b8e 100644
>> > --- a/configure.ac
>> > +++ b/configure.ac
>> > @@ -7117,6 +7117,9 @@ AC_DEFUN
>> >  			    #ifdef USG5_4
>> >  			    # include <sys/filio.h>
>> >  			    #endif
>> > +			    #ifdef HAVE_UNISTD_H
>> > +			    # include <unistd.h> /* defines ioctl() on Solaris */
>> > +			    #endif
>> >  			  ]],
>> >  			  [[int foo = ioctl (0, FIONREAD, &foo);]])],
>> >  	 [emacs_cv_usable_FIONREAD=yes],
>> > --
>> > 2.45.2
>> 
>> I guess this should be installed on emacs-30.  Eli, WDYT?
>
> I'd prefer on master.  Who knows what addition of unistd.h could cause
> to this test?

Note that the absence of the include means the configure check gives the
wrong result, it doesn't mean Emacs necessarily fails to build as a
result. It may be built with the wrong configuration.



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] configure.ac: Fix FIONREAD check to work with gcc-14 on Solaris
  2024-10-23 14:56     ` Sam James
@ 2024-10-23 17:54       ` Eli Zaretskii
  2024-10-23 18:10         ` Sam James
  0 siblings, 1 reply; 7+ messages in thread
From: Eli Zaretskii @ 2024-10-23 17:54 UTC (permalink / raw)
  To: Sam James; +Cc: stefankangas, alan.coopersmith, emacs-devel, Ali.Bahrami

> From: Sam James <sam@gentoo.org>
> Cc: Stefan Kangas <stefankangas@gmail.com>,  alan.coopersmith@oracle.com,
>   emacs-devel@gnu.org,  Ali.Bahrami@oracle.com
> Date: Wed, 23 Oct 2024 15:56:33 +0100
> 
> >> I guess this should be installed on emacs-30.  Eli, WDYT?
> >
> > I'd prefer on master.  Who knows what addition of unistd.h could cause
> > to this test?
> 
> Note that the absence of the include means the configure check gives the
> wrong result, it doesn't mean Emacs necessarily fails to build as a
> result. It may be built with the wrong configuration.

I understand.  But Solaris isn't a very important platform for us to
risk screwing other platforms, when we are quite close to a release,
and people who want to build Emacs 30 on Solaris can always apply this
change by hand.



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] configure.ac: Fix FIONREAD check to work with gcc-14 on Solaris
  2024-10-23 17:54       ` Eli Zaretskii
@ 2024-10-23 18:10         ` Sam James
  0 siblings, 0 replies; 7+ messages in thread
From: Sam James @ 2024-10-23 18:10 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: stefankangas, alan.coopersmith, emacs-devel, Ali.Bahrami

Eli Zaretskii <eliz@gnu.org> writes:

>> From: Sam James <sam@gentoo.org>
>> Cc: Stefan Kangas <stefankangas@gmail.com>,  alan.coopersmith@oracle.com,
>>   emacs-devel@gnu.org,  Ali.Bahrami@oracle.com
>> Date: Wed, 23 Oct 2024 15:56:33 +0100
>> 
>> >> I guess this should be installed on emacs-30.  Eli, WDYT?
>> >
>> > I'd prefer on master.  Who knows what addition of unistd.h could cause
>> > to this test?
>> 
>> Note that the absence of the include means the configure check gives the
>> wrong result, it doesn't mean Emacs necessarily fails to build as a
>> result. It may be built with the wrong configuration.
>
> I understand.  But Solaris isn't a very important platform for us to
> risk screwing other platforms, when we are quite close to a release,
> and people who want to build Emacs 30 on Solaris can always apply this
> change by hand.

OK, fair enough.



^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2024-10-23 18:10 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-08 20:58 [PATCH] configure.ac: Fix FIONREAD check to work with gcc-14 on Solaris Alan Coopersmith
2024-10-12 13:20 ` Stefan Kangas
2024-10-12 14:28   ` Eli Zaretskii
2024-10-23 13:48     ` Stefan Kangas
2024-10-23 14:56     ` Sam James
2024-10-23 17:54       ` Eli Zaretskii
2024-10-23 18:10         ` Sam James

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.