aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--README.md52
-rwxr-xr-xcreate_arm_img_urpmi.sh69
-rw-r--r--rpi2/second_stage_install.sh4
-rw-r--r--rpi3+/brcmfmac43430-sdio.txt66
-rw-r--r--rpi3+/brcmfmac43455-sdio.clm_blobbin0 -> 11231 bytes
-rw-r--r--rpi3+/brcmfmac43455-sdio.txt92
-rw-r--r--rpi3+/second_stage_install.sh4
-rw-r--r--rpi3/mageia4arm.cfg4
-rw-r--r--rpi3/second_stage_install.sh4
-rwxr-xr-xtools/install_graphical.sh1
10 files changed, 248 insertions, 48 deletions
diff --git a/README.md b/README.md
index cd01be0..e9cefd8 100644
--- a/README.md
+++ b/README.md
@@ -2,43 +2,43 @@
Outils servant à générer une image Mageia pour systèmes à base de processeurs arm
-Démarrage rapide:
+Démarrage rapide:
-Choisissez le dossier de configuration adapté à votre besoin (rpi ou xu4), sinon créez un nouveau dossier de configuration, copiez le fichier "mageia4arm.cfg.template"" à l'interieur et modifiez le selon vos besoins.
-Par défaut l'utilisateur est "pi"" avec le mot de passe "raspberry", et l'administrateur "root" avec le mot de passe "piroot"
+Choisissez le dossier de configuration adapté à votre besoin (rpi ou xu4), sinon créez un nouveau dossier de configuration, copiez le fichier "mageia4arm.cfg.template" à l'interieur et modifiez le selon vos besoins.
+Par défaut l'utilisateur est "pi" avec le mot de passe "raspberry", et l'administrateur "root" avec le mot de passe "piroot".
-Créer l'image:
-create_arm_img_urpmi.sh --all --config <dossier de configuration>
+Créer l'image:
+create_arm_img_urpmi.sh --all --config <dossier de configuration\>
-Aide:
-create_arm_img_urpmi.sh -h|--help
+Aide:
+create_arm_img_urpmi.sh -h|--help
-Vous pouvez adapter le script "second_stage_install.sh"" afin de compléter l'installation.
-Des scripts sont disponibles dans le dossier "tools", ils sont copié dans usr/local/bin/ dans l'image.
+Vous pouvez adapter le script "second_stage_install.sh" afin de compléter l'installation.
+Des scripts sont disponibles dans le dossier "tools", ils sont copié dans /usr/local/bin/ dans l'image.
-Premier lancement de l'image sur le raspberry pi:
-. lancer drakkeyboard afin de configurer le clavier
-. si vous avez besoin d'un gestionnaire graphique, lancer le script:
-install_graphical.sh \<gestionnaire-graphique\>( xfce, lxqt, plasma, ...) voir les métapaquetages disponibles dans "Environnement graphique" dans le gestionnaire de logiciels.
+Premier lancement de l'image sur le raspberry pi:
+- lancer drakkeyboard afin de configurer le clavier
+- si vous avez besoin d'un gestionnaire graphique, lancer le script:
+install_graphical.sh <gestionnaire-graphique\>( xfce, lxqt, plasma, ...) voir les métapaquetages disponibles dans "Environnement graphique" dans le gestionnaire de logiciels.
-This repository contains script to make image for arm based systems from Mageia repositories.
+This repository contains script to make image for arm based systems from Mageia repositories.
-Quick start:
+Quick start:
-Choose the config dir you need (rpi or xu4), else create a new config directory with "mageia4arm.cfg.template"" in and modify it as you need.
-By default username is "pi"" with password "raspberry" and root password is "piroot".
+Choose the config dir you need (rpi or xu4), else create a new config directory with "mageia4arm.cfg.template" in and modify it as you need.
+By default username is "pi" with password "raspberry" and root password is "piroot".
-create_arm_img_urpmi.sh --all --config <your config dir>
+create_arm_img_urpmi.sh --all --config <your config dir\>
-Help:
-create_arm_img_urpmi.sh -h|--help
+Help:
+create_arm_img_urpmi.sh -h|--help
-you can adapt the script "second_stage_install.sh"" to complete the installation.
-Some scripts are available in directory "tools". they are copied in /usr/local/bin/ in the image.
+you can adapt the script "second_stage_install.sh" to complete the installation.
+Some scripts are available in directory "tools". they are copied in /usr/local/bin/ in the image.
-First launch of the image on raspberry pi:
-. launch drakkeyboard for configure keyboard layout.
-. if you need a graphical environment, launch the script :
- install_graphical.sh \<graphical environment\> ( xfce, lxqt, plasma, ...), see "Graphical environment" in the Mageia application manager' meta packages.
+First launch of the image on raspberry pi:
+- launch drakkeyboard to configure keyboard layout.
+- if you need a graphical environment, launch the script :
+ install_graphical.sh <graphical environment\> ( xfce, lxqt, plasma, ...), see "Graphical environment" in the Mageia application manager meta packages.
diff --git a/create_arm_img_urpmi.sh b/create_arm_img_urpmi.sh
index a42c05b..84a10e3 100755
--- a/create_arm_img_urpmi.sh
+++ b/create_arm_img_urpmi.sh
@@ -62,17 +62,21 @@ function help()
echo "--all create ready to burn image of Mageia $MAGEIA_VERSION"
echo "--clean Clean all (suppress all) to make a new image"
echo "--size size of image default: 7Go"
+ echo "--build-path Path to the build directory of the image of Mageia $MAGEIA_VERSION"
+ echo "--target target system (for now rpi, odroid)"
+ echo "--target-version version of the target (0, 1, 2, 3 for rpi, 3 or 4 for odroid)"
+ echo "--config Path to config files"
+ echo "--bootfs filesystem of boot partition (ext4 or vfat) default: ext4"
+ echo "--nonfree activate nonfree repos"
+ echo "--tainted activate tainted repos"
+ echo "\nBuild levels:"
echo "--create-chroot Create the chroot directory"
echo "--addmedia add mirrors"
echo "--update-mirror update urpmi database"
echo "--install-basesystem install base system"
echo "--chroot chroot to arm directory and launch packages installation"
echo "--create-image Create the image of Mageia $MAGEIA_VERSION"
- echo "--build-path Path to the build directory of the image of Mageia $MAGEIA_VERSION"
- echo "--target target system (for now rpi, odroid)"
- echo "--target-version version of the target (0, 1, 2, 3 for rpi, 3 or 4 for odroid)"
- echo "--config Path to config files"
- echo "--bootfs filesystem of boot partition (ext4 or vfat) default: ext4"
+
echo -e "\nFor image size, make sure it fit on physical support. (Default size is 7 Go)"
}
@@ -182,12 +186,23 @@ function addmedia()
error "line $LINENO error $err - can't add medias from $MIRROR : exiting"
exit 1
fi
- title "activating non-free and tainted"
- /sbin/urpmi.update --urpmi-root "$BUILD_PATH" --no-ignore Nonfree\ Release Nonfree\ Updates Tainted\ Release Tainted\ Updates
- err=$?
- if [ $err -ne 0 ];then
- error "line $LINENO error $err - can't activate medias : exiting"
- exit 1
+ if [ $NONFREE -eq 1 ];then
+ title "activating non-free repos"
+ /sbin/urpmi.update --urpmi-root "$BUILD_PATH" --no-ignore Nonfree\ Release Nonfree\ Updates
+ err=$?
+ if [ $err -ne 0 ];then
+ error "line $LINENO error $err - can't activate medias nonfree : exiting"
+ exit 1
+ fi
+ fi
+ if [ $TAINTED -eq 1 ];then
+ title "activating tainted repos"
+ /sbin/urpmi.update --urpmi-root "$BUILD_PATH" --no-ignore Tainted\ Release Tainted\ Updates
+ err=$?
+ if [ $err -ne 0 ];then
+ error "line $LINENO error $err - can't activate medias tainted : exiting"
+ exit 1
+ fi
fi
}
@@ -536,12 +551,15 @@ copyingsystem()
UUID=$BOOT_UUID /mnt/arm_boot vfat defaults 0 0
UUID=$ROOT_UUID / ext4 defaults 0 0" > "$BUILD_PATH"/etc/fstab
-info "making /boot/extlinux/extlinux.conf"
-mkdir -p "$BUILD_PATH/boot/extlinux"
-sed -e s/\<UUID\>/$ROOT_UUID/g $SOURCE_PATH/$CONFIG_PATH/extlinux.conf >"$BUILD_PATH/boot/extlinux/extlinux.conf"
-KERNEL_ID=`basename $BUILD_PATH/usr/lib/linux-*`
-sed -i -e s/\<FDTDIR\>/$KERNEL_ID/g "$BUILD_PATH/boot/extlinux/extlinux.conf"
-
+ if [ ! -d "$BUILD_PATH/boot/extlinux" ];then
+ info "making /boot/extlinux/extlinux.conf"
+ mkdir -p "$BUILD_PATH/boot/extlinux"
+ fi
+ if [ ! -f "$BUILD_PATH/boot/extlinux/extlinux.conf" ];then
+ sed -e s/\<UUID\>/$ROOT_UUID/g $SOURCE_PATH/$CONFIG_PATH/extlinux.conf >"$BUILD_PATH/boot/extlinux/extlinux.conf"
+ KERNEL_ID=`basename $BUILD_PATH/usr/lib/linux-*`
+ sed -i -e s/\<FDTDIR\>/$KERNEL_ID/g "$BUILD_PATH/boot/extlinux/extlinux.conf"
+ fi
case $TARGET in
rpi)
@@ -566,7 +584,7 @@ brcmfmac" >> "$BUILD_PATH"/etc/modules
cp -v --preserve=mode "$FIRMWARE_PATH/$FIRMWARE_DIR/boot/start"* "$ARM_BOOT/"
cp -v --preserve=mode "$FIRMWARE_PATH/$FIRMWARE_DIR/boot/fixup"* "$ARM_BOOT/"
cp -v --preserve=mode "$FIRMWARE_PATH/$FIRMWARE_DIR/boot/bootcode.bin"* "$ARM_BOOT/"
- cp -v --preserve=mode "$FIRMWARE_PATH/$FIRMWARE_DIR/boot/overlays" "$ARM_BOOT/"
+ cp -vR --preserve=mode "$FIRMWARE_PATH/$FIRMWARE_DIR/boot/overlays" "$ARM_BOOT/"
info "copying u-boot binary to $ARM_BOOT"
case $TARGET_VERSION in
@@ -675,7 +693,7 @@ fi
# parsing commandline
-TEMP=$(getopt -o h,a --long all,help,clean,create-chroot,addmedia,create-image,,config:,target:,target-version:,chroot,bootfs:,install-basesystem,update-mirror,build-path:,size: -n $CMDNAME -- "$@")
+TEMP=$(getopt -o h,a --long all,help,clean,create-chroot,addmedia,create-image,,config:,target:,target-version:,chroot,bootfs:,install-basesystem,update-mirror,build-path:,size:,nonfree,tainted -n $CMDNAME -- "$@")
if [ $? -ne 0 ] ; then error "line $LINENO Failed parsing options." >&2 ; exit 1 ; fi
eval set -- "$TEMP"
@@ -757,6 +775,12 @@ do
BOOTFS_P=$2
shift 2
;;
+ --nonfree)
+ NONFREE_P=1
+ ;;
+ --tainted)
+ TAINTED_P=1
+ ;;
--)
shift
break;;
@@ -812,6 +836,13 @@ fi
if ! [ -z "$BOOTFS_P" ];then
BOOTFS=$BOOTFS_P
fi
+if ! [ -z "$NONFREE_P" ];then
+ NONFREE=$NONFREE_P
+fi
+if ! [ -z "$TAINTED_P" ];then
+ TAINTED=$TAINTED_P
+fi
+
info "Option: "$OPT
IMAGE="Mageia-${MAGEIA_VERSION}-$TARGET$TARGET_VERSION.img"
diff --git a/rpi2/second_stage_install.sh b/rpi2/second_stage_install.sh
index 1848789..eb105f7 100644
--- a/rpi2/second_stage_install.sh
+++ b/rpi2/second_stage_install.sh
@@ -23,7 +23,7 @@
#Install all packages you need
# No verifying rpm due to a bug in packages, some are not signed
-/usr/sbin/urpmi --auto --no-verify-rpm basesystem chrony rng-tools man openssh-server rfkill wireless-tools bluez wpa_supplicant make binutils dracut u-boot rsync kernel-desktop-latest mlocate drakx-kbd-mouse-x11
+/usr/sbin/urpmi --auto --no-verify-rpm basesystem chrony rng-tools man openssh-server rfkill wireless-tools bluez wpa_supplicant make binutils dracut u-boot rsync kernel-desktop-latest mlocate drakx-kbd-mouse-x11 glibc-i18ndata
/usr/bin/chown :chrony -R /etc/chrony.keys /var/log/chrony
@@ -39,3 +39,5 @@ dracut --kver $KV
rm -f $0
cp /boot/vmlinuz-* /boot/vmlinuz
cp /boot/initrd-* /boot/initrd
+
+alternatives --set soundprofile /etc/sound/profiles/alsa
diff --git a/rpi3+/brcmfmac43430-sdio.txt b/rpi3+/brcmfmac43430-sdio.txt
new file mode 100644
index 0000000..ea4f648
--- /dev/null
+++ b/rpi3+/brcmfmac43430-sdio.txt
@@ -0,0 +1,66 @@
+# NVRAM file for BCM943430WLPTH
+# 2.4 GHz, 20 MHz BW mode
+
+# The following parameter values are just placeholders, need to be updated.
+manfid=0x2d0
+prodid=0x0727
+vendid=0x14e4
+devid=0x43e2
+boardtype=0x0727
+boardrev=0x1101
+boardnum=22
+macaddr=00:90:4c:c5:12:38
+sromrev=11
+boardflags=0x00404201
+boardflags3=0x08000000
+xtalfreq=37400
+nocrc=1
+ag0=255
+aa2g=1
+ccode=ALL
+
+pa0itssit=0x20
+extpagain2g=0
+#PA parameters for 2.4GHz, measured at CHIP OUTPUT
+pa2ga0=-168,7161,-820
+AvVmid_c0=0x0,0xc8
+cckpwroffset0=5
+
+# PPR params
+maxp2ga0=84
+txpwrbckof=6
+cckbw202gpo=0
+legofdmbw202gpo=0x66111111
+mcsbw202gpo=0x77711111
+propbw202gpo=0xdd
+
+# OFDM IIR :
+ofdmdigfilttype=18
+ofdmdigfilttypebe=18
+# PAPD mode:
+papdmode=1
+papdvalidtest=1
+pacalidx2g=42
+papdepsoffset=-22
+papdendidx=58
+
+# LTECX flags
+ltecxmux=0
+ltecxpadnum=0x0102
+ltecxfnsel=0x44
+ltecxgcigpio=0x01
+
+il0macaddr=00:90:4c:c5:12:38
+wl0id=0x431b
+
+deadman_to=0xffffffff
+# muxenab: 0x1 for UART enable, 0x2 for GPIOs, 0x8 for JTAG
+muxenab=0x1
+# CLDO PWM voltage settings - 0x4 - 1.1 volt
+#cldo_pwm=0x4
+
+#VCO freq 326.4MHz
+spurconfig=0x3
+
+edonthd20l=-75
+edoffthd20ul=-80
diff --git a/rpi3+/brcmfmac43455-sdio.clm_blob b/rpi3+/brcmfmac43455-sdio.clm_blob
new file mode 100644
index 0000000..09b930b
--- /dev/null
+++ b/rpi3+/brcmfmac43455-sdio.clm_blob
Binary files differ
diff --git a/rpi3+/brcmfmac43455-sdio.txt b/rpi3+/brcmfmac43455-sdio.txt
new file mode 100644
index 0000000..260c929
--- /dev/null
+++ b/rpi3+/brcmfmac43455-sdio.txt
@@ -0,0 +1,92 @@
+# Cloned from bcm94345wlpagb_p2xx.txt
+NVRAMRev=$Rev: 498373 $
+sromrev=11
+vendid=0x14e4
+devid=0x43ab
+manfid=0x2d0
+prodid=0x06e4
+#macaddr=00:90:4c:c5:12:38
+macaddr=b8:27:eb:74:f2:6c
+nocrc=1
+boardtype=0x6e4
+boardrev=0x1304
+
+#XTAL 37.4MHz
+xtalfreq=37400
+
+btc_mode=1
+#------------------------------------------------------
+#boardflags: 5GHz eTR switch by default
+# 2.4GHz eTR switch by default
+# bit1 for btcoex
+boardflags=0x00480201
+boardflags2=0x40800000
+boardflags3=0x48200100
+phycal_tempdelta=15
+rxchain=1
+txchain=1
+aa2g=1
+aa5g=1
+tssipos5g=1
+tssipos2g=1
+femctrl=0
+AvVmid_c0=1,165,2,100,2,100,2,100,2,100
+pa2ga0=-129,6525,-718
+pa2ga1=-149,4408,-601
+pa5ga0=-185,6836,-815,-186,6838,-815,-184,6859,-815,-184,6882,-818
+pa5ga1=-202,4285,-574,-201,4312,-578,-196,4391,-586,-201,4294,-575
+itrsw=1
+pdoffsetcckma0=2
+pdoffset2gperchan=0,-2,1,0,1,0,1,1,1,0,0,-1,-1,0
+pdoffset2g40ma0=16
+pdoffset40ma0=0x8888
+pdoffset80ma0=0x8888
+extpagain5g=2
+extpagain2g=2
+tworangetssi2g=1
+tworangetssi5g=1
+# LTECX flags
+# WCI2
+ltecxmux=0
+ltecxpadnum=0x0504
+ltecxfnsel=0x22
+ltecxgcigpio=0x32
+
+maxp2ga0=80
+ofdmlrbw202gpo=0x0022
+dot11agofdmhrbw202gpo=0x4442
+mcsbw202gpo=0x98444422
+mcsbw402gpo=0x98444422
+maxp5ga0=82,82,82,82
+mcsbw205glpo=0xb9555000
+mcsbw205gmpo=0xb9555000
+mcsbw205ghpo=0xb9555000
+mcsbw405glpo=0xb9555000
+mcsbw405gmpo=0xb9555000
+mcsbw405ghpo=0xb9555000
+mcsbw805glpo=0xb9555000
+mcsbw805gmpo=0xb9555000
+mcsbw805ghpo=0xb9555000
+
+swctrlmap_2g=0x00000000,0x00000000,0x00000000,0x010000,0x3ff
+swctrlmap_5g=0x00100010,0x00200020,0x00200020,0x010000,0x3fe
+swctrlmapext_5g=0x00000000,0x00000000,0x00000000,0x000000,0x3
+swctrlmapext_2g=0x00000000,0x00000000,0x00000000,0x000000,0x3
+
+vcodivmode=1
+deadman_to=481500000
+
+ed_thresh2g=-54
+ed_thresh5g=-54
+eu_edthresh2g=-54
+eu_edthresh5g=-54
+ldo1=4
+rawtempsense=0x1ff
+cckPwrIdxCorr=3
+cckTssiDelay=150
+ofdmTssiDelay=150
+txpwr2gAdcScale=1
+txpwr5gAdcScale=1
+dot11b_opts=0x3aa85
+cbfilttype=1
+fdsslevel_ch11=6
diff --git a/rpi3+/second_stage_install.sh b/rpi3+/second_stage_install.sh
index 1848789..eb105f7 100644
--- a/rpi3+/second_stage_install.sh
+++ b/rpi3+/second_stage_install.sh
@@ -23,7 +23,7 @@
#Install all packages you need
# No verifying rpm due to a bug in packages, some are not signed
-/usr/sbin/urpmi --auto --no-verify-rpm basesystem chrony rng-tools man openssh-server rfkill wireless-tools bluez wpa_supplicant make binutils dracut u-boot rsync kernel-desktop-latest mlocate drakx-kbd-mouse-x11
+/usr/sbin/urpmi --auto --no-verify-rpm basesystem chrony rng-tools man openssh-server rfkill wireless-tools bluez wpa_supplicant make binutils dracut u-boot rsync kernel-desktop-latest mlocate drakx-kbd-mouse-x11 glibc-i18ndata
/usr/bin/chown :chrony -R /etc/chrony.keys /var/log/chrony
@@ -39,3 +39,5 @@ dracut --kver $KV
rm -f $0
cp /boot/vmlinuz-* /boot/vmlinuz
cp /boot/initrd-* /boot/initrd
+
+alternatives --set soundprofile /etc/sound/profiles/alsa
diff --git a/rpi3/mageia4arm.cfg b/rpi3/mageia4arm.cfg
index e05172d..7530c5d 100644
--- a/rpi3/mageia4arm.cfg
+++ b/rpi3/mageia4arm.cfg
@@ -17,6 +17,10 @@
MAGEIA_VERSION="7"
ARM_VERSION="armv7hl"
+# Activate / deactivate nonfree et tainted
+# value 0 to deactivate or 1 to activate
+NONFREE="0"
+TAINTED="0"
#target plateform (xu3-4 or rpi)
TARGET="rpi"
diff --git a/rpi3/second_stage_install.sh b/rpi3/second_stage_install.sh
index 1848789..eb105f7 100644
--- a/rpi3/second_stage_install.sh
+++ b/rpi3/second_stage_install.sh
@@ -23,7 +23,7 @@
#Install all packages you need
# No verifying rpm due to a bug in packages, some are not signed
-/usr/sbin/urpmi --auto --no-verify-rpm basesystem chrony rng-tools man openssh-server rfkill wireless-tools bluez wpa_supplicant make binutils dracut u-boot rsync kernel-desktop-latest mlocate drakx-kbd-mouse-x11
+/usr/sbin/urpmi --auto --no-verify-rpm basesystem chrony rng-tools man openssh-server rfkill wireless-tools bluez wpa_supplicant make binutils dracut u-boot rsync kernel-desktop-latest mlocate drakx-kbd-mouse-x11 glibc-i18ndata
/usr/bin/chown :chrony -R /etc/chrony.keys /var/log/chrony
@@ -39,3 +39,5 @@ dracut --kver $KV
rm -f $0
cp /boot/vmlinuz-* /boot/vmlinuz
cp /boot/initrd-* /boot/initrd
+
+alternatives --set soundprofile /etc/sound/profiles/alsa
diff --git a/tools/install_graphical.sh b/tools/install_graphical.sh
index a10ce12..847d653 100755
--- a/tools/install_graphical.sh
+++ b/tools/install_graphical.sh
@@ -26,5 +26,6 @@ else
. $PATH/install_gstreamer.sh
echo "installing task-$1"
/usr/sbin/urpmi --auto --no-verify-rpm task-$1 sox sddm
+ /usr/bin/alternatives --config soundprofile
fi
/usr/bin/systemctl enable sddm