Bug 194360

Summary: devel/linux-c6-devtools: can't build C++ code
Product: Ports & Packages Reporter: Brooks Davis <brooks>
Component: Individual Port(s)Assignee: Johannes Jost Meixner <xmj>
Status: Closed FIXED    
Severity: Affects Only Me CC: xmj
Priority: --- Flags: brooks: maintainer-feedback? (emulation)
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
Add libstdc++-devel-4.4.7-4.el6.i686.rpm to port
none
fix C++ compilation and general shared linkage none

Description Brooks Davis freebsd_committer freebsd_triage 2014-10-14 22:58:27 UTC
Created attachment 148314 [details]
Add libstdc++-devel-4.4.7-4.el6.i686.rpm to port

The linux-c6-devtools port allows C programs, but not C++ programs to be built due to missing C++ headers.  Add libstdc++-devel-4.4.7-4.el6.i686.rpm solves this problem.

The attached patch does this and the s/@dirrmtry/@dir/ switch.
Comment 1 Bugzilla Automation freebsd_committer freebsd_triage 2014-10-14 22:58:27 UTC
Auto-assigned to maintainer emulation@FreeBSD.org
Comment 2 Johannes Jost Meixner freebsd_committer freebsd_triage 2014-10-15 06:37:27 UTC
I'll take it.
Comment 3 Brooks Davis freebsd_committer freebsd_triage 2014-10-15 20:04:03 UTC
Created attachment 148348 [details]
fix C++ compilation and general shared linkage

In addition to the missing C++ headers, I tripped on the problem that /contrib/linux/usr/lib/gcc/i686-redhat-linux/4.4.4/libgcc_s.so was a symlink to /lib/libgcc_s.so.1 which can't be linked into a linux program.  This patch replaces it with a link to /compat/linux/lib/libgcc_s.so.1 so programs can be linked.
Comment 4 Johannes Jost Meixner freebsd_committer freebsd_triage 2014-10-16 07:12:19 UTC
Thanks for the amended patch.

As it were, I'm not sure you need to explicitly import 
bsd.port.pre.mk
before the post-install section, and
bsd.port.post.mk afterwards.
Comment 5 commit-hook freebsd_committer freebsd_triage 2014-10-17 14:21:57 UTC
A commit references this bug:

Author: xmj
Date: Fri Oct 17 14:21:38 UTC 2014
New revision: 371057
URL: https://svnweb.freebsd.org/changeset/ports/371057

Log:
  devel/linux-c6-devtools: add libstdc++

  - Add c6 libstdc++ RPM, so that Linux C++ code can be compiled.

  PR:		194360
  Differential Revision:	https://reviews.freebsd.org/D948
  Submitted by:	brooks
  Approved by:	swills (mentor)

Changes:
  head/devel/linux-c6-devtools/Makefile
  head/devel/linux-c6-devtools/distinfo.i686
  head/devel/linux-c6-devtools/pkg-plist
Comment 6 Johannes Jost Meixner freebsd_committer freebsd_triage 2014-10-17 15:07:48 UTC
Committed. Thanks!