Bug 211140 - net/samba43: Fails to link when samba is installed (cannot upgrade) on FreeBSD-11 amd64
Summary: net/samba43: Fails to link when samba is installed (cannot upgrade) on FreeBS...
Status: Closed Overcome By Events
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: amd64 Any
: --- Affects Only Me
Assignee: Timur I. Bakeyev
URL:
Keywords: needs-qa
Depends on:
Blocks:
 
Reported: 2016-07-15 12:05 UTC by Gerard Seibert
Modified: 2017-12-18 04:47 UTC (History)
2 users (show)

See Also:
bugzilla: maintainer-feedback? (timur)
koobs: merge-quarterly?


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gerard Seibert 2016-07-15 12:05:39 UTC
The build of samba43-4.3.11_1 from version samba43-4.3.9 ends with this error message:

cc: error: linker command failed with exit code 1 (use -v to see invocation)
Waf: Leaving directory `/usr/ports/net/samba43/work/samba-4.3.11/bin'
Build failed:  -> task failed (err #1): 
	{task: cc_link async_sock_1.o,async_connect_send_test_2.o -> async_connect_send_test}
*** Error code 1

FreeBSD scorpio.seibercom.net 11.0-CURRENT FreeBSD 11.0-CURRENT #0 r296485: Tue Mar  8 07:04:36 UTC 2016     root@releng2.nyi.freebsd.org:/usr/obj/usr/src/sys/GENERIC  amd64

/usr/ports/net/samba43 # make showconfig
===> The following configuration options are available for samba43-4.3.11_1:
     ACL_SUPPORT=on: File system ACL support
     ADS=on: Active Directory client support
     AD_DC=on: Active Directory Domain Controller support
     AIO_SUPPORT=on: Asyncronous IO support
     CUPS=off: CUPS printing system support
     DEBUG=on: With debug information in the binaries
     DEVELOPER=off: With development support
     DNSUPDATE=on: Dynamic DNS update (require ADS)
     DOCS=on: Build and/or install documentation
     EXP_MODULES=off: Experimental modules
     FAM=on: File Alteration Monitor support
     LDAP=on: LDAP client support
     MANPAGES=off: Build manpages from DOCBOOK templates
     PAM_SMBPASS=off: PAM authentication via passdb backends
     PTHREADPOOL=on: Pthread pool
     QUOTAS=on: Disk quota support
     SYSLOG=on: Syslog logging support
     UTMP=on: UTMP accounting support
====> Options available for the radio DNS: you can only select none or one of them
     NSUPDATE=off: Use samba NSUPDATE utility for AD DC
     BIND99=off: Use bind99 as AD DC DNS server frontend
     BIND910=off: Use bind910 as AD DC DNS server frontend
====> Options available for the radio ZEROCONF: you can only select none or one of them
     AVAHI=off: Zeroconf support via Avahi
     MDNSRESPONDER=off: Zeroconf support via mDNSResponder
===> Use 'make config' to modify these settings

A complete copy of the build log is available here: http://seibercom.net/net_samba43.log
Comment 1 Dimitry Andric freebsd_committer freebsd_triage 2016-07-17 01:32:55 UTC
The interesting part of the log is:

[3362/3871] Linking default/lib/async_req/async_connect_send_test
runner cc default/lib/async_req/async_sock_1.o default/lib/async_req/async_connect_send_test_2.o -o /usr/ports/net/samba43/work/samba-4.3.11/bin/default/lib/async_req/async_connect_send_test -L/usr/local/lib -fstack-protector -pie -Wl,-z,relro,-z,now -lpthread -Wl,-no-undefined -Wl,--export-dynamic -Wl,--as-needed -Wl,-rpath,/usr/ports/net/samba43/work/samba-4.3.11/bin/shared -Wl,-rpath,/usr/ports/net/samba43/work/samba-4.3.11/bin/shared/private -Ldefault/libcli/util -Ldefault/lib/replace -Ldefault/lib/util -Wl,-Bdynamic -liov-buf-samba4 -ltevent-util -lsocket-blocking-samba4 -lreplace-samba4 -lerrors-samba4 -lsamba-debug-samba4 -ltime-basic-samba4 -lrt -lcrypt -ltevent -ltalloc
/usr/local/lib/libtevent-util.so: undefined reference to `map_nt_error_from_unix_common@SAMBA_4.3.9'
/usr/local/lib/libtevent-util.so: undefined reference to `ntstatus_to_werror@SAMBA_4.3.9'
cc: error: linker command failed with exit code 1 (use -v to see invocation)
Comment 2 Gerard Seibert 2016-07-21 10:01:36 UTC
(In reply to Dimitry Andric from comment #1)

I am just wondering if there has been any movement on this issue. I still have samba43-4.3.9 installed, and it is reported as having security vulnerabilities. I would really like to update to the newest version if possible, but have not been able to due to this problem.
Comment 3 Dimitry Andric freebsd_committer freebsd_triage 2016-07-22 22:20:00 UTC
(In reply to Gerard Seibert from comment #2)
> I am just wondering if there has been any movement on this issue. I still
> have samba43-4.3.9 installed, and it is reported as having security
> vulnerabilities. I would really like to update to the newest version if
> possible, but have not been able to due to this problem.

There seems to be an issue with the port that during the linking stage, it finds libraries from its older version in /usr/local/lib, and then complains because obviously some symbols changed.

A quick fix is to delete your old samba43 port first, then build the new samba43 port.

The port maintainer should really investigate why the linking seems to pick up libraries from /usr/local/lib before those in the port working directory.
Comment 4 Gerard Seibert 2016-07-23 14:30:59 UTC
(In reply to Dimitry Andric from comment #3)

Deleting the port first works. It does make doing auto updates problematic though. Hopefully the port maintainer will be able to correct this problem before the next version is released.

I am wondering if this phenomena is occurring with all versions of Samba or just the "43" one.