Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mkimage-profiles
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ximper Linux
mkimage-profiles
Commits
e7d0f039
Commit
e7d0f039
authored
Nov 25, 2022
by
Anton Midyukov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Set variable BRANCH, if not defined or empty; show $BRANCH
So much clearer and easier. Thanks glebfm@ for the idea.
parent
41b06533
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
25 additions
and
21 deletions
+25
-21
Makefile
Makefile
+11
-0
mixin.mk
conf.d/mixin.mk
+1
-1
regular.mk
conf.d/regular.mk
+3
-3
branch.txt
doc/branch.txt
+2
-5
params.txt
doc/params.txt
+4
-2
profiles.mk.sample
doc/profiles.mk.sample
+0
-4
config.mk
features.in/stage2/config.mk
+1
-3
distro.mk
lib/distro.mk
+1
-1
profile.mk
lib/profile.mk
+1
-1
main.mk
main.mk
+1
-1
No files found.
Makefile
View file @
e7d0f039
...
...
@@ -2,6 +2,16 @@
# iterate over multiple goals/arches,
# collect proceedings
ifndef
BRANCH
BRANCH
:=
$(
shell
rpm
--eval
%_priority_distbranch
)
export
BRANCH
endif
ifeq
(,$(BRANCH))
override
BRANCH
=
sisyphus
MAKEOVERRIDES
+=
BRANCH
=
sisyphus
endif
# preferences
-include
$(HOME)/.mkimage/profiles.mk
...
...
@@ -51,6 +61,7 @@ SHELL = /bin/bash
else
\
say
"** goal:
$@
"
;
\
fi
;
\
say
"** BRANCH:
$(BRANCH)
"
;
\
for
ARCH
in
$(ARCHES)
;
do
\
if
[
-z
"
$(QUIET)
"
]
;
then
\
if
[
"
$$
ARCH"
!=
"
$
(firstword
$(ARCHES)
)"
]
;
then
\
...
...
conf.d/mixin.mk
View file @
e7d0f039
...
...
@@ -46,7 +46,7 @@ mixin/regular-x11: use/luks use/volumes/regular \
@$(call add,THE_PACKAGES,btrfs-progs)
@$(call add,THE_PACKAGES,gpm)
@$(call add,DEFAULT_SERVICES_DISABLE,gpm powertop)
ifneq (,$(BRANCH))
ifneq (
sisyphus
,$(BRANCH))
@$(call set,FX_FLAVOUR,-esr)
endif
...
...
conf.d/regular.mk
View file @
e7d0f039
...
...
@@ -8,7 +8,7 @@ distro/.regular-bare: distro/.base use/kernel/net use/docs/license \
use/stage2/rtc use/stage2/sbc use/stage2/scsi use/stage2/usb \
use/tty
@$(call try,SAVE_PROFILE,yes)
ifeq (,$(BRANCH))
ifeq (
sisyphus
,$(BRANCH))
ifeq (,$(filter-out i586 x86_64,$(ARCH)))
@$(call set,BOOTLOADER,grubpcboot)
endif
...
...
@@ -30,7 +30,7 @@ distro/.regular-x11: distro/.regular-base mixin/regular-x11 \
@$(call add,DEFAULT_SERVICES_DISABLE,gpm powertop)
# Network install
ifeq (,$(BRANCH))
ifeq (
sisyphus
,$(BRANCH))
ifeq (,$(filter-out i586 x86_64 aarch64,$(ARCH)))
distro/regular-net-install: distro/grub-net-install
@$(call set,BOOTCHAIN_OEM_SRV_NETINST,nightly.altlinux.org)
...
...
@@ -165,7 +165,7 @@ distro/regular-gnustep-systemd: distro/.regular-wm +systemd \
distro/regular-xfce: distro/.regular-gtk mixin/regular-xfce; @:
ifeq (,$(filter-out i586 x86_64 aarch64,$(ARCH)))
ifeq (,$(BRANCH))
ifeq (
sisyphus
,$(BRANCH))
@$(call set,KFLAVOURS,std-def un-def)
else
@$(call set,KFLAVOURS,un-def)
...
...
doc/branch.txt
View file @
e7d0f039
=== Переменная BRANCH ===
Переменная make, указывающая для какого бранча производится сборка.
Если не указана, сборка осуществляется для Сизифа.
Если не задана, определяется автоматически.
Если переменная имеет пустое значение, назначается sisyphus.
Для того, чтобы при указании этой переменной сборка осуществлялась для
целевого бранча, требуется:
* прописать в ~/.mkimage/profiles.mk:
--------------------------------------
ifneq (,$(BRANCH))
APTCONF = ~/apt/apt.conf.$(BRANCH).$(ARCH)
else
APTCONF = ~/apt/apt.conf.sisyphus.$(ARCH)
endif
--------------------------------------
* создать целевые конфиги apt по указанным выше путям.
...
...
doc/params.txt
View file @
e7d0f039
...
...
@@ -34,8 +34,10 @@ $HOME/.mkimage/profiles.mk.
* BRANCH
** указывает для какого бранча производится сборка
** собирает вместо регулярок стартеркиты
** значение: пусто (сборка для Сизифа) либо имя бранча
** задаёт переменную "STARTERKIT := mixin/starterkit"
** значение:
*** не определено - пытается определиться автоматически
*** пусто - присваивается значение sisyphus
*** имя бранча (sisyphus, p10, p9)
** см. doc/branch.txt main.mk, conf.d/mixin.mk
* BUILDDIR
...
...
doc/profiles.mk.sample
View file @
e7d0f039
...
...
@@ -2,11 +2,7 @@
# NB: REPORT doesn't work here, it's somewhat special
# where to look for apt.conf; system one used by default
ifneq (,$(BRANCH))
APTCONF = ~/apt/apt.conf.$(BRANCH).$(ARCH)
else
APTCONF = ~/apt/apt.conf.sisyphus.$(ARCH)
endif
# path to save out image
IMAGEDIR = ~/out/$(BRANCH)/$(shell date +%Y%m%d)
...
...
features.in/stage2/config.mk
View file @
e7d0f039
...
...
@@ -8,9 +8,7 @@ use/stage2:: sub/stage1
@$(call set,GLOBAL_HSH_PROC,1)
ifneq (,$(filter-out e2k%,$(ARCH)))
ifeq (,$(BRANCH))
use/stage2:: use/initrd-bootchain; @:
else ifneq (,$(filter-out p10 p9 p8 p7 p6 p5 с%,$(BRANCH)))
ifeq (sisyphus,$(BRANCH))
use/stage2:: use/initrd-bootchain; @:
else
use/stage2:: use/initrd-propagator; @:
...
...
lib/distro.mk
View file @
e7d0f039
...
...
@@ -13,7 +13,7 @@ distro/.init: profile/bare
@$(call try,META_PUBLISHER,ALT Linux Team)
distro/.boot: distro/.init boot/iso
ifeq (,$(BRANCH))
ifeq (
sisyphus
,$(BRANCH))
@$(call try,META_VOL_ID,ALT $(IMAGE_NAME)/$(ARCH))
else
@$(call try,IMAGE_FLAVOUR,$(subst alt-$(BRANCH)-,,$(IMAGE_NAME)))
...
...
lib/profile.mk
View file @
e7d0f039
...
...
@@ -100,7 +100,7 @@ profile/bare: profile/init use/pkgpriorities
@$(call try,GLOBAL_VERBOSE,)
@$(call try,IMAGEDIR,$(wildcard $(IMAGEDIR)))
@$(call try,LOGDIR,$(wildcard $(LOGDIR)))
ifeq (,$(BRANCH))
ifeq (
sisyphus
,$(BRANCH))
@$(call try,BRANDING,alt-sisyphus)
else
@$(call try,BRANDING,alt-starterkit)
...
...
main.mk
View file @
e7d0f039
...
...
@@ -17,7 +17,7 @@ endif
IMAGE_CONF := $(firstword $(subst ., ,$(IMAGE_TARGET)))# ve/generic
IMAGE_CLASS := $(firstword $(subst /, ,$(IMAGE_TARGET)))# ve
IMAGE_FILE := $(lastword $(subst /, ,$(IMAGE_TARGET)))# generic.tar.gz
ifneq (,$(BRANCH))
ifneq (
sisyphus
,$(BRANCH))
IMAGE_FILE := $(subst regular,alt-$(BRANCH),$(IMAGE_FILE))
endif
IMAGE_NAME := $(firstword $(subst ., ,$(IMAGE_FILE)))# generic
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment