| @@ -1,16 +1,16 @@ | | | @@ -1,16 +1,16 @@ |
1 | #! /bin/sh | | 1 | #! /bin/sh |
2 | | | 2 | |
3 | # $NetBSD: bootstrap,v 1.316 2022/09/29 02:25:15 charlotte Exp $ | | 3 | # $NetBSD: bootstrap,v 1.317 2022/10/04 11:47:45 jperkin Exp $ |
4 | # | | 4 | # |
5 | # Copyright (c) 2001-2011 Alistair Crooks <agc@NetBSD.org> | | 5 | # Copyright (c) 2001-2011 Alistair Crooks <agc@NetBSD.org> |
6 | # All rights reserved. | | 6 | # All rights reserved. |
7 | # | | 7 | # |
8 | # Redistribution and use in source and binary forms, with or without | | 8 | # Redistribution and use in source and binary forms, with or without |
9 | # modification, are permitted provided that the following conditions | | 9 | # modification, are permitted provided that the following conditions |
10 | # are met: | | 10 | # are met: |
11 | # 1. Redistributions of source code must retain the above copyright | | 11 | # 1. Redistributions of source code must retain the above copyright |
12 | # notice, this list of conditions and the following disclaimer. | | 12 | # notice, this list of conditions and the following disclaimer. |
13 | # 2. Redistributions in binary form must reproduce the above copyright | | 13 | # 2. Redistributions in binary form must reproduce the above copyright |
14 | # notice, this list of conditions and the following disclaimer in the | | 14 | # notice, this list of conditions and the following disclaimer in the |
15 | # documentation and/or other materials provided with the distribution. | | 15 | # documentation and/or other materials provided with the distribution. |
16 | # | | 16 | # |
| @@ -1422,35 +1422,41 @@ fi | | | @@ -1422,35 +1422,41 @@ fi |
1422 | echo ".endif # end pkgsrc settings" >> ${TARGET_MKCONF} | | 1422 | echo ".endif # end pkgsrc settings" >> ${TARGET_MKCONF} |
1423 | echo ".endif # end pkgsrc settings" >> ${BOOTSTRAP_MKCONF} | | 1423 | echo ".endif # end pkgsrc settings" >> ${BOOTSTRAP_MKCONF} |
1424 | | | 1424 | |
1425 | # build and register packages | | 1425 | # build and register packages |
1426 | # usage: build_package <packagedirectory> | | 1426 | # usage: build_package <packagedirectory> |
1427 | build_package() { | | 1427 | build_package() { |
1428 | run_cmd "(cd $pkgsrcdir/$1 && $bmake $make_quiet_flags MAKE_JOBS=${make_jobs} PKG_COMPRESSION=none -DPKG_PRESERVE PKGSRC_KEEP_BIN_PKGS=no MAKECONF=${BOOTSTRAP_MKCONF} install)" | | 1428 | run_cmd "(cd $pkgsrcdir/$1 && $bmake $make_quiet_flags MAKE_JOBS=${make_jobs} PKG_COMPRESSION=none -DPKG_PRESERVE PKGSRC_KEEP_BIN_PKGS=no MAKECONF=${BOOTSTRAP_MKCONF} install)" |
1429 | } | | 1429 | } |
1430 | build_package_nopreserve() { | | 1430 | build_package_nopreserve() { |
1431 | run_cmd "(cd $pkgsrcdir/$1 && $bmake $make_quiet_flags MAKE_JOBS=${make_jobs} PKG_COMPRESSION=none PKGSRC_KEEP_BIN_PKGS=no MAKECONF=${BOOTSTRAP_MKCONF} install)" | | 1431 | run_cmd "(cd $pkgsrcdir/$1 && $bmake $make_quiet_flags MAKE_JOBS=${make_jobs} PKG_COMPRESSION=none PKGSRC_KEEP_BIN_PKGS=no MAKECONF=${BOOTSTRAP_MKCONF} install)" |
1432 | } | | 1432 | } |
1433 | | | 1433 | |
1434 | # | | 1434 | # |
1435 | # cwrappers is special, we don't want to set it as a BOOTSTRAP_PKG but must | | 1435 | # Special packages that we don't want marked with BOOTSTRAP_PKG, but must be |
1436 | # build it (if required) without -DPKG_PRESERVE set so that it can be deleted. | | 1436 | # built (if required) without -DPKG_PRESERVE set so that they can be deleted. |
1437 | # | | 1437 | # |
1438 | use_cwrappers=`(cd $pkgsrcdir/devel/bmake && $bmake show-var VARNAME=_USE_CWRAPPERS)` | | 1438 | use_cwrappers=`(cd $pkgsrcdir/devel/bmake && $bmake show-var VARNAME=_USE_CWRAPPERS)` |
1439 | case "$use_cwrappers" in | | 1439 | case "$use_cwrappers" in |
1440 | yes) | | 1440 | yes) |
1441 | build_package_nopreserve "pkgtools/cwrappers" | | 1441 | build_package_nopreserve "pkgtools/cwrappers" |
1442 | ;; | | 1442 | ;; |
1443 | esac | | 1443 | esac |
| | | 1444 | use_mktools=`(cd $pkgsrcdir/devel/bmake && $bmake show-var VARNAME=_PKGSRC_USE_MKTOOLS)` |
| | | 1445 | case "$use_mktools" in |
| | | 1446 | yes) |
| | | 1447 | build_package_nopreserve "pkgtools/mktools" |
| | | 1448 | ;; |
| | | 1449 | esac |
1444 | | | 1450 | |
1445 | # | | 1451 | # |
1446 | # Please make sure that the following packages and | | 1452 | # Please make sure that the following packages and |
1447 | # only the following packages set BOOTSTRAP_PKG=yes. | | 1453 | # only the following packages set BOOTSTRAP_PKG=yes. |
1448 | # | | 1454 | # |
1449 | echo_msg "Installing packages" | | 1455 | echo_msg "Installing packages" |
1450 | build_package "pkgtools/bootstrap-mk-files" | | 1456 | build_package "pkgtools/bootstrap-mk-files" |
1451 | case "$need_bsd_install" in | | 1457 | case "$need_bsd_install" in |
1452 | yes) | | 1458 | yes) |
1453 | if [ "$use_bsdinstall" = "yes" ]; then | | 1459 | if [ "$use_bsdinstall" = "yes" ]; then |
1454 | build_package "sysutils/bsdinstall" | | 1460 | build_package "sysutils/bsdinstall" |
1455 | else | | 1461 | else |
1456 | build_package "sysutils/install-sh" | | 1462 | build_package "sysutils/install-sh" |