pkgsrc-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
pkg/46779: heimdal 1.5.2nb2 compilation failure on PC's due to a gcc error
>Number: 46779
>Category: pkg
>Synopsis: pkgsrc/security/heimdal 1.5.2nb2 compilation failure on PC's
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: pkg-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Tue Aug 07 12:10:00 +0000 2012
>Originator: Ken'ichi Fukamachi
>Release: NetBSD 5.1.2
>Organization:
NSRG.FML.ORG
>Environment:
System: NetBSD fml.org 5.1.2 NetBSD 5.1.2 (HOME_SERVER) #0: Sat
Feb 18 21:03:22 JST 2012
fukachan%fml.org@localhost:/usr/src/sys/arch/i386/compile/HOME_SERVER i386
Architecture: i386
Machine: i386
>Description:
We cannot comile pkgsrc/security/heimdal 1.5.2nb2 on PC's since the proper
CFLAGS is not given to GCC.
We can see the following errors on several PCs:
pkgsrc/security/heimdal/work/heimdal-1.5.2/base/.libs/libheimbase.so:
undefined reference to `__sync_add_and_fetch_4'
*** Error code 1
For example, NetBSD 5.1.2/i386 (and 5.1.2_PATCH taken and built from
anoncvs) reveals this problem but NetBSD 6.0_BETA/i386 and NetBSD
6.0_BETA/i386 on KVM (with a kvm hack) NOT.
The patch attached below resolves it on the following limited environments:
(1) using GCC on Intel CPU,
(2) pkgsrc/devel/cpuflags works well,
and
(3) maybe NetBSD 5.x.y/i386.
The more smart solution is that pkgsrc/mk framework should be changed
to use cpuflags.mk by default.
Also, the following quick hacks found in pkgsrc may be or should be
changed to cpuflags.mk framework:
.if ${MACHINE_ARCH} == "i386"
CFLAGS+= -march=i486
CXXFLAGS+= -march=i486
.endif
>How-To-Repeat:
build pkgsrc/security/heimdal on NetBSD 5.x.y/i386
>Fix:
diff --exclude=CVS -ubr security/heimdal/Makefile nsrg/heimdal/Makefile
--- security/heimdal/Makefile 2012-08-07 15:53:13.000000000 +0900
+++ nsrg/heimdal/Makefile 2012-08-07 15:18:55.000000000 +0900
@@ -24,6 +24,12 @@
PKGCONFIG_OVERRIDE+= tools/heimdal-gssapi.pc.in
MAKE_ENV+= INSTALL_CATPAGES=no
+# check cpu types
+.if ${MACHINE_ARCH} == "i386"
+BUILD_DEPENDS+= cpuflags-[0-9]*:../../devel/cpuflags
+.endif
+
+
.include "../../mk/bsd.prefs.mk"
.include "options.mk"
@@ -91,6 +97,11 @@
pre-build:
${TOUCH} ${WRKSRC}/po/localefiles
+# check cpu types
+.if exists(${LOCALBASE}/share/mk/cpuflags.mk)
+. include "${LOCALBASE}/share/mk/cpuflags.mk"
+.endif
+
.include "../../databases/sqlite3/buildlink3.mk"
.include "../../devel/readline/buildlink3.mk"
.include "../../security/openssl/buildlink3.mk"
>Unformatted:
since the proper CFLAGS is not given to GCC.
Home |
Main Index |
Thread Index |
Old Index