mirror of
git://soft.sys114.com/odroid-stamper
synced 2025-12-19 00:08:43 +09:00
commnad: add new flag '--linuxfactory=<IP address>'
Signed-off-by: Dongjin Kim <tobetter@gmail.com> Change-Id: I5d84f0cde2123c25f3cbd30c6f500cabaaeac2a9
This commit is contained in:
@@ -5,3 +5,9 @@ mkdir -p $(dirname $(realpath -m /etc/resolv.conf))
|
|||||||
cat>/etc/resolv.conf<<__EOF
|
cat>/etc/resolv.conf<<__EOF
|
||||||
nameserver 127.0.0.53
|
nameserver 127.0.0.53
|
||||||
__EOF
|
__EOF
|
||||||
|
|
||||||
|
if [ ! "x@@DEFAULT_LINUXFACTORY@@" = "x" ]; then
|
||||||
|
echo "@@DEFAULT_LINUXFACTORY@@ ppa.linuxfactory.or.kr" >> /etc/hosts
|
||||||
|
fi
|
||||||
|
|
||||||
|
cat /etc/hosts
|
||||||
|
|||||||
@@ -439,6 +439,8 @@ do_preinstall() {
|
|||||||
DEFAULT_KERNEL_PACKAGE=$(get_kernel_package)
|
DEFAULT_KERNEL_PACKAGE=$(get_kernel_package)
|
||||||
[ ! "x${opt_kernel_package}" = "x" ] && DEFAULT_KERNEL_PACKAGE=${opt_kernel_package}
|
[ ! "x${opt_kernel_package}" = "x" ] && DEFAULT_KERNEL_PACKAGE=${opt_kernel_package}
|
||||||
|
|
||||||
|
[ ! "x${opt_linuxfactory}" = "x" ] && DEFAULT_LINUXFACTORY=${opt_linuxfactory}
|
||||||
|
|
||||||
FIXUPS=`ls -A1 ${rootfs_mnt}${fixups_dir}/*`
|
FIXUPS=`ls -A1 ${rootfs_mnt}${fixups_dir}/*`
|
||||||
for fixup in ${FIXUPS}; do
|
for fixup in ${FIXUPS}; do
|
||||||
sed -i \
|
sed -i \
|
||||||
@@ -451,6 +453,7 @@ do_preinstall() {
|
|||||||
-e "s,@@DEFAULT_KERNEL_PACKAGE@@,${DEFAULT_KERNEL_PACKAGE},g" \
|
-e "s,@@DEFAULT_KERNEL_PACKAGE@@,${DEFAULT_KERNEL_PACKAGE},g" \
|
||||||
-e "s,@@DEFAULT_BOOTSCRIPT_PACKAGE@@,$(get_bootscript_package),g" \
|
-e "s,@@DEFAULT_BOOTSCRIPT_PACKAGE@@,$(get_bootscript_package),g" \
|
||||||
-e "s,@@DEFAULT_MACHINE_NAME@@,$(get_machine_name),g" \
|
-e "s,@@DEFAULT_MACHINE_NAME@@,$(get_machine_name),g" \
|
||||||
|
-e "s,@@DEFAULT_LINUXFACTORY@@,${DEFAULT_LINUXFACTORY},g" \
|
||||||
-e "s,@@LINUX_KERNEL_CMDLINE@@,root=UUID=${UUID_ROOT} rootwait ro quiet,g" \
|
-e "s,@@LINUX_KERNEL_CMDLINE@@,root=UUID=${UUID_ROOT} rootwait ro quiet,g" \
|
||||||
-e "s,@@LINUX_KERNEL_CMDLINE_DEFAULTS@@,$(get_kernel_cmdline_defaults),g" \
|
-e "s,@@LINUX_KERNEL_CMDLINE_DEFAULTS@@,$(get_kernel_cmdline_defaults),g" \
|
||||||
-e "s,@@DEFAULT_DEV_BOOT@@,${UUID_BOOT},g" \
|
-e "s,@@DEFAULT_DEV_BOOT@@,${UUID_BOOT},g" \
|
||||||
|
|||||||
@@ -22,6 +22,7 @@ usage() {
|
|||||||
echo " --keep-builddir: prevent removing temporary directory"
|
echo " --keep-builddir: prevent removing temporary directory"
|
||||||
echo " after building an image."
|
echo " after building an image."
|
||||||
echo " --kernel: kernel package name to use"
|
echo " --kernel: kernel package name to use"
|
||||||
|
echo " --linuxfactory: alternative server IP address of 'ppa.linuxfactory.or.kr'"
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -47,6 +48,8 @@ for opt in "$@"; do
|
|||||||
--keep-builddir)
|
--keep-builddir)
|
||||||
opt_keep_builddir=true;;
|
opt_keep_builddir=true;;
|
||||||
--kernel=*) opt_kernel_package="${opt#*=}";;
|
--kernel=*) opt_kernel_package="${opt#*=}";;
|
||||||
|
--linuxfactory=*)
|
||||||
|
opt_linuxfactory="${opt#*=}";;
|
||||||
--custom=*)
|
--custom=*)
|
||||||
opt_custom="${opt#*=}";;
|
opt_custom="${opt#*=}";;
|
||||||
--addon-wifi) opt_wifi=true;;
|
--addon-wifi) opt_wifi=true;;
|
||||||
|
|||||||
Reference in New Issue
Block a user