Opened 3 years ago

Closed 3 years ago

#61521 closed defect (duplicate)

xemacs @21.4.22: error: implicitly declaring library function 'exit'

Reported by: wealthychef1 Owned by: dstrubbe (David Strubbe)
Priority: Normal Milestone:
Component: ports Version: 2.6.4
Keywords: bigsur catalina Cc:
Port: xemacs

Description (last modified by ryandesign (Ryan Carsten Schmidt))

xemacs fails to install for me using MacPorts 2.6.4 on Big Sur:

--->  Attempting to fetch xemacs-mule-sumo-2010-07-27.tar.gz from https://lil.fr.distfiles.macports.org/xemacs
--->  Verifying checksums for xemacs
--->  Extracting xemacs
--->  Applying patches to xemacs
--->  Configuring xemacs
Error: Failed to configure xemacs, consult /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_editors_xemacs/xemacs/work/xemacs-21.4.22/config.log
Error: Failed to configure xemacs: configure failure: command execution failed
Error: See /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_editors_xemacs/xemacs/main.log for details.
root@Richs-iMac (~ ): grep error /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_editors_xemacs/xemacs/work/xemacs-21.4.22/config.log
configure:2412:10: fatal error: 'features.h' file not found
1 error generated.
#error Not a GNU libc system :-(
clang: error: linker command failed with exit code 1 (use -v to see invocation)
/* Override any gcc2 internal prototype to avoid an error.  */
clang: error: linker command failed with exit code 1 (use -v to see invocation)
configure:3516:10: fatal error: 'a.out.h' file not found
1 error generated.
configure:3516:10: fatal error: 'elf.h' file not found
1 error generated.
configure:3516:10: fatal error: 'cygwin/version.h' file not found
1 error generated.
configure:3516:10: fatal error: 'sys/pstat.h' file not found
1 error generated.
configure:3663:67: error: implicitly declaring library function 'exit' with type 'void (int) __attribute__((noreturn))' [-Werror,-Wimplicit-function-declaration]
1 error generated.
configure:4449:2: error: use of undeclared identifier 'not'
1 error generated.
configure:4519:11: error: implicitly declaring library function 'exit' with type 'void (int) __attribute__((noreturn))' [-Werror,-Wimplicit-function-declaration]
1 warning and 1 error generated.

I'm attaching the referenced log file.

Attachments (1)

config.log (18.3 KB) - added by wealthychef1 3 years ago.

Download all attachments as: .zip

Change History (6)

Changed 3 years ago by wealthychef1

Attachment: config.log added

comment:1 Changed 3 years ago by wealthychef1

Summary: xemacs: configure:2412:10: fatal error: 'features.h' file not foundxemacs-21.4.22: configure:2412:10: fatal error: 'features.h' file not found

comment:2 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)

Port: xemacs added; xemacs-21.4.22 removed
Summary: xemacs-21.4.22: configure:2412:10: fatal error: 'features.h' file not foundxemacs @21.4.22: error: implicitly declaring library function 'exit'

It is perfectly fine and accurate that features.h is not found. configure scripts test for the presence of various files and features to decide how to build on your system. Because it could not find features.h, it inferred that your system is not a GNU libc system, which is correct; macOS does not use glibc.

The real problem is that the writers of the configure script forgot to include essential headers, like those that define the exit() function, hence some later test fail unintentionally with error: implicitly declaring library function 'exit'. That's what needs to be fixed.

comment:3 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)

Description: modified (diff)
Keywords: bigsur catalina added
Owner: set to dstrubbe
Status: newassigned

comment:4 Changed 3 years ago by wealthychef1

Oh, another #include <unistd.h> thing I bet! Happened with compface yesterday.

comment:5 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: duplicate
Status: assignedclosed

unistd.h does not define exit(); stdlib.h does. For each implicit declaration of function, it must be researched what the correct header is and the correct include must be added to the applicable code.

Duplicate of #61383.

Note: See TracTickets for help on using tickets.