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
0
Merge Requests
0
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
Anton Palgunov
mkimage-profiles
Commits
1f4db6c7
Commit
1f4db6c7
authored
Feb 09, 2021
by
Anton Midyukov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
stage1: build propagator and copy kernel in mkimage-profiles
parent
2c53e5ef
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
72 additions
and
6 deletions
+72
-6
90-build-propagator
features.in/stage2/stage1/scripts.d/90-build-propagator
+33
-0
95-copy-kernel
features.in/stage2/stage1/scripts.d/95-copy-kernel
+35
-0
Makefile
sub.in/stage1/Makefile
+4
-6
No files found.
features.in/stage2/stage1/scripts.d/90-build-propagator
0 → 100755
View file @
1f4db6c7
#!/bin/sh -efu
libdir
=
"
$(
getconf LIBDIR
)
"
case
"
`
arch
`
"
in
e2k
)
kname
=
image
;;
*
)
kname
=
vmlinuz
;;
esac
if
[
-L
/boot/
$kname
]
;
then
kimage
=
"
$(
readlink
-mv
/boot/
$kname
)
"
else
kimage
=
"
$(
find /boot
-type
f
-name
"
$kname
-*"
-print
-quit
)
"
fi
kver
=
"
${
kimage
#/boot/
$kname
-
}
"
mkmodpack
-p
/.in/modules
-o
/tmp/modules
-k
"
$kver
"
rm
-f
/boot/full.cz
[
!
-f
/tmp/modules
]
||
cat
"
$libdir
/propagator/initfs"
/tmp/modules
>
/boot/full.cz
sed
\
-e
"s,@LIBDIR@,
$libdir
,"
\
-e
"s,@TMPDIR@,/tmp,g"
\
<
"
$WORKDIR
/initfs"
|
gencpio - |
gzip
-c
>>
/boot/full.cz
features.in/stage2/stage1/scripts.d/95-copy-kernel
0 → 100755
View file @
1f4db6c7
#!/bin/sh -ef
cd
/.image
mkdir
-p
boot
case
"
`
arch
`
"
in
e2k
)
kname
=
image
;;
*
)
kname
=
vmlinuz
;;
esac
if
[
-L
"/boot/
$kname
"
]
;
then
kimage
=
"
$(
readlink
-ev
/boot/
$kname
)
"
else
kimage
=
"
$(
find /boot
-type
f
-name
"
$kname
-*"
-print
-quit
)
"
fi
if
[
-n
"
$kimage
"
]
;
then
cp
-af
"
$kimage
"
boot/
$kname
[
!
-f
/boot/full.cz
]
||
cp
-af
/boot/full.cz boot/full.cz
fi
# config is generated in mkimage
case
"
$GLOBAL_EFI_BOOTLOADER
"
in
refind|elilo
)
mkdir
-p
EFI/BOOT
cp
-lpLft
EFI/BOOT
--
boot/vmlinuz
[
!
-f
boot/full.cz
]
||
cp
-lpLft
EFI/BOOT
--
boot/full.cz
;;
esac
sub.in/stage1/Makefile
View file @
1f4db6c7
...
...
@@ -30,10 +30,8 @@ GLOBAL_STAGE1_KFLAVOUR := $(STAGE1_KFLAVOUR)
CHROOT_PACKAGES_REGEXP
:=
$
(
call kpackages,
\
$(STAGE1_KFLAVOUR)
,
$(STAGE1_KMODULES)
,
$(STAGE1_KMODULES_REGEXP)
)
ifneq
"$(findstring stage2,$(SUBPROFILES))"
""
### assumes stage2 ~ propagator
PROPAGATOR_VERSION
=
ALT
PROPAGATOR_MAR_MODULES
=
./modules
PROPAGATOR_INITFS
=
./initfs
BUILD_PROPAGATOR
=
prepare-modules build-propagator
LIST_MODULES
=
.work/chroot/.in/modules
PREPARE_MODULES
=
prepare-modules
endif
endif
...
...
@@ -51,8 +49,8 @@ prepare-modules:
# scripts prepare bootloader configuration, too
# NB: we pass tested squashfs options for sub.in/stage2/Makefile to include
all
:
| debug prepare-workdir copy-tree
run-scripts $(BUILD_PROPAGATOR)
\
copy-$(BOOTLOADER)
$(COPY_SQUASHCFG) pack-image $(GLOBAL_CLEAN_WORKDIR)
all
:
| debug prepare-workdir copy-tree
$(PREPARE_MODULES) run-scripts
\
$(COPY_SQUASHCFG) pack-image $(GLOBAL_CLEAN_WORKDIR)
@
if
[
-s
$(OUTDIR)
/squashcfg.mk
]
;
then
\
cp
$(OUTDIR)
/squashcfg.mk
$(GLOBAL_BUILDDIR)
/
;
\
fi
...
...
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