#66998 closed defect (fixed)

gnutls +universal fails on arm64

Reported by: Liontooth (David Liontooth) Owned by: Schamschula (Marius Schamschula)
Priority: Normal Milestone:
Component: ports Version: 2.8.1
Keywords: Cc:
Port: gnutls

Description

sudo port install kde4-baseapps kdelibs4 kde4-runtime calls for gnutls and fetches

gnutls-3.7.9_1+universal.darwin_22.arm64-x86_64.tbz2

Straight gnutls without universal builds fine -- is the universal version actually needed? In which port file is gnutls +universal listed?

gnutls +universal fails to build on Apple silicon M2 Ventura 13.1 with this error:

:info:build Undefined symbols for architecture x86_64:
:info:build   "_rpl_malloc", referenced from:
:info:build       _gnutls_secure_malloc in mem.o
:info:build       _gnutls_malloc in mem.o
:info:build       _gnutls_system_mutex_init in threads.o
:info:build       _gnutls_idna_reverse_map in str-idna.o
:info:build       _gnutls_load_file in file.o
:info:build       _mdir_name in libgnu.a(dirname-lgpl.o)
:info:build       _hash_initialize in libgnu.a(hash.o)
:info:build       ...
:info:build   "_rpl_realloc", referenced from:
:info:build       _gnutls_realloc in mem.o
:info:build       __gnutls_fread_file in libgnu.a(read-file.o)
:info:build       _rpl_getdelim in libgnu.a(getdelim.o)
:info:build       _printf_parse in libgnu.a(printf-parse.o)
:info:build       _vasnprintf in libgnu.a(vasnprintf.o)
:info:build       _gnutls_realloc_zero in libcrypto.a(init.o)
:info:build ld: symbol(s) not found for architecture x86_64

Attachments (1)

main.log (1.7 MB) - added by Liontooth (David Liontooth) 21 months ago.
Build file

Download all attachments as: .zip

Change History (12)

comment:1 Changed 21 months ago by Schamschula (Marius Schamschula)

Cc: Schamschula removed
Owner: set to Schamschula
Status: newassigned

Providing a universal variant isn't my choice.

There are dependent ports that require it. Searching for these may be difficult, as there are some ports that just don't support arm64, which will need some intermediate dependency that depends on gnutls.

That having been said, I personally never build universal variants. Hence, I haven't run into this error.

I'm curious if the change from the universal 1.0 to universal 1.1 PortGroup caused this issue. See: [205879d66a328f24c9349f082d694f3976a07efe/macports-ports]

Last edited 21 months ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

Changed 21 months ago by Liontooth (David Liontooth)

Attachment: main.log added

Build file

comment:2 Changed 21 months ago by kencu (Ken)

worked fine for me:

% port -v installed gnutls | grep active
  gnutls @3.7.9_1+universal (active) requested_variants='+universal' platform='darwin 22' archs='arm64 x86_64' date='2023-02-12T16:36:51-0800'

but I built it two weeks ago. I'll try again...

Last edited 21 months ago by kencu (Ken) (previous) (diff)

comment:3 Changed 21 months ago by kencu (Ken)

You need universal variants if you want KDE, as KDE can only build as x86_64.

comment:4 Changed 21 months ago by Marius Schamschula <mschamschula@…>

In 121c442cdc26ed87e97282b5ecb66538afe13e34/macports-ports (master):

gnutls: further cleanup from major version bump

Hopefully also fix universal build
See: #66998

comment:5 Changed 21 months ago by Liontooth (David Liontooth)

I built with the previous version of the gnutls portfile with universal 1.0 and it built fine. I haven't tried your latest revision!

comment:6 Changed 21 months ago by kencu (Ken)

no, still broken with this latest commit.

I also rebuilt it with muniversal-1.0 and it worked fine. I'll see if I can try that again after your latest commit.

comment:7 Changed 21 months ago by kencu (Ken)

yes, reverting the change to muniversal-1.1 allows building universal successfully.

comment:8 Changed 21 months ago by Schamschula (Marius Schamschula)

I'll revert the change.

comment:9 Changed 21 months ago by Marius Schamschula <mschamschula@…>

comment:10 Changed 21 months ago by Liontooth (David Liontooth)

Just confirming version 3.7.9_2 works; please close.

comment:11 Changed 21 months ago by Schamschula (Marius Schamschula)

Resolution: fixed
Status: assignedclosed
Note: See TracTickets for help on using tickets.