Bug 221766 - arabic/libitl: build invokes linker with unintended commandline arguments
Summary: arabic/libitl: build invokes linker with unintended commandline arguments
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-ports-bugs (Nobody)
Keywords: patch, patch-ready
Depends on:
Blocks: 214864
  Show dependency treegraph
Reported: 2017-08-24 14:38 UTC by Ed Maste
Modified: 2017-12-27 02:35 UTC (History)
1 user (show)

See Also:

patch-libitl-0.8.0 (8.37 KB, patch)
2017-11-04 23:12 UTC, Carlos J. Puga Medina
no flags Details | Diff
patch-libitl-0.8.0 (8.53 KB, patch)
2017-12-09 16:58 UTC, Carlos J. Puga Medina
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ed Maste freebsd_committer 2017-08-24 14:38:27 UTC
From http://package18.nyi.freebsd.org/data/headamd64PR214864-default/2017-08-22_08h39m11s/logs/errors/ar-libitl-0.7.0_1.log when attempting to link with lld:

==> Create symbolic links for library generation...
test -d ../../build/itl/  || mkdir -p ../../build/itl/  || exit 1;
ln -sf ../../prayertime/src/prayer.h ../../build/itl/prayer.h
ln -sf ../prayertime/src/prayer.o ../../build/prayer.o
ln -sf ../prayertime/src/astro.o ../../build/astro.o
ld build/*.o -fstack-protector -shared -lm -lc -soname=libitl.so.0 -o build/libitl.so.0.0.7
ld: error: unknown argument: -fstack-protector
ld: error: unable to find library -lm
ld: error: unable to find library -lc
*** Error code 1

This package's build invokes ld with -fstack-protector, a flag intended to be passed to the compiler. GNU linkers interpret -fstack-protector as a command to create an auxiliary filter library for "stack-protector":

0x000000007ffffffd AUXILIARY            Auxiliary library: [stack-protector]

The link commandline should omit -fstack-protector, and could also pass in -L/usr/lib for future compatibility with LLD
Comment 1 Carlos J. Puga Medina freebsd_committer 2017-11-04 23:12:16 UTC
Created attachment 187745 [details]

patch to update libitl to 0.8.0 (code refactoring and several bug fixes)

Upstream switched to cmake to build libitl.

Comment 2 Carlos J. Puga Medina freebsd_committer 2017-11-17 22:30:19 UTC
Ed, does the libitl update solve the issue?

Waiting to hear from you soon,

Comment 3 Carlos J. Puga Medina freebsd_committer 2017-12-09 16:58:01 UTC
Created attachment 188660 [details]

- Add DOCS option
Comment 4 commit-hook freebsd_committer 2017-12-09 17:36:01 UTC
A commit references this bug:

Author: cpm
Date: Sat Dec  9 17:35:52 UTC 2017
New revision: 455868
URL: https://svnweb.freebsd.org/changeset/ports/455868

  - Update to 0.8.0
  - Switch to USE_GITHUB
  - Switch to USES=cmake
  - Drop unneeded patches
  - Add DOCS option
  - Update comment and WWW in pkg-descr
  - Take maintainership

  Changelog: https://github.com/arabeyes-org/ITL/releases/tag/v0.8.0

  PR:		221766
  Submitted by:	cpm

Comment 5 Ed Maste freebsd_committer 2017-12-18 16:18:35 UTC
Yes, 0.8.0 builds for me with lld as /usr/bin/ld, thank you.