Bug 191901 - security/p5-Crypt-SSLeay 0.72 fails to build with CC=clang in /etc/make.conf
Summary: security/p5-Crypt-SSLeay 0.72 fails to build with CC=clang in /etc/make.conf
Status: Closed Unable to Reproduce
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-perl (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-07-16 18:04 UTC by Trond Endrestøl
Modified: 2015-03-08 19:47 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Trond Endrestøl 2014-07-16 18:04:37 UTC
security/p5-Crypt-SSLeay 0.72 fails to build when CC=clang is set in /etc/make.conf.

When perl Makefile.PL is run during the make configure step, gcc is assumed.
Somehow the CC variable isn't propagated.
This happens on stable/{9,10}, and head.

Quick fix:

CONFIGURE_ENV+=	CC=${CC}

Btw, the sed-inplace string probably needs a rework, it assumes the contents of the Makefile.PL of security/p5-Crypt-SSLeay 0.64.
Comment 1 Trond Endrestøl 2014-07-17 10:10:20 UTC
On stable/10 and head I'm in the (bad?) habit of specifying CPYTYPE?=corei7 in /etc/make.conf, which is acceptable for clang, but not for gcc, at least not for /usr/bin/gcc, as gcc rejects -march=corei7 and -mtune=corei7 when run as part of a test compilation done by the Makefile.PL file.

I'm also in the (equally bad?) habit of specifying WITH_GCC=yes and WITH_GNUCXX=yes in /etc/src.conf.

Thus my reason to force the selection of clang as the compiler for security/p5-Crypt-SSLeay.

Maybe it's simply my fault. I don't know if setting CPUTYPE in /etc/make.conf is discouraged. Maybe CPUTYPE should be moved to /etc/src.conf.
Comment 2 John Marino freebsd_committer freebsd_triage 2014-07-20 15:10:03 UTC
over to maintainer
Comment 3 Po-Chuan Hsieh freebsd_committer freebsd_triage 2015-02-27 12:39:01 UTC
I cannot reproduce this problem. I could build this port successfully with CC=clang on my FreeBSD box. I also tried CC=clang36 and it builds without problem.
Comment 4 commit-hook freebsd_committer freebsd_triage 2015-03-08 19:46:14 UTC
A commit references this bug:

Author: adamw
Date: Sun Mar  8 19:45:55 UTC 2015
New revision: 380793
URL: https://svnweb.freebsd.org/changeset/ports/380793

Log:
  Remove obsolete cruft from Makefile that either no longer reflects
  the codebase, or touches code paths that aren't accessed.

  PR:		191901
  Submitted by:	Trond.Endrestol@ximalas.info

Changes:
  head/security/p5-Crypt-SSLeay/Makefile
Comment 5 Adam Weinberger freebsd_committer freebsd_triage 2015-03-08 19:47:29 UTC
I can also confirm that this port respects CC= just fine, so I'm closing this PR.

However, your last line there about the REINPLACE stuff needing rework was quite correct. I yanked the whole thing out (along with other unused variables).

Sorry this PR sat for so long, but thank you for submitting it!