Annotation of wikisrc/pkgsrc/how_to_use_pkgsrc_on_linux.mdwn, revision 1.4
1.2 schmonz 1: **This page should use cross references to avoid duplicate content. Please help us by cleaning it up. ?**
2:
3: **Contents**
4:
5: [[!toc levels=2]]
6:
1.4 ! asau 7: #See
1.2 schmonz 8:
1.4 ! asau 9: [README.Linux](ftp://ftp.netbsd.org/pub/pkgsrc/current/pkgsrc/bootstrap/README.Linux)
1.2 schmonz 10: #Software requirements
11:
12: Before you can use pkgsrc, you need a few packages installed on your Linux system upfront.
13:
14: * gcc (and libstdc++)
15: * libncurses-devel
16: * zlib and zlib-devel
17: * openssl-devel (optional but required for some packages)
18:
19: The names may vary, depending on what Linux distribution you are using. Also be mindful of the platform you are using (eg. i686 vs. x86_64 - some have different pre-required packages). Also note that some very basic tools such as file, patch, sed, and others are required, as well.
20:
21: #Troubleshooting bootstrap
22: ##Shell's echo command is not BSD-compatible
23:
24: If you see this error
25:
26: ERROR: Your shell's echo command is not BSD-compatible.
27:
28: This error is known to occur if /bin/sh is linked to /bin/dash (recent Ubuntu versions).
29:
30: The fix is to issue the following before commencing bootstrap: export SH=/bin/bash
31: ##ARG_MAX undeclared
32:
33: If bootstrap stops at
34:
35: In file included from glob.c:12:
36: __glob13.c: In function globextend:
37: __glob13.c:836: error: ARG_MAX undeclared (first use in this function)
38:
39: Then apply this patch [1](http://mail-index.netbsd.org/pkgsrc-bugs/2008/06/21/msg026977.html)
40: ##FORTIFY_SOURCE
41:
42: If bootstrap stops at
43:
44: /usr/pkgsrc/bootstrap/work/bmake/arch.c: In function 'Arch_Touch':
45: /usr/pkgsrc/bootstrap/work/bmake/arch.c:1038: warning: ignoring return
46: value of 'fwrite', declared with attribute warn_unused_result
47: *** Error code 1
48:
49: This error occurs because Linux uses -DFORTIFY_SOURCES by default. Bootstrap can be achieved by:
50:
51: CFLAGS="-U_FORTIFY_SOURCE" ./bootstrap
52:
53: ##libncurses not installed
54:
55: If bootstrap stops at
56:
57: ERROR: This package has set PKG_FAIL_REASON:
58: ERROR: No usable termcap library found on the system.
59:
60: Then install the libncurses-dev package
61:
1.3 schmonz 62: On an RPM based system this might be via 'yum install ncurses-devel', and on a debia/ubuntu system 'apt-get install ncurses5-dev'
CVSweb for NetBSD wikisrc <wikimaster@NetBSD.org> software: FreeBSD-CVSweb