History log of /netbsd-current/usr.sbin/sysinst/main.c
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# 1.33 21-Feb-2024 martin

Defer deletion of any color menu options untill the final menu (in the
selected language) has been loaded.


# 1.32 17-Dec-2023 martin

Add a https transfer method (sharing all host details with the http
transfer). Make this method the default for all downloads.

Try to make sure the binary pkg installation (which runs in a chroot
in the already installed system) can make use of SSL verification.

This does NOT fix the missing SSL verification in most install media
even if using https (due to not fully populated /etc/openssl/certs).


# 1.31 09-Jun-2023 martin

If the install medium does not come with any openssl trusted root certs,
tell ftp(1) not to verify trust chains when doing https downloads.


Revision tags: netbsd-10-base
# 1.30 10-Jul-2022 martin

branches: 1.30.2;
Preparations to make the extended partitioning during normal installation
more usefull - pass an optional install_description to partman().


# 1.29 28-Jan-2022 wiz

sysinst: sync usage with man page


# 1.28 28-Jan-2022 martin

Add an option to set the directory where we look for message catalogs.


Revision tags: cjep_sun2x-base1 cjep_sun2x-base cjep_staticlib_x-base1 cjep_staticlib_x-base
# 1.27 31-Jan-2021 rillig

sysinst: remove trailing whitespace from *.c *.h

In contrast to the messages files, this whitespace is not significant.


# 1.26 19-Aug-2020 msaitoh

s/ be be / be /


# 1.25 12-May-2020 martin

PR 55202: disable swapping if we started it due to low ram


# 1.24 22-Apr-2020 joerg

Don't depend on common symbol definitions.


Revision tags: phil-wifi-20200421 phil-wifi-20200411 phil-wifi-20200406
# 1.23 04-Mar-2020 martin

PR 55045: strlcpy(NULL, ..., 0) considered harmfull in some implementations.


Revision tags: is-mlppp-base
# 1.22 19-Feb-2020 martin

Remove unused "rel" global variable and make the -r option a no-op.


# 1.21 19-Feb-2020 martin

Use strlcpy in a few places to guarnatee 0-terminated strings


# 1.20 16-Jan-2020 martin

Fix /tmp tmpfs handling and on machines with enough RAM default to
creating a /tmp tmpfs with 25% of ram size limit. Suggested by ad@.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-2-RELEASE netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.32 17-Dec-2023 martin

Add a https transfer method (sharing all host details with the http
transfer). Make this method the default for all downloads.

Try to make sure the binary pkg installation (which runs in a chroot
in the already installed system) can make use of SSL verification.

This does NOT fix the missing SSL verification in most install media
even if using https (due to not fully populated /etc/openssl/certs).


# 1.31 09-Jun-2023 martin

If the install medium does not come with any openssl trusted root certs,
tell ftp(1) not to verify trust chains when doing https downloads.


Revision tags: netbsd-10-base
# 1.30 10-Jul-2022 martin

branches: 1.30.2;
Preparations to make the extended partitioning during normal installation
more usefull - pass an optional install_description to partman().


# 1.29 28-Jan-2022 wiz

sysinst: sync usage with man page


# 1.28 28-Jan-2022 martin

Add an option to set the directory where we look for message catalogs.


Revision tags: cjep_sun2x-base1 cjep_sun2x-base cjep_staticlib_x-base1 cjep_staticlib_x-base
# 1.27 31-Jan-2021 rillig

sysinst: remove trailing whitespace from *.c *.h

In contrast to the messages files, this whitespace is not significant.


# 1.26 19-Aug-2020 msaitoh

s/ be be / be /


# 1.25 12-May-2020 martin

PR 55202: disable swapping if we started it due to low ram


# 1.24 22-Apr-2020 joerg

Don't depend on common symbol definitions.


Revision tags: phil-wifi-20200421 phil-wifi-20200411 phil-wifi-20200406
# 1.23 04-Mar-2020 martin

PR 55045: strlcpy(NULL, ..., 0) considered harmfull in some implementations.


Revision tags: is-mlppp-base
# 1.22 19-Feb-2020 martin

Remove unused "rel" global variable and make the -r option a no-op.


# 1.21 19-Feb-2020 martin

Use strlcpy in a few places to guarnatee 0-terminated strings


# 1.20 16-Jan-2020 martin

Fix /tmp tmpfs handling and on machines with enough RAM default to
creating a /tmp tmpfs with 25% of ram size limit. Suggested by ad@.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-2-RELEASE netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.31 09-Jun-2023 martin

If the install medium does not come with any openssl trusted root certs,
tell ftp(1) not to verify trust chains when doing https downloads.


Revision tags: netbsd-10-base
# 1.30 10-Jul-2022 martin

branches: 1.30.2;
Preparations to make the extended partitioning during normal installation
more usefull - pass an optional install_description to partman().


# 1.29 28-Jan-2022 wiz

sysinst: sync usage with man page


# 1.28 28-Jan-2022 martin

Add an option to set the directory where we look for message catalogs.


Revision tags: cjep_sun2x-base1 cjep_sun2x-base cjep_staticlib_x-base1 cjep_staticlib_x-base
# 1.27 31-Jan-2021 rillig

sysinst: remove trailing whitespace from *.c *.h

In contrast to the messages files, this whitespace is not significant.


# 1.26 19-Aug-2020 msaitoh

s/ be be / be /


# 1.25 12-May-2020 martin

PR 55202: disable swapping if we started it due to low ram


# 1.24 22-Apr-2020 joerg

Don't depend on common symbol definitions.


Revision tags: phil-wifi-20200421 phil-wifi-20200411 phil-wifi-20200406
# 1.23 04-Mar-2020 martin

PR 55045: strlcpy(NULL, ..., 0) considered harmfull in some implementations.


Revision tags: is-mlppp-base
# 1.22 19-Feb-2020 martin

Remove unused "rel" global variable and make the -r option a no-op.


# 1.21 19-Feb-2020 martin

Use strlcpy in a few places to guarnatee 0-terminated strings


# 1.20 16-Jan-2020 martin

Fix /tmp tmpfs handling and on machines with enough RAM default to
creating a /tmp tmpfs with 25% of ram size limit. Suggested by ad@.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-2-RELEASE netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.30 10-Jul-2022 martin

Preparations to make the extended partitioning during normal installation
more usefull - pass an optional install_description to partman().


# 1.29 28-Jan-2022 wiz

sysinst: sync usage with man page


# 1.28 28-Jan-2022 martin

Add an option to set the directory where we look for message catalogs.


Revision tags: cjep_sun2x-base1 cjep_sun2x-base cjep_staticlib_x-base1 cjep_staticlib_x-base
# 1.27 31-Jan-2021 rillig

sysinst: remove trailing whitespace from *.c *.h

In contrast to the messages files, this whitespace is not significant.


# 1.26 19-Aug-2020 msaitoh

s/ be be / be /


# 1.25 12-May-2020 martin

PR 55202: disable swapping if we started it due to low ram


# 1.24 22-Apr-2020 joerg

Don't depend on common symbol definitions.


Revision tags: phil-wifi-20200421 phil-wifi-20200411 phil-wifi-20200406
# 1.23 04-Mar-2020 martin

PR 55045: strlcpy(NULL, ..., 0) considered harmfull in some implementations.


Revision tags: is-mlppp-base
# 1.22 19-Feb-2020 martin

Remove unused "rel" global variable and make the -r option a no-op.


# 1.21 19-Feb-2020 martin

Use strlcpy in a few places to guarnatee 0-terminated strings


# 1.20 16-Jan-2020 martin

Fix /tmp tmpfs handling and on machines with enough RAM default to
creating a /tmp tmpfs with 25% of ram size limit. Suggested by ad@.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-2-RELEASE netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.29 28-Jan-2022 wiz

sysinst: sync usage with man page


# 1.28 28-Jan-2022 martin

Add an option to set the directory where we look for message catalogs.


Revision tags: cjep_sun2x-base1 cjep_sun2x-base cjep_staticlib_x-base1 cjep_staticlib_x-base
# 1.27 31-Jan-2021 rillig

sysinst: remove trailing whitespace from *.c *.h

In contrast to the messages files, this whitespace is not significant.


# 1.26 19-Aug-2020 msaitoh

s/ be be / be /


# 1.25 12-May-2020 martin

PR 55202: disable swapping if we started it due to low ram


# 1.24 22-Apr-2020 joerg

Don't depend on common symbol definitions.


Revision tags: phil-wifi-20200421 phil-wifi-20200411 phil-wifi-20200406
# 1.23 04-Mar-2020 martin

PR 55045: strlcpy(NULL, ..., 0) considered harmfull in some implementations.


Revision tags: is-mlppp-base
# 1.22 19-Feb-2020 martin

Remove unused "rel" global variable and make the -r option a no-op.


# 1.21 19-Feb-2020 martin

Use strlcpy in a few places to guarnatee 0-terminated strings


# 1.20 16-Jan-2020 martin

Fix /tmp tmpfs handling and on machines with enough RAM default to
creating a /tmp tmpfs with 25% of ram size limit. Suggested by ad@.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-2-RELEASE netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.27 31-Jan-2021 rillig

sysinst: remove trailing whitespace from *.c *.h

In contrast to the messages files, this whitespace is not significant.


# 1.26 19-Aug-2020 msaitoh

s/ be be / be /


# 1.25 12-May-2020 martin

PR 55202: disable swapping if we started it due to low ram


# 1.24 22-Apr-2020 joerg

Don't depend on common symbol definitions.


Revision tags: phil-wifi-20200421 phil-wifi-20200411 phil-wifi-20200406
# 1.23 04-Mar-2020 martin

PR 55045: strlcpy(NULL, ..., 0) considered harmfull in some implementations.


Revision tags: is-mlppp-base
# 1.22 19-Feb-2020 martin

Remove unused "rel" global variable and make the -r option a no-op.


# 1.21 19-Feb-2020 martin

Use strlcpy in a few places to guarnatee 0-terminated strings


# 1.20 16-Jan-2020 martin

Fix /tmp tmpfs handling and on machines with enough RAM default to
creating a /tmp tmpfs with 25% of ram size limit. Suggested by ad@.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-2-RELEASE netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.26 19-Aug-2020 msaitoh

s/ be be / be /


# 1.25 12-May-2020 martin

PR 55202: disable swapping if we started it due to low ram


# 1.24 22-Apr-2020 joerg

Don't depend on common symbol definitions.


Revision tags: phil-wifi-20200421 phil-wifi-20200411 phil-wifi-20200406
# 1.23 04-Mar-2020 martin

PR 55045: strlcpy(NULL, ..., 0) considered harmfull in some implementations.


Revision tags: is-mlppp-base
# 1.22 19-Feb-2020 martin

Remove unused "rel" global variable and make the -r option a no-op.


# 1.21 19-Feb-2020 martin

Use strlcpy in a few places to guarnatee 0-terminated strings


# 1.20 16-Jan-2020 martin

Fix /tmp tmpfs handling and on machines with enough RAM default to
creating a /tmp tmpfs with 25% of ram size limit. Suggested by ad@.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-2-RELEASE netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.25 12-May-2020 martin

PR 55202: disable swapping if we started it due to low ram


# 1.24 22-Apr-2020 joerg

Don't depend on common symbol definitions.


Revision tags: phil-wifi-20200421 phil-wifi-20200411 phil-wifi-20200406
# 1.23 04-Mar-2020 martin

PR 55045: strlcpy(NULL, ..., 0) considered harmfull in some implementations.


Revision tags: is-mlppp-base
# 1.22 19-Feb-2020 martin

Remove unused "rel" global variable and make the -r option a no-op.


# 1.21 19-Feb-2020 martin

Use strlcpy in a few places to guarnatee 0-terminated strings


# 1.20 16-Jan-2020 martin

Fix /tmp tmpfs handling and on machines with enough RAM default to
creating a /tmp tmpfs with 25% of ram size limit. Suggested by ad@.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-2-RELEASE netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.24 22-Apr-2020 joerg

Don't depend on common symbol definitions.


Revision tags: phil-wifi-20200421 phil-wifi-20200411 phil-wifi-20200406
# 1.23 04-Mar-2020 martin

PR 55045: strlcpy(NULL, ..., 0) considered harmfull in some implementations.


Revision tags: is-mlppp-base
# 1.22 19-Feb-2020 martin

Remove unused "rel" global variable and make the -r option a no-op.


# 1.21 19-Feb-2020 martin

Use strlcpy in a few places to guarnatee 0-terminated strings


# 1.20 16-Jan-2020 martin

Fix /tmp tmpfs handling and on machines with enough RAM default to
creating a /tmp tmpfs with 25% of ram size limit. Suggested by ad@.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-2-RELEASE netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.23 04-Mar-2020 martin

PR 55045: strlcpy(NULL, ..., 0) considered harmfull in some implementations.


# 1.22 19-Feb-2020 martin

Remove unused "rel" global variable and make the -r option a no-op.


# 1.21 19-Feb-2020 martin

Use strlcpy in a few places to guarnatee 0-terminated strings


# 1.20 16-Jan-2020 martin

Fix /tmp tmpfs handling and on machines with enough RAM default to
creating a /tmp tmpfs with 25% of ram size limit. Suggested by ad@.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.22 19-Feb-2020 martin

Remove unused "rel" global variable and make the -r option a no-op.


# 1.21 19-Feb-2020 martin

Use strlcpy in a few places to guarnatee 0-terminated strings


# 1.20 16-Jan-2020 martin

Fix /tmp tmpfs handling and on machines with enough RAM default to
creating a /tmp tmpfs with 25% of ram size limit. Suggested by ad@.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.20 16-Jan-2020 martin

Fix /tmp tmpfs handling and on machines with enough RAM default to
creating a /tmp tmpfs with 25% of ram size limit. Suggested by ad@.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.19 11-Dec-2019 martin

Get rid of the evbarm preliminary menu: do not bother to ask the user
whether this is a RPi - query the FDT instead.


Revision tags: phil-wifi-20191119
# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

branches: 1.17.2;
no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.18 12-Nov-2019 martin

Add options to the various partitioning stages that allow cloning of
alien partitions (optionally including data).


Revision tags: netbsd-9-base
# 1.17 22-Jun-2019 christos

no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.17 22-Jun-2019 christos

no need to initialize fields that are already 0.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


# 1.16 12-Jun-2019 martin

Rework internal data structures and "interfaces to user interface" functions
to get rid of all disklabel assumptions.

Previously (even for GPT partitioning) struct disklabel was used, which
obviously breaks large disk setups. Also many MD parts and parts of the
user interface assumed (a) a struct disklabel is used internally to
store partitioning information and (b) partitions are named 'a' ... $MAXPART.

Get rid of this and replace it with a quite abstract interface that should
be able to deal with all variants in partition storage:

- partitions are stored in a (partly abstract) struct disk_partitions
and most parts of it are only accessed via accessor functions provided
by a "partitioning scheme".

- implement partitioning schemes for MBR, disklabel and GPT (with likely
RDB [amiga] and Apple Partition Map [mac*] to follow soon)

- partitioning schemes may be cascaded, e.g. on x86 when using MBR as
"outer partitions", we have disklabel as "inner partitions".

- all user interface goes via accessor functions in the partitioning scheme,
some of which return pointers to special user interface descriptors
(e.g. to allow editing partition flags, which are scheme specific)

Overall the user interface changes (in this initial step) are minimal but
noticable. A new Anita is needed for automatic test setups - many thanks
to Andreas Gustafsson for lots of early testing and a new Anita version,
and to Manuel Bouyer for cooperation and tests of the Anita release.

This work was sponsored by The NetBSD Foundation, Inc.


Revision tags: phil-wifi-20190609 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8; 1.7.10;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.


Revision tags: pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226
# 1.15 16-Dec-2018 martin

Editor mishap in previous, pointed out by leot


# 1.14 16-Dec-2018 martin

Separate binary sets and binary pkg prefix from the machine, and set
it explicitly for evbarm*, evbmips* and evbsh3 so we get the correct
64bit pkgs on aarch64 and also have working defaults on the other
variants.


Revision tags: pgoyette-compat-1126
# 1.13 07-Nov-2018 martin

Unify handling of CDROM device names.
Skip CDs when looking for install targets (we do not support installing
onto a blueray with UDF).

Fix search for the default CDROM device and the CD we booted from
for ports with nonstandard CDROM device names.


# 1.12 03-Nov-2018 martin

Remove "usage" translations - they never could be displayed as we only select
the language later.
Extend usage display a bit and sync with reality.


Revision tags: pgoyette-compat-1020
# 1.11 06-Oct-2018 martin

Support sets in .tar.xz format


Revision tags: pgoyette-compat-0930
# 1.10 20-Sep-2018 rin

Add NOPARTMAN compile-time option, which drops extended partitioning
support provided by partman.c. It reduces, e.g., about 30KB for
crunched binary in atari install floppy.

OK christos


# 1.9 12-Sep-2018 martin

Try to properly guess a path on the ftp server for pkg binaries
and use that as default.

Assume for $N.99 (current) we can use $N.0. Otherwise strip all
RC*/STABLE* annotations and just use the plain numbers.


# 1.8 11-Sep-2018 martin

Split the host name used for ftp transfers from the one used for http
transfers. This is slightly inconsistent, as directories are still
shared - but this allows us to default to cdn/nycdn for http (which don't
support ftp).


Revision tags: pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2
# 1.7 04-May-2017 sevan

branches: 1.7.8;
Drop main() prototype.


Revision tags: prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107 pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
# 1.6 14-Oct-2014 christos

branches: 1.6.6;
Don't use asctime(localtime(time_t *)) because this is really ctime(time_t *)
and not checking the result of localtime can lead to tears.
Add a safectime() that always returns a good string, and add some debugging
so that we can see if there is indeed something wrong in the new libc time
code.


# 1.5 19-Aug-2014 martin

branches: 1.5.2;
if chdir() fails, try chdir /


# 1.4 19-Aug-2014 martin

Check return value from getenv() before using the value. Pointed out by
coverity scan.


Revision tags: tls-maxphys-base netbsd-7-base tls-earlyentropy-base
# 1.3 06-Aug-2014 martin

branches: 1.3.2; 1.3.4;
Make sysinst use the catalog files installed in /usr/share/sysinst (if
available), fall back to . if not, or use build-in english otherwise.


# 1.2 03-Aug-2014 martin

(Finally) merge a slightly modified version of the 2012 GSoC results
from Eugene Lozovoy: add extended partitioning options to sysinst.
Still needs some testing and polishing, but it now is possible to use GPT
or to create a RAID set from scratch and install onto it.


# 1.1 26-Jul-2014 dholland

Move sysinst sources to usr.sbin.

This commit only physically moves the sources - there are no other
changes, to maximize the probability that this will be treated as a
rename if we ever do manage to migrate away from CVS.

Moving sysinst has been discussed on and off for years and has two
goals: making it easier to work on sysinst, and also making sysinst
available on running systems for use installing chroots and VM images
and other such things. None of the latter is possible yet, but as they
say, one thing at a time.

Doing this now was approved in an impromptu fashion by mrg, riz,
riastradh, me, and groo.