Bug 274196 - sysutils/libcdio: fix build with lld 17
Summary: sysutils/libcdio: fix build with lld 17
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Jason E. Hale
URL:
Keywords:
Depends on:
Blocks: 273753
  Show dependency treegraph
 
Reported: 2023-10-01 12:05 UTC by Dimitry Andric
Modified: 2023-10-06 17:57 UTC (History)
0 users

See Also:
jhale: maintainer-feedback+
jhale: merge-quarterly+


Attachments
sysutils/libcdio: fix build with lld 17 (3.28 KB, patch)
2023-10-01 12:05 UTC, Dimitry Andric
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dimitry Andric freebsd_committer freebsd_triage 2023-10-01 12:05:18 UTC
Building sysutils/libcdio with lld 17 results in the following link errors:

libtool: link: cc -shared  -fPIC -DPIC  .libs/_cdio_generic.o .libs/_cdio_stdio.o .libs/_cdio_stream.o .libs/abs_path.o .libs/aix.o .libs/audio.o .libs/cd_types.o .libs/cdio.o .libs/cdtext.o .libs/device.o .libs/disc.o .libs/ds.o FreeBSD/.libs/freebsd.o FreeBSD/.libs/freebsd_cam.o FreeBSD/.libs/freebsd_ioctl.o .libs/gnu_linux.o image/.libs/bincue.o image/.libs/cdrdao.o .libs/image_common.o image/.libs/nrg.o .libs/logging.o .libs/memory.o mmc/.libs/mmc.o mmc/.libs/mmc_hl_cmds.o mmc/.libs/mmc_ll_cmds.o mmc/.libs/mmc_util.o MSWindows/.libs/aspi32.o MSWindows/.libs/win32_ioctl.o MSWindows/.libs/win32.o .libs/netbsd.o .libs/osx.o .libs/read.o .libs/realpath.o .libs/sector.o .libs/solaris.o .libs/track.o .libs/utf8.o .libs/util.o   -L/usr/local/lib -lm -lcam  -O2 -fstack-protector-strong -Wl,--version-script=libcdio.la.ver -fstack-protector-strong   -Wl,-soname -Wl,libcdio.so.19 -o .libs/libcdio.so.19.0.0
ld: error: version script assignment of 'CDIO_19' to symbol 'cdio_get_default_device_bsdi' failed: symbol not defined
ld: error: version script assignment of 'CDIO_19' to symbol 'cdio_get_devices_bsdi' failed: symbol not defined
ld: error: version script assignment of 'CDIO_19' to symbol 'cdio_have_bsdi' failed: symbol not defined
ld: error: version script assignment of 'CDIO_19' to symbol 'cdio_open_am_bsdi' failed: symbol not defined
ld: error: version script assignment of 'CDIO_19' to symbol 'cdio_open_bsdi' failed: symbol not defined
ld: error: version script assignment of 'CDIO_19' to symbol 'cdio_set_drive_speed' failed: symbol not defined
ld: error: version script assignment of 'CDIO_19' to symbol 'mmc_get_last_lsn' failed: symbol not defined
ld: error: version script assignment of 'CDIO_19' to symbol 'mmc_isrc_track_read_subchannel' failed: symbol not defined
cc: error: linker command failed with exit code 1 (use -v to see invocation)

There are a number of symbols in libcdio's linker version scripts which are no longer defined, so remove them.
Comment 1 Dimitry Andric freebsd_committer freebsd_triage 2023-10-01 12:05:47 UTC
Created attachment 245352 [details]
sysutils/libcdio: fix build with lld 17
Comment 2 Jason E. Hale freebsd_committer freebsd_triage 2023-10-02 21:06:06 UTC
Looks good to me. Please also merge to quarterly.
Comment 3 commit-hook freebsd_committer freebsd_triage 2023-10-06 17:52:01 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=dca37f39f47dae363f7f2aa636e3e8b963752350

commit dca37f39f47dae363f7f2aa636e3e8b963752350
Author:     Dimitry Andric <dim@FreeBSD.org>
AuthorDate: 2023-10-01 12:02:24 +0000
Commit:     Dimitry Andric <dim@FreeBSD.org>
CommitDate: 2023-10-06 17:48:55 +0000

    sysutils/libcdio: fix build with lld 17

    Building sysutils/libcdio with lld 17 results in the following link
    errors:

      libtool: link: cc -shared  -fPIC -DPIC  .libs/_cdio_generic.o .libs/_cdio_stdio.o .libs/_cdio_stream.o .libs/abs_path.o .libs/aix.o .libs/audio.o .libs/cd_types.o .libs/cdio.o .libs/cdtext.o .libs/device.o .libs/disc.o .libs/ds.o FreeBSD/.libs/freebsd.o FreeBSD/.libs/freebsd_cam.o FreeBSD/.libs/freebsd_ioctl.o .libs/gnu_linux.o image/.libs/bincue.o image/.libs/cdrdao.o .libs/image_common.o image/.libs/nrg.o .libs/logging.o .libs/memory.o mmc/.libs/mmc.o mmc/.libs/mmc_hl_cmds.o mmc/.libs/mmc_ll_cmds.o mmc/.libs/mmc_util.o MSWindows/.libs/aspi32.o MSWindows/.libs/win32_ioctl.o MSWindows/.libs/win32.o .libs/netbsd.o .libs/osx.o .libs/read.o .libs/realpath.o .libs/sector.o .libs/solaris.o .libs/track.o .libs/utf8.o .libs/util.o   -L/usr/local/lib -lm -lcam  -O2 -fstack-protector-strong -Wl,--version-script=libcdio.la.ver -fstack-protector-strong   -Wl,-soname -Wl,libcdio.so.19 -o .libs/libcdio.so.19.0.0
      ld: error: version script assignment of 'CDIO_19' to symbol 'cdio_get_default_device_bsdi' failed: symbol not defined
      ld: error: version script assignment of 'CDIO_19' to symbol 'cdio_get_devices_bsdi' failed: symbol not defined
      ld: error: version script assignment of 'CDIO_19' to symbol 'cdio_have_bsdi' failed: symbol not defined
      ld: error: version script assignment of 'CDIO_19' to symbol 'cdio_open_am_bsdi' failed: symbol not defined
      ld: error: version script assignment of 'CDIO_19' to symbol 'cdio_open_bsdi' failed: symbol not defined
      ld: error: version script assignment of 'CDIO_19' to symbol 'cdio_set_drive_speed' failed: symbol not defined
      ld: error: version script assignment of 'CDIO_19' to symbol 'mmc_get_last_lsn' failed: symbol not defined
      ld: error: version script assignment of 'CDIO_19' to symbol 'mmc_isrc_track_read_subchannel' failed: symbol not defined
      cc: error: linker command failed with exit code 1 (use -v to see invocation)

    There are a number of symbols in libcdio's linker version scripts which
    are no longer defined, so remove them.

    PR:             274196
    Approved by:    jhale (maintainer)
    MFH:            2023Q4

 .../files/patch-lib_driver_cdio__private.h (new)   | 13 +++++
 .../files/patch-lib_driver_libcdio.sym (new)       | 66 ++++++++++++++++++++++
 .../files/patch-lib_iso9660_libiso9660.sym (new)   | 10 ++++
 3 files changed, 89 insertions(+)