live-bootstrap/sysc/perl-5.32.1/perl-5.32.1.sh
fosslinux 5c88f1c87f Add sysb and sysc scaffolding.
Now that we have the Linux Kernel built, we move to a full-disk (rather
than initramfs) setup in sysc. However, we cannot assume the seed kernel
has support for mounting hard drives. So, first we need to kexec into
sysb, which is used as a jumping off point to create the hard drive for
sysc.

Additionally, since 2.6.16 does not have support for on-demand initramfs
(initramfs must be built into kernel), we will have to rebuild the linux
kernel within sysb without the initramfs.

All of this process is not performed for chroot mode. Instead, we skip
sysb and jump straight to sysc, copying over appropriate data.

The python scripts have been changed slightly. Each sys* inherits
SysGeneral, which contains various functions which are not specific to
any sys* and simplifies those files. rootfs now also handles sysb and
sysc.

bootstrap.cfg also gives an indication whether we are running in a
chroot to avoid attempting to kexec/mount within a chroot.
2021-08-27 14:54:08 +10:00

46 lines
1.3 KiB
Bash
Executable file

# SPDX-FileCopyrightText: 2021 Andrius Štikonas <andrius@stikonas.eu>
#
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
default
# Regenerate bison files
# perly.c looks suspiciously like it is from bison, but is not; from the
# below script:
# Note that perly.c is *not* regenerated - this is now a static file which
# is not dependent on perly.y any more.
perl regen_perly.pl
# Regenerate other prebuilt header files
# Taken from headers of regen scripts
rm embed.h embedvar.h perlapi.c perlapi.h proto.h mg_names.inc mg_raw.h \
mg_vtable.h opcode.h opnames.h pp_proto.h \
lib/B/Op_private.pm overload.h overload.inc lib/overload/numbers.pm \
reentr.h reentr.c regnodes.h lib/warnings.pm \
warnings.h lib/feature.pm feature.h
perl regen.pl
# Regenerate configure + config_h.SH
rm Configure config_h.SH
ln -s ../perl-5f2dc80/regen-configure/.package .
ln -s ../perl-5f2dc80/regen-configure/U .
metaconfig -m
}
src_configure() {
./Configure -des \
-Dprefix="${PREFIX}" \
-Dcc=gcc \
-Dusedl=false \
-Ddate=':' \
-Dccflags="-U__DATE__ -U__TIME__" \
-Darchname="i386-linux"
}
src_install() {
# Remove old perl
rm -rf "${PREFIX}"/lib/perl5/
default
}