Bug 208201 - [maintainer update][patch] devel/dyncall: build with -fPIC
Summary: [maintainer update][patch] devel/dyncall: build with -fPIC
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: Thomas Zander
URL:
Keywords: easy, needs-qa, patch
Depends on:
Blocks:
 
Reported: 2016-03-22 13:33 UTC by Tassilo Philipp
Modified: 2016-03-30 17:33 UTC (History)
1 user (show)

See Also:


Attachments
patch adding -fPIC (554 bytes, patch)
2016-03-22 13:33 UTC, Tassilo Philipp
tphilipp: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tassilo Philipp 2016-03-22 13:33:52 UTC
Created attachment 168493 [details]
patch adding -fPIC

Added needed CFLAGS+= -fPIC, bumped PORTREVISION
Comment 1 Thomas Zander freebsd_committer freebsd_triage 2016-03-25 07:16:30 UTC
What problem does it solve? And is it required on every ARCH?
Comment 2 Tassilo Philipp 2016-03-25 10:34:38 UTC
dyncall is often used in scripting language extensions, which are shared libraries. Without fPIC, building those would fail.

dyncall's configure step actually adds -fPIC for all FreeBSD builds, *if* CFLAGS isn't already set by the user. Since the ports tree sets it, the result is that fPIC isn't used.

This simply adds it back for FreeBSD builds.

I *think* this would be required for all the platforms, as dyncall itself would set it for all FreeBSD builds, I wouldn't see why dynamic linking logic would work on arm differently than x86? Maybe I'm missing something?
Comment 3 commit-hook freebsd_committer freebsd_triage 2016-03-30 17:31:46 UTC
A commit references this bug:

Author: riggs
Date: Wed Mar 30 17:30:47 UTC 2016
New revision: 412177
URL: https://svnweb.freebsd.org/changeset/ports/412177

Log:
  Add -fPIC to CFLAGS; bump PORTREVISION

  PIC is required for this port to work properly. However, the
  port's own build system only adds it if CFLAGS is not set in MAKE_ENV.
  This adds -fPIC to the pre-defined set of CFLAGS to ensure the port
  is properly built.

  PR:		208201
  Submitted by:	tphilipp@potion-studios.com (maintainer)

Changes:
  head/devel/dyncall/Makefile
Comment 4 Thomas Zander freebsd_committer freebsd_triage 2016-03-30 17:33:19 UTC
(In reply to Tassilo Philipp from comment #2)

No worries, you are not missing anything. I just wanted to make sure that I fully understand the intention of this patch. Committed, thank you!