Skip to content

Commit 48ff3a0

Browse files
committed
Merge branch 'alteriso-3-mainline' into alteriso-3-stable
2 parents 88d613b + 2c0c166 commit 48ff3a0

37 files changed

Lines changed: 422 additions & 261 deletions

File tree

allarch.sh

Lines changed: 66 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,7 @@ _usage () {
202202
echo " General options:"
203203
echo " -b | --boot-splash Enable boot splash"
204204
echo " -e | --cleanup | --cleaning Enable post-build cleaning"
205+
echo " --tarball Build rootfs in tar.xz format"
205206
echo " -h | --help This help message and exit"
206207
echo
207208
echo " -c | --comp-type <comp_type> Set SquashFS compression type (gzip, lzma, lzo, xz, zstd)"
@@ -283,6 +284,7 @@ _usage () {
283284
echo " --nochkver NO check the version of the channel"
284285
echo " --noloopmod No check and load kernel module automatically"
285286
echo " --nodepend No check package dependencies before building"
287+
echo " --noiso No build iso image (Use with --tarball)"
286288
echo " --shmkalteriso Use the shell script version of mkalteriso"
287289
if [[ -n "${1:-}" ]]; then exit "${1}"; fi
288290
}
@@ -368,9 +370,9 @@ remove_work() {
368370
# Display channel list
369371
show_channel_list() {
370372
if [[ "${nochkver}" = true ]]; then
371-
bash "${script_path}/tools/channel.sh" -v "${alteriso_version}" -n show
373+
bash "${script_path}/tools/channel.sh" -m -v "${alteriso_version}" -n show
372374
else
373-
bash "${script_path}/tools/channel.sh" -v "${alteriso_version}" show
375+
bash "${script_path}/tools/channel.sh" -m -v "${alteriso_version}" show
374376
fi
375377
}
376378

@@ -399,6 +401,9 @@ check_env() {
399401
msg_error "This kernel is currently not supported on this channel." "1"
400402
fi
401403

404+
# Show warning about allarch.sh
405+
msg_info "Some features of build.sh are not available."
406+
402407
# Check packages
403408
if [[ "${nodepend}" = false ]] && [[ "${arch}" = $(uname -m) ]] ; then
404409
local _installed_pkg=($(pacman -Q | awk '{print $1}')) _installed_ver=($(pacman -Q | awk '{print $2}')) _check_pkg _check_failed=false _pkg
@@ -426,7 +431,7 @@ check_env() {
426431
# リモートとローカルのバージョンが一致しない場合
427432
[[ "${debug}" = true ]] && echo -ne " $(pacman -Q ${1} | awk '{print $2}')\n"
428433
msg_warn "${1} is not the latest package."
429-
msg_warn "Local: $(pacman -Q ${1} 2> /dev/null | awk '{print $2}') Latest: $(pacman -Sp --print-format '%v' --config ${build_pacman_conf} ${1} 2> /dev/null)"
434+
msg_warn "Local: $(pacman -Q ${1} 2> /dev/null | awk '{print $2}') Latest: ${__ver}"
430435
return 0
431436
fi
432437
fi
@@ -587,6 +592,8 @@ prepare_build() {
587592
check_bool customized_username
588593
check_bool noloopmod
589594
check_bool nochname
595+
check_bool tarball
596+
check_bool noiso
590597
check_bool noaur
591598
check_bool customized_syslinux
592599

@@ -1008,8 +1015,8 @@ make_syslinux() {
10081015
# 一時ディレクトリに設定ファイルをコピー
10091016
mkdir -p "${work_dir}/${arch}/syslinux/"
10101017
cp -a "${script_path}/syslinux/"* "$work_dir/${arch}/syslinux/"
1011-
if [[ -d "${script_path}/channels/${channel_name}/syslinux.${arch}" ]] && [[ "${customized_syslinux}" = true ]]; then
1012-
cp -af "${script_path}/channels/${channel_name}/syslinux.${arch}/"* "$work_dir/${arch}/syslinux/"
1018+
if [[ -d "${script_path}/channels/${channel_name}/syslinux" ]] && [[ "${customized_syslinux}" = true ]]; then
1019+
cp -af "${script_path}/channels/${channel_name}/syslinux/"* "$work_dir/${arch}/syslinux/"
10131020
fi
10141021

10151022
# copy all syslinux config to work dir
@@ -1105,20 +1112,20 @@ make_efi() {
11051112

11061113
# Prepare efiboot.img::/EFI for "El Torito" EFI boot mode
11071114
make_efiboot() {
1108-
mkdir -p "${work_dir}/iso/EFI/archiso"
1109-
truncate -s 64M "${work_dir}/iso/EFI/archiso/efiboot.img"
1110-
mkfs.fat -n ARCHISO_EFI "${work_dir}/iso/EFI/archiso/efiboot.img"
1115+
mkdir -p "${work_dir}/iso/EFI/alteriso"
1116+
truncate -s 64M "${work_dir}/iso/EFI/alteriso/efiboot.img"
1117+
mkfs.fat -n ARCHISO_EFI "${work_dir}/iso/EFI/alteriso/efiboot.img"
11111118

11121119
mkdir -p "${work_dir}/efiboot"
1113-
mount "${work_dir}/iso/EFI/archiso/efiboot.img" "${work_dir}/efiboot"
1120+
mount "${work_dir}/iso/EFI/alteriso/efiboot.img" "${work_dir}/efiboot"
11141121

1115-
mkdir -p "${work_dir}/efiboot/EFI/archiso"
1122+
mkdir -p "${work_dir}/efiboot/EFI/alteriso"
11161123

1117-
cp "${work_dir}/iso/${install_dir}/boot/x86_64/${kernel_filename}" "${work_dir}/efiboot/EFI/archiso/${kernel_filename}.efi"
1118-
cp "${work_dir}/iso/${install_dir}/boot/x86_64/archiso.img" "${work_dir}/efiboot/EFI/archiso/archiso.img"
1124+
cp "${work_dir}/iso/${install_dir}/boot/x86_64/${kernel_filename}" "${work_dir}/efiboot/EFI/alteriso/${kernel_filename}.efi"
1125+
cp "${work_dir}/iso/${install_dir}/boot/x86_64/archiso.img" "${work_dir}/efiboot/EFI/alteriso/archiso.img"
11191126

1120-
cp "${work_dir}/iso/${install_dir}/boot/intel_ucode.img" "${work_dir}/efiboot/EFI/archiso/intel_ucode.img"
1121-
cp "${work_dir}/iso/${install_dir}/boot/amd_ucode.img" "${work_dir}/efiboot/EFI/archiso/amd_ucode.img"
1127+
cp "${work_dir}/iso/${install_dir}/boot/intel_ucode.img" "${work_dir}/efiboot/EFI/alteriso/intel_ucode.img"
1128+
cp "${work_dir}/iso/${install_dir}/boot/amd_ucode.img" "${work_dir}/efiboot/EFI/alteriso/amd_ucode.img"
11221129

11231130
mkdir -p "${work_dir}/efiboot/EFI/boot"
11241131

@@ -1149,6 +1156,33 @@ make_efiboot() {
11491156
umount -d "${work_dir}/efiboot"
11501157
}
11511158

1159+
# Compress tarball
1160+
make_tarball() {
1161+
cp -a -l -f "${work_dir}/${arch}/airootfs" "${work_dir}"
1162+
1163+
if [[ -f "${work_dir}/${arch}/airootfs/root/optimize_for_tarball.sh" ]]; then
1164+
chmod 755 "${work_dir}/${arch}/airootfs/root/optimize_for_tarball.sh"
1165+
# Execute optimize_for_tarball.sh.
1166+
${mkalteriso} ${mkalteriso_option} \
1167+
-w "${work_dir}/${arch}" \
1168+
-C "${work_dir}/pacman-${arch}.conf" \
1169+
-D "${install_dir}" \
1170+
-r "/root/optimize_for_tarball.sh" \
1171+
run
1172+
fi
1173+
1174+
ARCHISO_GNUPG_FD=${gpg_key:+17} ${mkalteriso} ${mkalteriso_option} -w "${work_dir}/${arch}" -C "${work_dir}/pacman-${arch}.conf" -D "${install_dir}" -r "mkinitcpio -p ${kernel_mkinitcpio_profile}" run
1175+
1176+
remove "${work_dir}/${arch}/airootfs/root/optimize_for_tarball.sh"
1177+
1178+
${mkalteriso} ${mkalteriso_option} -w "${work_dir}" -D "${install_dir}" -L "${iso_label}" -P "${iso_publisher}" -A "${iso_application}" -o "${out_dir}" tarball "$(echo ${iso_filename} | sed 's/\.[^\.]*$//' | sed "s/dual/${arch}/g").tar.xz"
1179+
1180+
remove "${work_dir}/airootfs"
1181+
if [[ "${noiso}" = true ]]; then
1182+
msg_info "The password for the live user and root is ${password}."
1183+
fi
1184+
}
1185+
11521186

11531187
# Build airootfs filesystem image
11541188
make_prepare() {
@@ -1256,7 +1290,7 @@ parse_files() {
12561290
# Parse options
12571291
ARGUMENT="${@}"
12581292
_opt_short="bc:deg:hjk:l:o:p:rt:u:w:x"
1259-
_opt_long="boot-splash,comp-type:,debug,cleaning,cleanup,gpgkey:,help,lang:,japanese,kernel:,out:,password:,comp-opts:,user:,work:,bash-debug,nocolor,noconfirm,nodepend,gitversion,shmkalteriso,msgdebug,noloopmod,noaur,nochkver,channellist,config:"
1293+
_opt_long="boot-splash,comp-type:,debug,cleaning,cleanup,gpgkey:,help,lang:,japanese,kernel:,out:,password:,comp-opts:,user:,work:,bash-debug,nocolor,noconfirm,nodepend,gitversion,shmkalteriso,msgdebug,noloopmod,tarball,noiso,noaur,nochkver,channellist,config:"
12601294
OPT=$(getopt -o ${_opt_short} -l ${_opt_long} -- ${DEFAULT_ARGUMENT} ${ARGUMENT})
12611295
[[ ${?} != 0 ]] && exit 1
12621296

@@ -1293,7 +1327,7 @@ while :; do
12931327
exit 0
12941328
;;
12951329
-j | --japanese)
1296-
msg_error "This option is obsolete in AlterISO 3. To use Japanese, use \"-g ja\"." "1"
1330+
msg_error "This option is obsolete in AlterISO 3. To use Japanese, use \"-l ja\"." "1"
12971331
;;
12981332
-k | --kernel)
12991333
kernel="${2}"
@@ -1311,6 +1345,10 @@ while :; do
13111345
password="${2}"
13121346
shift 2
13131347
;;
1348+
-r | --tarball)
1349+
tarball=true
1350+
shift 1
1351+
;;
13141352
-t | --comp-opts)
13151353
sfs_comp_opt="${2}"
13161354
shift 2
@@ -1361,6 +1399,10 @@ while :; do
13611399
noloopmod=true
13621400
shift 1
13631401
;;
1402+
--noiso)
1403+
noiso=true
1404+
shift 1
1405+
;;
13641406
--noaur)
13651407
noaur=true
13661408
shift 1
@@ -1408,7 +1450,7 @@ set +eu
14081450
[[ -n "${1}" ]] && channel_name="${1}"
14091451

14101452
# Check for a valid channel name
1411-
[[ "$(bash "${script_path}/tools/channel.sh" check "${channel_name}")" = false ]] && msg_error "Invalid channel ${channel_name}" "1"
1453+
[[ "$(bash "${script_path}/tools/channel.sh" -m check "${channel_name}")" = false ]] && msg_error "Invalid channel ${channel_name}" "1"
14121454

14131455
# Set for special channels
14141456
if [[ -d "${script_path}/channels/${channel_name}.add" ]]; then
@@ -1452,14 +1494,19 @@ for arch in ${all_arch[@]}; do
14521494
run_arch make_setup_mkinitcpio
14531495
run_arch make_syslinux
14541496
run_arch make_boot
1455-
run_arch make_prepare
1497+
[[ "${noiso}" = false ]] && run_arch make_prepare
14561498
done
14571499
run_once make_boot_extra
14581500
run_once make_syslinux_loadfiles
14591501
run_once make_isolinux
14601502
run_once make_efi
14611503
run_once make_efiboot
1462-
run_once make_iso
1504+
if [[ "${tarball}" = true ]]; then
1505+
for arch in ${all_arch[@]}; do
1506+
run_arch make_tarball
1507+
done
1508+
fi
1509+
[[ "${noiso}" = false ]] && run_once make_iso
14631510
[[ "${cleaning}" = true ]] && remove_work
14641511

14651512
exit 0

build.sh

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -601,7 +601,7 @@ prepare_build() {
601601
# リモートとローカルのバージョンが一致しない場合
602602
[[ "${debug}" = true ]] && echo -ne " $(pacman -Q ${1} | awk '{print $2}')\n"
603603
msg_warn "${1} is not the latest package."
604-
msg_warn "Local: $(pacman -Q ${1} 2> /dev/null | awk '{print $2}') Latest: $(pacman -Sp --print-format '%v' --config ${build_pacman_conf} ${1} 2> /dev/null)"
604+
msg_warn "Local: $(pacman -Q ${1} 2> /dev/null | awk '{print $2}') Latest: ${__ver}"
605605
return 0
606606
fi
607607
fi
@@ -1073,8 +1073,8 @@ make_syslinux() {
10731073
# 一時ディレクトリに設定ファイルをコピー
10741074
mkdir -p "${work_dir}/${arch}/syslinux/"
10751075
cp -a "${script_path}/syslinux/"* "${work_dir}/${arch}/syslinux/"
1076-
if [[ -d "${script_path}/channels/${channel_name}/syslinux.${arch}" ]] && [[ "${customized_syslinux}" = true ]]; then
1077-
cp -af "${script_path}/channels/${channel_name}/syslinux.${arch}/"* "${work_dir}/${arch}/syslinux/"
1076+
if [[ -d "${script_path}/channels/${channel_name}/syslinux" ]] && [[ "${customized_syslinux}" = true ]]; then
1077+
cp -af "${script_path}/channels/${channel_name}/syslinux"* "${work_dir}/${arch}/syslinux/"
10781078
fi
10791079

10801080
# copy all syslinux config to work dir
@@ -1157,20 +1157,20 @@ make_efi() {
11571157

11581158
# Prepare efiboot.img::/EFI for "El Torito" EFI boot mode
11591159
make_efiboot() {
1160-
mkdir -p "${work_dir}/iso/EFI/archiso"
1161-
truncate -s 64M "${work_dir}/iso/EFI/archiso/efiboot.img"
1162-
mkfs.fat -n ARCHISO_EFI "${work_dir}/iso/EFI/archiso/efiboot.img"
1160+
mkdir -p "${work_dir}/iso/EFI/alteriso"
1161+
truncate -s 64M "${work_dir}/iso/EFI/alteriso/efiboot.img"
1162+
mkfs.fat -n ARCHISO_EFI "${work_dir}/iso/EFI/alteriso/efiboot.img"
11631163

11641164
mkdir -p "${work_dir}/efiboot"
1165-
mount "${work_dir}/iso/EFI/archiso/efiboot.img" "${work_dir}/efiboot"
1165+
mount "${work_dir}/iso/EFI/alteriso/efiboot.img" "${work_dir}/efiboot"
11661166

1167-
mkdir -p "${work_dir}/efiboot/EFI/archiso"
1167+
mkdir -p "${work_dir}/efiboot/EFI/alteriso"
11681168

1169-
cp "${work_dir}/iso/${install_dir}/boot/${arch}/${kernel_filename}" "${work_dir}/efiboot/EFI/archiso/${kernel_filename}.efi"
1170-
cp "${work_dir}/iso/${install_dir}/boot/${arch}/archiso.img" "${work_dir}/efiboot/EFI/archiso/archiso.img"
1169+
cp "${work_dir}/iso/${install_dir}/boot/${arch}/${kernel_filename}" "${work_dir}/efiboot/EFI/alteriso/${kernel_filename}.efi"
1170+
cp "${work_dir}/iso/${install_dir}/boot/${arch}/archiso.img" "${work_dir}/efiboot/EFI/alteriso/archiso.img"
11711171

1172-
cp "${work_dir}/iso/${install_dir}/boot/intel_ucode.img" "${work_dir}/efiboot/EFI/archiso/intel_ucode.img"
1173-
cp "${work_dir}/iso/${install_dir}/boot/amd_ucode.img" "${work_dir}/efiboot/EFI/archiso/amd_ucode.img"
1172+
cp "${work_dir}/iso/${install_dir}/boot/intel_ucode.img" "${work_dir}/efiboot/EFI/alteriso/intel_ucode.img"
1173+
cp "${work_dir}/iso/${install_dir}/boot/amd_ucode.img" "${work_dir}/efiboot/EFI/alteriso/amd_ucode.img"
11741174

11751175
mkdir -p "${work_dir}/efiboot/EFI/boot"
11761176
#cp "${work_dir}/${arch}/airootfs/usr/lib/systemd/boot/efi/systemd-bootx64.efi" "${work_dir}/efiboot/EFI/boot/bootx64.efi"
@@ -1372,7 +1372,7 @@ while :; do
13721372
exit 0
13731373
;;
13741374
-j | --japanese)
1375-
msg_error "This option is obsolete in AlterISO 3. To use Japanese, use \"-g ja\"." "1"
1375+
msg_error "This option is obsolete in AlterISO 3. To use Japanese, use \"-l ja\"." "1"
13761376
;;
13771377
-k | --kernel)
13781378
kernel="${2}"
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
# ---------------------------------------------
2+
# Alter Linux i3wm edition
3+
# dunst config file
4+
#
5+
# Watasuke
6+
# Twitter: @Watasuke102
7+
# Email : Watasuke102@gmail.com
8+
#
9+
# (c) 2020 Fascode Network.
10+
# ---------------------------------------------
11+
12+
[global]
13+
monitor = 0
14+
follow = mouse
15+
sort = yes
16+
indicate_hidden = yes
17+
word_wrap = yes # multi line
18+
19+
# don't show URL and action
20+
show_indicators = no
21+
22+
# format
23+
markup = full
24+
format = "<b>%a - %s</b>\n%b\n%p"
25+
26+
# icon
27+
icon_path = /usr/share/icons/Inverse-blue-dark/16/devices;/usr/share/icons/Inverse-blue-dark/16/status;/usr/share/icons/Inverse-blue-dark/32/status
28+
icon_position = left
29+
max_icon_size = 64
30+
31+
# appearance
32+
padding = 10
33+
horizontal_padding = 15
34+
separator_height = 5
35+
transparency = 10
36+
geometry = "350x20-30+40"
37+
font = Noto Sans 9
38+
39+
[urgency_low]
40+
background = "#292929"
41+
foreground = "#ffffff"
42+
timeout = 10
43+
44+
[urgency_normal]
45+
background = "#292929"
46+
foreground = "#ffffff"
47+
timeout = 10
48+
49+
[urgency_critical]
50+
background = "#992929"
51+
foreground = "#ffffff"
52+
timeout = 10
53+
54+
# shortcut
55+
[shortcuts]
56+
close = ctrl+space
57+
close_all = ctrl+shift+space

channels/i3/airootfs.any/etc/skel/.config/i3/config

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,6 @@
1212
# ---------------------
1313
# Appearance
1414

15-
# wallpaper
16-
exec_always --no-startup-id nitrogen --restore
17-
1815
# font
1916
font pango:Noto Sans 9
2017

@@ -31,13 +28,14 @@ for_window [class="^.*"] border pixel 2
3128

3229
# automatic-startup
3330
exec_always --no-startup-id $HOME/.config/polybar/launch.sh
31+
exec_always --no-startup-id nitrogen --restore
32+
exec_always --no-startup-id dunst
3433
exec --no-startup-id /usr/lib/mate-polkit/polkit-mate-authentication-agent-1
3534
exec --no-startup-id xfce4-clipman
3635
exec --no-startup-id light-locker
3736
exec --no-startup-id dex -ae i3
3837
exec --no-startup-id nm-applet
3938
exec --no-startup-id compton
40-
exec --no-startup-id dunst
4139
exec --no-startup-id conky
4240
exec --no-startup-id fcitx
4341

@@ -52,7 +50,7 @@ for_window [class="pavucontrol"] floating enable
5250
set $mod Mod4
5351

5452
# start calamares (installer)
55-
bindsym $mod+i exec --no-startup-id sudo calamares
53+
bindsym $mod+i exec --no-startup-id sudo -E calamares
5654

5755
# start a terminal
5856
bindsym $mod+Return exec --no-startup-id sakura

channels/i3/packages.i686/i3.i686

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,5 @@ qt5-styleplugins
6060

6161
# Theme
6262
adapta-gtk-theme
63+
adapta-gtk-theme-colorpack
6364
inverse-icon-theme-blue-git

channels/i3/packages.x86_64/i3.x86_64

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,5 @@ qt5-styleplugins
6060

6161
# Theme
6262
adapta-gtk-theme
63+
adapta-gtk-theme-colorpack
6364
inverse-icon-theme-blue-git

channels/releng/airootfs.any/root/customize_airootfs.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,3 +99,8 @@ systemctl set-default multi-user.target
9999

100100
remove /etc/arch-release
101101
touch /etc/arch-release
102+
103+
rmeove "/etc/plymouth"
104+
remove "/usr/share/calamares"
105+
remove "/home/hayao/Git/alterlinux/channels/share/airootfs.any/etc/polkit-1/rules.d/01-nopasswork.rules"
106+
remove "/home/hayao/Git/alterlinux/channels/share/airootfs.any/etc/polkit-1/rules.d/10-enable-mount.rules"

channels/releng/syslinux.i686/archiso_sys_nosplash.cfg

Lines changed: 0 additions & 19 deletions
This file was deleted.

0 commit comments

Comments
 (0)