f59057de2a
Since Fedora 30, license files are missing from the ISO filesystem
of live or installer images (including official builds). The source
path to these files changed when they were moved into a subpackage
named fedora-release-common (or generic-release-common).
Also, copy the license files from the installroot, rather than the
existing root filesystem.
(cherry picked from commit 7df94aed4d
)
53 lines
1.7 KiB
Cheetah
53 lines
1.7 KiB
Cheetah
<%page args="kernels, runtime_img, runtime_base, basearch, outroot, arch"/>
|
|
<%
|
|
configdir="tmp/config_files/uboot"
|
|
PXEBOOTDIR="images/pxeboot"
|
|
BOOTDIR="boot"
|
|
KERNELDIR=PXEBOOTDIR
|
|
LIVEDIR="LiveOS"
|
|
LORAXDIR="usr/share/lorax/"
|
|
|
|
from os.path import basename
|
|
%>
|
|
|
|
mkdir ${LIVEDIR}
|
|
install ${runtime_img} ${LIVEDIR}/squashfs.img
|
|
treeinfo stage2 mainimage ${LIVEDIR}/squashfs.img
|
|
|
|
## install kernels
|
|
mkdir ${KERNELDIR}
|
|
%for kernel in kernels:
|
|
%if kernel.flavor:
|
|
installkernel images-${kernel.flavor}-${basearch} ${kernel.path} ${KERNELDIR}/vmlinuz-${kernel.flavor}
|
|
installinitrd images-${kernel.flavor}-${basearch} ${kernel.initrd.path} ${KERNELDIR}/initrd-${kernel.flavor}.img
|
|
|
|
treeinfo images-${kernel.flavor}-${basearch} uimage ${KERNELDIR}/uImage-${kernel.flavor}
|
|
treeinfo images-${kernel.flavor}-${basearch} uinitrd ${KERNELDIR}/uInitrd-${kernel.flavor}
|
|
|
|
%else:
|
|
installkernel images-${basearch} ${kernel.path} ${KERNELDIR}/vmlinuz
|
|
installinitrd images-${basearch} ${kernel.initrd.path} ${KERNELDIR}/initrd.img
|
|
|
|
treeinfo images-${basearch} uimage ${KERNELDIR}/uImage
|
|
treeinfo images-${basearch} uinitrd ${KERNELDIR}/uInitrd
|
|
|
|
%endif
|
|
%endfor
|
|
|
|
# Create optional product.img and updates.img
|
|
<% images=["product", "updates"] %>
|
|
%for img in images:
|
|
%if exists("%s/%s/" % (LORAXDIR, img)):
|
|
installimg --xz -9 --memlimit-compress=3700MiB ${LORAXDIR}/${img}/ images/${img}.img
|
|
treeinfo images-${basearch} ${img}.img images/${img}.img
|
|
%endif
|
|
%endfor
|
|
|
|
# Add the license files
|
|
%for f in glob("usr/share/licenses/*-release-common/*"):
|
|
install ${f} ${f|basename}
|
|
%endfor
|
|
|
|
## FIXME: ARM may need some extra boot config
|
|
|