Commit Graph

147 Commits

Author SHA1 Message Date
Anton Midyukov
41b065336f check conditions of make for equality of variables with an empty value
check conditions of  make  for equality of variables with an empty value
instead of check definition.
A defined but empty variable under all these conditions results errors.
2022-12-30 19:39:43 +07:00
Anton Midyukov
ee1113419d Replace 'egrep' to 'grep -E'
Fix 'warning: egrep is obsolescent; using grep -E'
2022-05-12 15:10:30 +07:00
Anton Midyukov
9fc8689db8 log.mk, profile.mk: Output errors Step 3 to BUILDLOG and on screen 2022-04-11 23:13:22 +07:00
Anton Midyukov
f77d9b6024 lib/profile.mk: install branding-$$(BRANDING)-release always after basesystem
This package must always be installed in chroot in one transaction with
basesystem so that the correct package is installed.
2022-03-05 17:10:37 +07:00
Anton Midyukov
05c3dafcf7 lib/profile.mk, build-distro: save current commit, when generating a profile
Images building from the generated profile will have mkimage-profiles
commit information.
2022-03-02 11:03:45 +07:00
Anton Midyukov
bf3163e37a build.mk, profile.mk: execute target make-aptbox from profile-populate
make-aptbox is needed to check package lists only.
2022-01-20 09:31:03 +07:00
Anton Midyukov
be46eb8b13 lib/distro.mk: Replace 'set' to 'try'
All variables can be overridden.
2021-12-22 03:03:00 +07:00
Anton Midyukov
36c7fa3882 lib/distro.mk: fix META_VOL_ID for Starterkits
It was broken сommit 676aac358c
2021-12-22 03:00:51 +07:00
Anton Midyukov
8551e71028 lib/profile.mk: add branding-<BRANDING>-release to PACKAGES_REQUIRES_INITROOT
It was a mistake to add branding package to the initialized chroot. There
were no problems until the package had dependencies. Now, when most branding
has a dependence on alt-os-release, chroot initialization broke.
See also ALT bug 41570.
Branding needed to be added to PACKAGES_REQUIRED_INITROOT so that it is
installed with basesystem.
2021-12-19 16:18:02 +07:00
Michael Shigorin
a028ee7734 profile.mk: quote variables properly
...otherwise:

$ make QUIET=1 REPORT=1 THE_APT_CONF=branch BRANDING=alt-starterkit ...
/bin/sh: line 5: [: too many arguments
/bin/sh: line 28: [: too many arguments
2021-12-13 17:29:27 +07:00
Anton Midyukov
f783d28dd9 Revert "Do not rsync .gitignore to build directories"
This reverts commit 366cb49dbe.
.gitignore is needed for packaging empty catalogs to the profile archive.
2021-12-10 20:50:33 +07:00
Anton Midyukov
1c50ff1ffa build.mk, params.txt: add parameter USE_QEMU
The parameter determines use of QEMU or not, if the target architecture
does not correspond to the host architecture.
By default, the parameter is on (Value 1).
For architectures that do not support QEMU (e2k), the option is turned off.
2021-11-22 22:30:57 +07:00
Anton Midyukov
7b4f9e4dbe build.mk: Do nothing with IMAGEDIR if $(DIRECT_TARGETS) is running 2021-10-14 13:59:37 +07:00
Anton Midyukov
b4e8bb406b profile.mk: fix typo 2021-09-19 20:35:02 +07:00
Anton Midyukov
008106f835 lib/profile.mk: with BRANCH variable set try fallback BRANDING alt-starterkit 2021-08-31 10:11:51 +07:00
Anton Midyukov
09b5739a4a lib/profile.mk: do not abort build with CHECK=0, if unavailable ARCH 2021-08-31 00:45:31 +07:00
Anton Midyukov
ec1b562453 lib/report.mk: do not enable tracing with REPORT='' 2021-08-23 21:52:13 +07:00
Anton Midyukov
d8e39efc12 lib/build.mk: do not check package lists when CHECK=0
Aptbox is not initialized, so build time is reduced.
2021-08-23 21:09:07 +07:00
Anton Midyukov
6a85e7213f build.mk: fix build without APTCONF parameter 2021-08-13 23:16:40 +07:00
Anton Midyukov
137428c5e0 build.mk: fix make distclean for aborted build
mkimage to run сlean/distclean successfully requires .work/.cache
and .work/.out directories.
2021-08-09 21:46:41 +07:00
Anton Midyukov
21dc644baf Revert "clean.mk: do not run twice make clean (distclean)"
This reverts commit 83e0b91309.
However, it is not make clean is executed, but the make distclean.
2021-07-23 16:06:57 +07:00
Anton Midyukov
0f68446da7 build.mk: initial .work/aptbox immediately after configuring the profile
This will allow apt to be request before/without the hasher is created.
2021-07-20 22:38:52 +07:00
Anton Midyukov
b8aaede559 profile.mk: Set WORK_INIT_LIST to branding-$$(BRANDING)-release
Requires support at mkimage.
2021-07-13 17:16:57 +07:00
Anton Midyukov
366cb49dbe Do not rsync .gitignore to build directories 2021-06-24 21:48:53 +07:00
Anton Midyukov
58f650503f log.mk: Don't write anything to build.log when DIRECT_TARGETS
build.log does not exist when they run, because the build directory
is no longer created to run them.
2021-06-23 14:46:02 +07:00
Anton Midyukov
83e0b91309 clean.mk: do not run twice make clean (distclean)
The build directory is normally removed after make clean.
2021-06-23 14:43:25 +07:00
Anton Midyukov
86f75210e0 Makefile, profile.mk: not create temp directories with DIRECT_TARGETS
See-also: https://bugzilla.altlinux.org/show_bug.cgi?id=40148
2021-06-18 18:06:29 +07:00
Anton Midyukov
8dbd0a0fee Makefile, lib/build.mk: fix usage AUTOCLEAN with DEBUG
make distclean should be launched after copying the log when
debugging is enabled.
2021-06-06 19:55:23 +07:00
Anton Midyukov
b2570d8246 lib/profile.mk, doc/params.txt: add parameter MKIMAGE_PREFIX
Previously, you had to specify two parameters MKIMAGE_PREFIX and
GLOBAL_PREFIX with the same value - the path to mkimage. And this
behavior has not been documented. The GLOBAL_PREFIX variable is
defined in mkimage in config.mk and rules.mk.
2021-05-17 18:14:29 +07:00
Anton Midyukov
b44968fc8d lib/clean.mk: fix typo in distclean
Because of this, distclean did not work. Only the symlink was
removed.
2021-04-16 17:50:22 +07:00
Anton Midyukov
e8fcdaf8e3 lib/boot.mk: Set IMAGE_PACKTYPE to isodata for e2k 2021-04-16 01:31:33 +07:00
Anton Midyukov
93e7d43f47 lib/boot.mk: Fix BOOTLOADER for e2k 2021-04-13 02:00:46 +07:00
Anton Midyukov
7c17cc5582 lib/vm.mk: .base-grub-efi available for riscv64 2021-04-04 23:16:27 +07:00
Anton Midyukov
58eea1911b boot.mk, efi, grub: Add support riscv64
For riscv64 available grub-efi.
Needed added support for mkimage (mki-copy-efiboot-chrooted).
2021-03-16 21:15:49 +07:00
Anton Midyukov
f40fe0ebc5 boot.mk, grub, syslinux: Add the ability to override BOOTLOADER
More than one BOOTLOADER may be available for the same architecture.
Set IMAGE_PACKTYPE in boot/iso, there is no point in duplicating
in different features.
Closes ALT bug 39786.
2021-03-16 18:12:48 +07:00
Anton Midyukov
de9adb0594 build-distro, boot.mk: Set BOOT_TYPE, BOOTLOADER to efiboot for aarch64
mki-copy-grubaa64boot more not needed. In addition, it did not
support the config in boot/grub instead of EFI/BOOT.
Needed mkimage >= 0.2.38-alt1
2021-02-17 13:47:39 +07:00
Anton Midyukov
30af48c871 vm.mk: Simplified conditions for choosing a bootloader depending on arch 2020-09-18 12:45:09 +07:00
Anton Midyukov
6338944604 profile.mk: pinned package branding-$$(BRANDING)-release
This is necessary to prevent accidental hit of another branding.
Usually the problem is solved by setting up pkgpriorities  in apt settings.
But this is inconvenient when you need to make building often with others
branding.
2020-05-01 23:49:56 +07:00
Anton Midyukov
a02c328447 lib/vm.mk: vm/.base-grub allowed on ppc64le 2020-04-07 22:35:52 +07:00
Anton Midyukov
e42bcdcb30 90-build-distro.mk, boot.mk, syslinux: add ARM64 EFI support for distro targets 2019-08-30 19:23:28 +03:00
Gleb Fotengauer-Malinovskiy
f47d1c09ba Use ieee1275boot as bootloader on ppc64le
ieee1275boot bootloader support was added in mkimage 0.2.27.
2019-08-19 23:31:01 +03:00
Anton Midyukov
813274a0cf lib/vm.mk: use/bootloader/* 2019-08-19 23:27:06 +03:00
Mikhail Gordeev
e1cc0863de lib/ve.mk: split package management and networking
Some images (i.e. docker and systemd-bare) require apt
but do not require etcnet.
2019-04-02 17:43:34 +03:00
Michael Shigorin
801455fece build.mk: added Conflicts: to error filter
Just stumbled into that and (falsely) blamed vseleznv@! :(
2019-03-08 17:27:24 +03:00
Ivan A. Melnikov
45b38f389d build.mk: Run mips{,64}el builds natively on mips* machines 2018-12-25 15:43:08 +03:00
cf420b2174 vm.mk: add vm/.bare-grub{,-efi}
Some images will now be better off with GRUB;
rework ve/.bare while at that (splitting the
image targets appropriately).
2018-12-24 19:36:31 +03:00
Michael Shigorin
3c2ef1c035 rework isoboot support beyond x86
Every .iso was assumed to be bootable since the very beginning[*],
and isoboot images were deemed to be x86 isolinux ones; this didn't
change with basic ppc/armh support as I never ran into hardware
that would _boot_ those ISOs, not only run the code, and it was
only e2k isodata project that finally forced this refactoring.

It's still not perfect: pack and syslinux features still end up
somewhat interwoven, and too much places care for architecture
the image is being built for (instead of archdep features tossing
their appropriate bits and pieces in).

Should help:
- any-arch regarding isodata images;
- {x86,aarch64}/efi by decoupling isoboot and isolinux;
- ppc{,64} as introducing yaboot support will be easier now;
- mipsel{,64} too, hopefully.

* I knew of school addon images baked with mkimage-profiles-desktop
  but postponed and then neglected the whole problem for years...
2018-07-25 16:49:01 +03:00
Ivan Zakharyaschev
8e94854858 profile.mk: fix thinko
find's argument order is a bit different indeed.
2018-06-05 18:22:01 +03:00
Ivan Zakharyaschev
0ecfb35700 profile.mk: safer find/grep
Don't go crazy if Dir::Etc::sourceparts/d
gives something strange (e.g., /).
2018-05-23 11:30:15 +03:00
Michael Shigorin
d010cef393 build.mk: just go on for e2k*
There's no qemu there so far, and there's no need
to fiddle with setarch either.

NB: part of this commit erroneously went into
    1c777c8ad4
    quite some time ago, sorry about the mess.
2018-05-21 22:51:07 +03:00