Opened 10 years ago

Closed 4 years ago

#45734 closed defect (fixed)

gettext @0.19.3: compiling areadlink.c fails with "use of undeclared identifier 'AT_FDCWD'"

Reported by: chockenbrocht@… Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 2.3.2
Keywords: Cc:
Port: gettext

Description (last modified by larryv (Lawrence Velázquez))

There is a linking error that I've been having with building gettext, which happens to be a dependency for pretty much everything.

Relevant line from log:

:info:build areadlink.c:55:24: error: use of undeclared identifier 'AT_FDCWD'
:info:build   return careadlinkat (AT_FDCWD, filename, NULL, 0, NULL, careadlinkatcwd);

log attached.

Attachments (5)

main.log (10.4 KB) - added by chockenbrocht@… 10 years ago.
build log for gettext
main.2.log (255.8 KB) - added by chockenbrocht@… 10 years ago.
config.log (9.8 KB) - added by chockenbrocht@… 10 years ago.
config.2.log (777.3 KB) - added by chockenbrocht@… 10 years ago.
config.3.log (2.0 MB) - added by chockenbrocht@… 10 years ago.

Change History (22)

Changed 10 years ago by chockenbrocht@…

Attachment: main.log added

build log for gettext

comment:1 Changed 10 years ago by larryv (Lawrence Velázquez)

Description: modified (diff)
Keywords: yosemite gettext removed
Owner: changed from macports-tickets@… to ryandesign@…
Summary: gettext fails--linking errorgettext @0.19.3: compiling areadlink.c fails with "use of undeclared identifier 'AT_FDCWD'"

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

This was not a clean build attempt. Please clean and try again and attach the new main.log file.

Changed 10 years ago by chockenbrocht@…

Attachment: main.2.log added

comment:3 in reply to:  2 Changed 10 years ago by chockenbrocht@…

Replying to ryandesign@…:

This was not a clean build attempt. Please clean and try again and attach the new main.log file.

Sorry about that--forgot that I tried to build twice after cleaning. I think I was trying something. FWIW, the function sig AT_FDCWD is referenced in "fcntl.h" of the linux kernel--though this is a common c library for most *nix systems so I'm confused as to why the signature is missing.

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

Could you attach the config.log files too? There are several of them in the work directory; please indicate which one is from which directory.

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

I've compared your latest log with mine, and there are hundreds of differences in capabilities that my system correctly detected that yours didn't. I'm hoping comparing the config.log files will explain why.

Also, please let me know what version of Xcode you're using. If you're running less than 6.1, you should upgrade to 6.1, and also ensure you've installed the matching Xcode command line tools.

comment:6 Changed 10 years ago by chockenbrocht@…

Hi, sorry I didn't get back quicker, I've been out all day. I'm attaching the logs.

Changed 10 years ago by chockenbrocht@…

Attachment: config.log added

Changed 10 years ago by chockenbrocht@…

Attachment: config.2.log added

Changed 10 years ago by chockenbrocht@…

Attachment: config.3.log added

comment:7 Changed 10 years ago by chockenbrocht@…

Hi, so the first one is from the base build directory, the second from gettext-tools build dir (which is a subdir) and gettext-runtime (another subdir) the third attached... I'm actually not familiar with the build procedure that MacPorts uses, so I'm assuming that these were gathered dependencies or related thigns and built around the same time.

As far as Xcode, I'm on 6.1, and all my system software that isn't compiled binaries is up to date.

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

Multiple config.logs is not unique to MacPorts; it's unique to the gettext build system.

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

The best suggestion I can offer at this time is reinstall the Xcode command line tools, because the symbols your logs say are missing are defined by files in /usr/include, which is part of the command line tools package. If "xcode-select --install" says they're already installed, download the standalone Xcode command line tools installer from the Apple developer web site and install that.

comment:10 in reply to:  9 Changed 10 years ago by chockenbrocht@…

I've reinstalled it, but to no avail. Will look further into /usr/include stuff.

comment:11 Changed 10 years ago by chockenbrocht@…

And the files are even there, and I found the AT_FDCWD macro (defined as -2, no less), but it remains more mysterious as to why it's not linking.

comment:12 in reply to:  description ; Changed 10 years ago by chockenbrocht@…

Resolved. The migration instructions should be changed because the version handles it, and the perl script given in the tut breaks the stuff, such as gettext.

Replying to chockenbrocht@…:

There is a linking error that I've been having with building gettext, which happens to be a dependency for pretty much everything.

Relevant line from log:

:info:build areadlink.c:55:24: error: use of undeclared identifier 'AT_FDCWD'
:info:build   return careadlinkat (AT_FDCWD, filename, NULL, 0, NULL, careadlinkatcwd);

log attached.

comment:13 in reply to:  12 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Replying to chockenbrocht@…:

Resolved. The migration instructions should be changed because the version handles it, and the perl script given in the tut breaks the stuff, such as gettext.

Could you elaborate on the problem with the migration instructions?

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

For example, what do you mean "because the version handles it"? and what "perl script" are you referring to?

comment:15 Changed 10 years ago by chockenbrocht@…

The current version of MacPorts "updated the database of binaries", which is, I'm assuming rebuilt everything. The perl script is actually a tcl script, so, mistake on my part. It is found here: https://svn.macports.org/repository/macports/contrib/restore_ports/restore_ports.tcl, the link given on the "Migration" page.

comment:16 in reply to:  15 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Replying to chockenbrocht@…:

The current version of MacPorts "updated the database of binaries", which is, I'm assuming rebuilt everything.

No; MacPorts keeps track of which files that are installed are binaries (vs those that are architecture-agnostic). It runs a check for this after every port installation or upgrade. This has nothing to do with the necessity for rebuilding ports after upgrading the OS X version, which is what the Migration page describes.

comment:17 Changed 4 years ago by kencu (Ken)

Resolution: fixed
Status: newclosed

fixed at some point: currently builds on all systems.

Note: See TracTickets for help on using tickets.