Undefined symbols _utimensat on older macOS

Skip to first unread message

Ryan Schmidt

Nov 15, 2020, 9:58:57 PM11/15/20
to tup-users
Hi, I'm the maintainer of tup in MacPorts. tup 0.7.10 doesn't build on older versions of macOS. For example on OS X 10.10:

Undefined symbols for architecture x86_64:
  "_utimensat", referenced from:
      _tup_fs_utimens in fuse_fs.o
ld: symbol(s) not found for architecture x86_64

As far as I know, utimensat did not appear until macOS 10.13.

I see that you have compatibility code for utimensat but build.sh does not include it on macOS.

Mike Shal

Nov 22, 2020, 8:16:12 PM11/22/20
to tup-...@googlegroups.com
Thanks for maintaining it in MacPorts!

I'm not sure how authoritative this list is, but it looks like 10.10 reached end-of-life in 2017: https://en.wikipedia.org/wiki/MacOS_version_history

If 10.13 is indeed the oldest version that is still supported by Apple as the list suggests, I feel like that is a reasonable target to be the oldest version supported by new releases of tup.

That said, if it's an easy patch in tup to support older macOS versions, I don't see why it couldn't be merged.

Thanks again,

Ryan Schmidt

Nov 25, 2020, 9:16:54 AM11/25/20
to tup-...@googlegroups.com

On Nov 22, 2020, at 19:15, Mike Shal wrote:
Just because Apple stops supporting a version of macOS does not mean that it automatically becomes impossible to install or compile software on it. Installing new open source software is a great way to extend the life of an old computer.

Since you already have a compatibility implementation of utimensat I assume it should be trivial to include it on older versions of macOS or any other OS that doesn't have it built-in.

I'm not familiar with your build system so I can't suggest a patch. If you were using an autotools-based build system, I would expect that you would have a configure test to check for the presence of utimensat, and if it is not present, then you would use your compatibility implementation. Since you are not using autotools perhaps whatever build system you use has an equivalent concept that could be employed.

Reply all
Reply to author
0 new messages