NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Few notes&questions on NetBSD building and on wedges included by default



> It is needed to support GPT partitions, which is needed to support > 2TB
> drives. What version of NetBSD are you trying to install ?
I tried 6.1.1 nightly, obtained from "ftp://nyftp.netbsd.org";
I'll use MBR then, my system isn't EFI one.

> Why do you need to set HOST_CXX at all ?
Didn't knew it can guess.

> Maybe you should use MKPIC=no ?
No luck. It fails again, and the solution is unknown contrary to -lgcc case. 
(Seems that lgcc is an optional library with useless features, and NetBSD has 
no GCC-dependent code, except for build.sh\makefiles, -lgcc flag could easily 
be deleted. Also, lgcc errors actually do happen when LINKLIB=no, so the other 
solution is to comment it out).
mk.conf configs are tricky and non-straightforward too - if i set MKPIC=no, i 
surely will have problems with pkgsrc packages.
MKPIC sets not only the way of linking, but also the necessity to build shared 
libraries.
I expected "MKLINKLIB=no" + "MKSTATICLIB=no" + "MKPIC=no" to:
1. do not neccessairly install static libraries, but to build them and use them 
for linking
2. build shared libraries, then cp\mv them into the resulted system.
What i got: error, Nbmake lacks some .a library for something, That's because 
MKSTATICLIB configures if the static libs are actually built or not, not only 
if they are installed.

Too complexly made...

But still, even with MKSTATICLIB=yes, i've got errors.
Linking-related configs:
"""
MKDYNAMICROOT=no
MKLINKLIB=no
MKPIC=no
MKPICINSTALL=no
MKPICLIB=yes    # it (+MKLINKLIB=no) may still generate shared libraries, if no 
- we could make them on our own, without position-dependent-code difficulties
MKPIE=no
MKPROFILE=no
MKSTATICLIB=yes
"""

Part of build log:
"""
install ===> lib/../external/bsd/am-utils/lib/libamu
(cd "/usr/nbsrc/external/bsd/am-utils/lib/libamu" &&  HOST_SH=/bin/sh 
AWK=/usr/nbtools/bin/nbawk  /bin/sh /usr/nbsrc/lib/checkver -v 
/usr/nbsrc/external/bsd/am-utils/lib/libamu/shlib_version  -d 
/usr/nbdest/usr/lib amu)
_makedirtarget() {  dir="$1"; shift;  target="$1"; shift;  case "${dir}" in  
/*)        this="${dir}/";  real="${dir}" ;;  .)   this="lib/";  
real="/usr/nbsrc/lib" ;;  *)      this="lib/${dir}/";  
real="/usr/nbsrc/lib/${dir}" ;;  esac;  show=${this:-.};  echo "${target} ===> 
${show%/}${1:+      (with: $@)}";  cd "${real}"  &&  /usr/nbtools/bin/nbmake 
_THISDIR_="${this}" "$@" ${target};  };  _makedirtarget 
../external/bsd/flex/lib install
install ===> lib/../external/bsd/flex/lib
nbmake: don't know how to make /usr/nbdest/usr/lib/libl.a. Stop

nbmake: stopped in /usr/nbsrc/external/bsd/flex/lib

*** Failed target:  install-../external/bsd/flex/lib
*** Failed command: _makedirtarget() { dir="$1"; shift; target="$1"; shift; 
case "${dir}" in /*) this="${dir}/"; real="${dir}" ;; .) this="lib/"; 
real="/usr/nbsrc/lib" ;; *) this="lib/${dir}/"; real="/usr/nbsrc/lib/${dir}" ;; 
esac; show=${this:-.}; echo "${target} ===> ${show%/}${1:+ (with: $@)}"; cd 
"${real}" && /usr/nbtools/bin/nbmake _THISDIR_="${this}" "$@" ${target}; }; 
_makedirtarget ../external/bsd/flex/lib install
*** Error code 2

Stop.
nbmake: stopped in /usr/nbsrc/lib

*** Failed target:  do-lib
*** Failed command: _makedirtarget() { dir="$1"; shift; target="$1"; shift; 
case "${dir}" in /*) this="${dir}/"; real="${dir}" ;; .) this=""; 
real="/usr/nbsrc" ;; *) this="${dir}/"; real="/usr/nbsrc/${dir}" ;; esac; 
show=${this:-.}; echo "${target} ===> ${show%/}${1:+ (with: $@)}"; cd "${real}" 
&& /usr/nbtools/bin/nbmake _THISDIR_="${this}" "$@" ${target}; }; 
_makedirtarget lib install
*** Error code 1

Stop.
nbmake: stopped in /usr/nbsrc

*** Failed target:  build
*** Failed command: _makedirtarget() { dir="$1"; shift; target="$1"; shift; 
case "${dir}" in /*) this="${dir}/"; real="${dir}" ;; .) this=""; 
real="/usr/nbsrc" ;; *) this="${dir}/"; real="/usr/nbsrc/${dir}" ;; esac; 
show=${this:-.}; echo "${target} ===> ${show%/}${1:+ (with: $@)}"; cd "${real}" 
&& /usr/nbtools/bin/nbmake _THISDIR_="${this}" "$@" ${target}; }; 
_makedirtarget . do-lib
*** Error code 1

Stop.
nbmake: stopped in /usr/nbsrc

ERROR: Failed to make build
*** BUILD ABORTED ***
"""

Apparently, it can't handle MKLINKLIB=no again.
Maybe (and probably) i'm doing something wrong. Having support for totally 
static system with shared libraries for pkgsrc would be much apperciated.
Anyways, i've built (not without hacks) "static base"+"dynamic /usr" netbsd 
successfully, and have no problems with building currently, Now i'm figuring 
out how to do partitioning\labeling propertly and dual-booting with linux.


Home | Main Index | Thread Index | Old Index