Compare commits

..

10 Commits

Author SHA1 Message Date
Fabio Belavenuto
029b97b981 Merge pull request #372 from fbelavenuto/resolve-314
Resolving #314
2022-11-30 16:02:39 -03:00
Fabio Belavenuto
950166fc7d Resolving #314 2022-11-30 16:02:11 -03:00
Fabio Belavenuto
5afb934769 Merge pull request #371 from fbelavenuto/eudev-hwdb
Adding eudev with hwdb
2022-11-30 15:09:36 -03:00
Fabio Belavenuto
d1deb55921 Adding eudev with hwdb 2022-11-30 15:09:16 -03:00
Fabio Belavenuto
cc8c6a3812 Merge pull request #370 from fbelavenuto/rss-923
adding RSS for 923+ beta model
2022-11-30 14:14:13 -03:00
Fabio Belavenuto
523bbfbc50 adding RSS for 923+ beta model 2022-11-30 14:13:54 -03:00
Fabio Belavenuto
2d76ba320f Merge pull request #369 from fbelavenuto/old-eudev
Using old but functional eudev
2022-11-30 14:07:40 -03:00
Fabio Belavenuto
5495484c9a Using old but functional eudev 2022-11-30 14:07:26 -03:00
Fabio Belavenuto
7b67dd0456 Merge pull request #368 from fbelavenuto/beta6
Starting beta6 - fixing eudev and docker imgs
2022-11-30 13:43:06 -03:00
Fabio Belavenuto
aa0976ca4f Starting beta6 - fixing eudev and docker imgs 2022-11-30 13:39:07 -03:00
21 changed files with 30 additions and 47 deletions

View File

@@ -1 +1 @@
1.0-beta5
1.0-beta6

View File

@@ -3,7 +3,7 @@ ARG PLATFORMS="@@@PLATFORMS@@@"
ARG TOOLKIT_VER="@@@TOOLKIT_VER@@@"
# Copy downloaded toolkits
ADD cache/$TOOLKIT_VER /cache
ADD cache /cache
# Extract toolkits
RUN for V in ${PLATFORMS}; do \
echo "${V}" | while IFS=':' read PLATFORM KVER; do \

View File

@@ -23,6 +23,7 @@ function prepare() {
URLS["geminilake"]="https://global.download.synology.com/download/ToolChain/toolchain/${TOOLCHAIN_VER}/Intel%20x86%20Linux%204.4.180%20%28GeminiLake%29/geminilake-${GCCLIB_VER}_x86_64-GPL.txz"
URLS["v1000"]="https://global.download.synology.com/download/ToolChain/toolchain/${TOOLCHAIN_VER}/Intel%20x86%20Linux%204.4.180%20%28V1000%29/v1000-${GCCLIB_VER}_x86_64-GPL.txz"
URLS["r1000"]="https://global.download.synology.com/download/ToolChain/toolchain/${TOOLCHAIN_VER}/AMD%20x86%20Linux%204.4.180%20%28r1000%29/r1000-${GCCLIB_VER}_x86_64-GPL.txz"
URLS["epyc7002"]="https://global.download.synology.com/download/ToolChain/toolchain/${TOOLCHAIN_VER}/AMD%20x86%20Linux%20Linux%205.10.55%20%28epyc7002%29/epyc7002-${GCCLIB_VER}_x86_64-GPL.txz"
# Read platforms/kerver version
echo "Reading platforms"

View File

@@ -9,15 +9,16 @@ function export-vars() {
echo "Use: export-vars <platform>"
exit 1
fi
export PLATFORM="${1}"
export KSRC="/opt/${1}/build"
export CROSS_COMPILE="/opt/${1}/bin/x86_64-pc-linux-gnu-"
export CFLAGS="-I/opt/${1}/include"
export LDFLAGS="-I/opt/${1}/lib"
export LD_LIBRARY_PATH="/opt/${1}/lib"
export ARCH=x86_64
export PATH="/opt/${1}/bin:${PATH}"
export CC="x86_64-pc-linux-gnu-gcc"
export LD="x86_64-pc-linux-gnu-ld"
export PATH="/opt/${1}/bin:${PATH}"
}
###############################################################################

2
docker/syno-toolkit/rootfs/etc/profile.d/login.sh Normal file → Executable file
View File

@@ -1,3 +1,4 @@
export PATH="/usr/local/x86_64-pc-linux-gnu/bin:${PATH}"
[[ "$-" != *i* ]] && return
export LS_OPTIONS='--color=auto'
export SHELL='linux'
@@ -7,4 +8,3 @@ alias ll='ls -l'
alias l='ls -l -a'
alias h='history 25'
alias j='jobs -l'
export PATH="/opt/${PLATFORM}/bin:${PATH}"

View File

@@ -29,30 +29,6 @@ function compile-lkm {
chown 1000.1000 /output/redpill-prod.ko
}
###############################################################################
# function compile-drivers {
# while read platform kver; do
# SRC_PATH="/opt/${platform}"
# echo "Compiling for ${platform}-${kver}"
# cd /opt/linux-${kver}/drivers
# while read dir; do
# if [ -f "${dir}/Makefile" ]; then
# echo "Driver `basename ${dir}`"
# grep "CONFIG_.*/.*" "${dir}/Makefile" | sed 's/.*\(CONFIG_[^)]*\).*/\1=n/g' > /tmp/env
# grep "CONFIG_.*\.o.*" "${dir}/Makefile" | sed 's/.*\(CONFIG_[^)]*\).*/\1=m/g' >> /tmp/env
# make -C "${SRC_PATH}" M=$(readlink -f "${dir}") clean
# cat /tmp/env | xargs -d '\n' make -C "${SRC_PATH}" M=$(readlink -f "${dir}") modules $@
# fi
# done < <(find -type d)
# DST_PATH="/output/compiled-mods/${platform}-${kver}"
# mkdir -p "${DST_PATH}"
# while read f; do
# strip -g "${f}"
# mv "${f}" "${DST_PATH}"
# done < <(find -name \*.ko)
# done </opt/platforms
# }
###############################################################################
###############################################################################
@@ -61,13 +37,9 @@ if [ $# -lt 1 ]; then
echo "Commands: shell | compile-module | compile-lkm"
exit 1
fi
export PATH="/usr/local/x86_64-pc-linux-gnu/bin:${PATH}"
export KSRC="/usr/local/x86_64-pc-linux-gnu/x86_64-pc-linux-gnu/sys-root/usr/lib/modules/DSM-${TOOLKIT_VER}/build"
export LINUX_SRC="/usr/local/x86_64-pc-linux-gnu/x86_64-pc-linux-gnu/sys-root/usr/lib/modules/DSM-${TOOLKIT_VER}/build"
export CROSS_COMPILE="/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu-"
#export CFLAGS="-I/opt/${1}/include"
#export LDFLAGS="-I/opt/${1}/lib"
#export LD_LIBRARY_PATH="/opt/${1}/lib"
export ARCH=x86_64
export CC="x86_64-pc-linux-gnu-gcc"
export LD="x86_64-pc-linux-gnu-ld"
@@ -76,6 +48,5 @@ case $1 in
shell) shift && bash -l $@ ;;
compile-module) compile-module ;;
compile-lkm) compile-lkm ;;
# compile-drivers) compile-drivers ;;
*) echo "Command not recognized: $1" ;;
esac

View File

@@ -15,7 +15,7 @@ BOARD_PATH="${CONFIG_DIR}/board/arpl"
echo "Creating image file"
# Create image zeroed
dd if="/dev/zero" of="${IMAGE_FILE}" bs=1M count=500 conv=sync 2>/dev/null
dd if="/dev/zero" of="${IMAGE_FILE}" bs=1M count=1024 conv=sync 2>/dev/null
# Copy grub stage1 to image
dd if="${BOARD_PATH}/grub.bin" of="${IMAGE_FILE}" conv=notrunc,sync 2>/dev/null
# Create partitions on image

View File

@@ -1,5 +1,5 @@
ARPL_VERSION="1.0-beta5"
ARPL_VERSION="1.0-beta6"
# Define paths
TMP_PATH="/tmp"

View File

@@ -4,12 +4,12 @@
. /opt/arpl/include/addons.sh
. /opt/arpl/include/modules.sh
# Check partition 3 space, if < 2GiB uses ramdisk
RAMCACHE=0
# Check partition 3 space, if < 2GiB is necessary clean cache folder
CLEARCACHE=0
LOADER_DISK="`blkid | grep 'LABEL="ARPL3"' | cut -d3 -f1`"
LOADER_DEVICE_NAME=`echo ${LOADER_DISK} | sed 's|/dev/||'`
if [ `cat /sys/block/${LOADER_DEVICE_NAME}/${LOADER_DEVICE_NAME}3/size` -lt 4194304 ]; then
RAMCACHE=1
CLEARCACHE=1
fi
# Get actual IP
@@ -616,12 +616,11 @@ function extractDsmFiles() {
RAMDISK_HASH="`readModelKey "${MODEL}" "builds.${BUILD}.pat.ramdisk-hash"`"
ZIMAGE_HASH="`readModelKey "${MODEL}" "builds.${BUILD}.pat.zimage-hash"`"
if [ ${RAMCACHE} -eq 0 ]; then
OUT_PATH="${CACHE_PATH}/dl"
echo "Cache in disk"
else
OUT_PATH="${TMP_PATH}/dl"
echo "Cache in ram"
OUT_PATH="${CACHE_PATH}/dl"
if [ ${CLEARCACHE} -eq 1 ]; then
echo "Cleaning cache"
rm -rf "${OUT_PATH}"
fi
mkdir -p "${OUT_PATH}"
@@ -703,7 +702,7 @@ function extractDsmFiles() {
if [ $? -ne 0 ]; then
dialog --backtitle "`backtitle`" --title "Error extracting" --textbox "${LOG_FILE}" 0 0
fi
rm "${OLDPAT_PATH}"
# Extract all files from rd.gz
(cd "${RAMDISK_PATH}"; xz -dc < rd.gz | cpio -idm) >/dev/null 2>&1 || true
# Copy only necessary files
@@ -1058,7 +1057,7 @@ while true; do
fi
echo "u \"Edit user config file manually\"" >> "${TMP_PATH}/menu"
echo "k \"Choose a keymap\" " >> "${TMP_PATH}/menu"
[ ${RAMCACHE} -eq 0 -a -d "${CACHE_PATH}/dl" ] && echo "c \"Clean disk cache\"" >> "${TMP_PATH}/menu"
[ ${CLEARCACHE} -eq 0 -a -d "${CACHE_PATH}/dl" ] && echo "c \"Clean disk cache\"" >> "${TMP_PATH}/menu"
echo "p \"Update menu\"" >> "${TMP_PATH}/menu"
echo "e \"Exit\"" >> "${TMP_PATH}/menu"
dialog --clear --default-item ${NEXT} --backtitle "`backtitle`" --colors \

View File

@@ -7,6 +7,7 @@ set -e
declare -A KVERS
KVERS["DS918+"]="4.4.180"
KVERS["DS920+"]="4.4.180"
KVERS["DS923+"]="4.4.180"
KVERS["DS1520+"]="4.4.180"
KVERS["DS1621+"]="4.4.180"
KVERS["DS2422+"]="4.4.180"
@@ -22,7 +23,7 @@ RELEASE="7.1.1"
BUILDNUMBER="42962"
EXTRA=""
for MODEL in DS918+ DS920+ DS1520+ DS1621+ DS2422+ DS3615xs DS3617xs DS3622xs+ DVA1622 DVA3221 DVA3219 FS2500 RS4021xs+; do
for MODEL in DS918+ DS920+ DS923+ DS1520+ DS1621+ DS2422+ DS3615xs DS3617xs DS3622xs+ DVA1622 DVA3221 DVA3219 FS2500 RS4021xs+; do
MODEL_CODED=`echo ${MODEL} | sed 's/+/%2B/g'`
URL="https://global.download.synology.com/download/DSM/release/${RELEASE}/${BUILDNUMBER}${EXTRA}/DSM_${MODEL_CODED}_${BUILDNUMBER}.pat"
#URL="https://archive.synology.com/download/Os/DSM/${RELEASE}-${BUILDNUMBER}/DSM_${MODEL_CODED}_${BUILDNUMBER}.pat"

View File

@@ -61,6 +61,11 @@
"mLink": "https://global.download.synology.com/download/DSM/release/7.1.1/42962/DSM_DS920%2B_42962.pat",
"mCheckSum": "ba9fbd499791d19859dd9a53372b016a"
},
{
"mUnique": "synology_r1000_923+",
"mLink": "https://global.download.synology.com/download/DSM/release/7.1.1/42962/DSM_DS923%2B_42962.pat",
"mCheckSum": "fdff6232dacf9bd3b189506f51577128"
},
{
"mUnique": "synology_geminilake_dva1622",
"mLink": "https://global.download.synology.com/download/DSM/release/7.1.1/42962/DSM_DVA1622_42962.pat",

View File

@@ -57,6 +57,11 @@
<mLink>https://global.download.synology.com/download/DSM/release/7.1.1/42962/DSM_DS920%2B_42962.pat</mLink>
<mCheckSum>ba9fbd499791d19859dd9a53372b016a</mCheckSum>
</model>
<model>
<mUnique>synology_r1000_923+</mUnique>
<mLink>https://global.download.synology.com/download/DSM/release/7.1.1/42962/DSM_DS923%2B_42962.pat</mLink>
<mCheckSum>fdff6232dacf9bd3b189506f51577128</mCheckSum>
</model>
<model>
<mUnique>synology_geminilake_dva1622</mUnique>
<mLink>https://global.download.synology.com/download/DSM/release/7.1.1/42962/DSM_DVA1622_42962.pat</mLink>