pkgsrc-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
pkg/57838: Solaris 10 pkgsrc bootstrap broken due to libnbcompat bug in strndup.c
>Number: 57838
>Category: pkg
>Synopsis: Solaris 10 pkgsrc bootstrap broken due to libnbcompat bug in strndup.c
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: pkg-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Fri Jan 12 02:30:00 +0000 2024
>Originator: Dan Clough
>Release: pkgsrc current 2024/01/06
>Organization:
N/A
>Environment:
SunOS <hostname_redacted> 5.10 Generic_147440-01 sun4u sparc SUNW,UltraAX-i2
>Description:
Attempting to bootstrap pkgsrc on Solaris 10 fails due to an unchecked dependency in the libnbcompat strndup.c file.
The version of strndup.c shipping in libnbcompat includes sys/cdefs.h without checking HAVE_SYS_CDEFS_H.
The configure script correctly identifies that the system does not have sys/cdefs.h.
>How-To-Repeat:
Following steps given in https://cdn.netbsd.org/pub/pkgsrc/current/pkgsrc/bootstrap/README.Solaris:
1. On a fresh Solaris 10 system, install the GCC 4 binary package from the OpenCSW repository.
2. Download and extract pkgsrc.tar.gz to /usr/
3. cd /usr/pkgsrc/bootstrap
4. Run "env CC=/opt/csw/bin/gcc ./bootstrap --abi=64"
5. Observe the failure when bootstrap attempts to compile libnbcompat
>Fix:
In pkgtools/libnbcompat/files/strndup.c, wrap line 39 with an ifdef:
+#ifdef HAVE_SYS_CDEFS_H
#include <sys/cdefs.h>
+#endif
Home |
Main Index |
Thread Index |
Old Index