Skip to content

Commit

Permalink
Relabel SteamOS version variable.
Browse files Browse the repository at this point in the history
  • Loading branch information
fewtarius committed Dec 6, 2024
1 parent 072f6ba commit c99adbd
Show file tree
Hide file tree
Showing 14 changed files with 39 additions and 36 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export WORK_DIR := ${BUILD_DIR}/_work
export IMAGE_DIR := ${BUILD_DIR}/release/images
export REPO_DIR := ${BUILD_DIR}/release/repos
export BUILD_VER := $(shell date +%Y%m%d.%H%M)
export UPSTREAM_VERSION := 3.6
export STEAMOS_VERSION := 3.6

RUN_ARGS := $(wordlist 2,$(words $(MAKECMDGOALS)),$(MAKECMDGOALS))
$(eval $(RUN_ARGS):;@:)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@
# SPDX-License-Identifier: GPL-2.0
# Copyright (C) 2024-present Fewtarius

source /etc/os-release

rm -f /etc/pacman.d/steamfork-mirrorlist
steamfork-get-mirror random | while read line
do
echo "Server = https://${line}/repos/rel" >>/etc/pacman.d/steamfork-mirrorlist
echo "Server = https://${line}/repos/${STEAMOS_VERSION}" >>/etc/pacman.d/steamfork-mirrorlist
done
12 changes: 6 additions & 6 deletions metadata/pacman.conf
Original file line number Diff line number Diff line change
Expand Up @@ -76,25 +76,25 @@ LocalFileSigLevel = Optional
[steamfork]
Include = /etc/pacman.d/steamfork-mirrorlist

[jupiter-@UPSTREAM_VERSION@]
[jupiter-@STEAMOS_VERSION@]
Server = https://steamdeck-packages.steamos.cloud/archlinux-mirror/$repo/os/$arch

[holo-@UPSTREAM_VERSION@]
[holo-@STEAMOS_VERSION@]
Server = https://steamdeck-packages.steamos.cloud/archlinux-mirror/$repo/os/$arch

[core-@UPSTREAM_VERSION@]
[core-@STEAMOS_VERSION@]
Server = https://steamdeck-packages.steamos.cloud/archlinux-mirror/$repo/os/$arch

[extra-@UPSTREAM_VERSION@]
[extra-@STEAMOS_VERSION@]
Server = https://steamdeck-packages.steamos.cloud/archlinux-mirror/$repo/os/$arch

#[community-testing]
#Include = /etc/pacman.d/mirrorlist

[community-@UPSTREAM_VERSION@]
[community-@STEAMOS_VERSION@]
Server = https://steamdeck-packages.steamos.cloud/archlinux-mirror/$repo/os/$arch

[multilib-@UPSTREAM_VERSION@]
[multilib-@STEAMOS_VERSION@]
Server = https://steamdeck-packages.steamos.cloud/archlinux-mirror/$repo/os/$arch

# An example of a custom package repository. See the pacman manpage for
Expand Down
12 changes: 6 additions & 6 deletions metadata/steamfork-mirrorlist
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Server = https://www.steamfork.org/@UPSTREAM_VERSION@/@RELEASE_TYPE@
Server = https://www1.ny.steamfork.org/@UPSTREAM_VERSION@/@RELEASE_TYPE@
Server = https://www1.da.steamfork.org/@UPSTREAM_VERSION@/@RELEASE_TYPE@
Server = https://www1.sj.steamfork.org/@UPSTREAM_VERSION@/@RELEASE_TYPE@
Server = https://www1.as.steamfork.org/@UPSTREAM_VERSION@/@RELEASE_TYPE@
Server = https://www2.as.steamfork.org/@UPSTREAM_VERSION@/@RELEASE_TYPE@
Server = https://www.steamfork.org/@STEAMOS_VERSION@/@RELEASE_TYPE@
Server = https://www1.ny.steamfork.org/@STEAMOS_VERSION@/@RELEASE_TYPE@
Server = https://www1.da.steamfork.org/@STEAMOS_VERSION@/@RELEASE_TYPE@
Server = https://www1.sj.steamfork.org/@STEAMOS_VERSION@/@RELEASE_TYPE@
Server = https://www1.as.steamfork.org/@STEAMOS_VERSION@/@RELEASE_TYPE@
Server = https://www2.as.steamfork.org/@STEAMOS_VERSION@/@RELEASE_TYPE@
2 changes: 1 addition & 1 deletion rootfs/installer/package_lists/full.x86_64
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ gpm
zenity
gptfdisk
grml-zsh-config
core-@UPSTREAM_VERSION@/grub
core-@STEAMOS_VERSION@/grub
hdparm
hyperv
intel-ucode
Expand Down
2 changes: 1 addition & 1 deletion rootfs/installer/package_lists/minimal.x86_64
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ gpm
zenity
gptfdisk
grml-zsh-config
core-${UPSTREAM_VERSION}/grub
core-${STEAMOS_VERSION}/grub
hdparm
hyperv
intel-ucode
Expand Down
9 changes: 5 additions & 4 deletions rootfs/steamfork/build-image
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ case $key in
shift
;;
--upstream_ver)
UPSTREAM_VERSION=$2
echo "Upstream Version: ${UPSTREAM_VERSION}"
STEAMOS_VERSION=$2
echo "Upstream Version: ${STEAMOS_VERSION}"
shift
shift
;;
Expand Down Expand Up @@ -137,12 +137,12 @@ mkdir -p ${WORKDIR}

PACCFG_SOURCE="metadata/pacman.conf"
cp -f ${PACCFG_SOURCE} ${WORKDIR}
sed -i 's~@UPSTREAM_VERSION@~'${UPSTREAM_VERSION}'~g' ${WORKDIR}/pacman.conf
sed -i 's~@STEAMOS_VERSION@~'${STEAMOS_VERSION}'~g' ${WORKDIR}/pacman.conf
PACCFG=${WORKDIR}/pacman.conf

SF_PACCFG_SOURCE="metadata/steamfork-mirrorlist"
cp -f ${SF_PACCFG_SOURCE} ${WORKDIR}
sed -i 's~@UPSTREAM_VERSION@~'${UPSTREAM_VERSION}'~g' ${WORKDIR}/steamfork-mirrorlist
sed -i 's~@STEAMOS_VERSION@~'${STEAMOS_VERSION}'~g' ${WORKDIR}/steamfork-mirrorlist
SF_PACCFG=${WORKDIR}/steamfork-mirrorlist

mkdir -p ${OUTPUT}
Expand Down Expand Up @@ -209,6 +209,7 @@ LOGO=steamos
VERSION_ID="${RELEASE_TAG}"
VARIANT_ID="${RELEASE_TYPE}"
BUILD_ID="${RELEASE_TAG}"
STEAMOS_VERSION="${STEAMOS_VERSION}"
EOF

echo "Write steamfork-release"
Expand Down
4 changes: 2 additions & 2 deletions rootfs/steamfork/presets/minimal.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export DISABLED_SERVICES=()
export PLYMOUTH_THEME=""
export FINAL_DISTRIB_IMAGE=${BUILDVER}
export KERNELCHOICE="linux"
export BASE_BOOTSTRAP_PKGS="base base-devel linux-firmware intel-ucode amd-ucode dkms jq btrfs-progs core-${UPSTREAM_VERSION}/grub efibootmgr openssh"
export BASE_BOOTSTRAP_PKGS="base base-devel linux-firmware intel-ucode amd-ucode dkms jq btrfs-progs core-${STEAMOS_VERSION}/grub efibootmgr openssh"
export STEAMOS_PKGS="acl
accountsservice
adobe-source-code-pro-fonts
Expand Down Expand Up @@ -259,7 +259,7 @@ export STEAMOS_PKGS="acl
linux-api-headers
linux-firmware
linux-firmware-whence
extra-${UPSTREAM_VERSION}/llvm
extra-${STEAMOS_VERSION}/llvm
lsof
lz4
lzo
Expand Down
2 changes: 1 addition & 1 deletion rootfs/steamfork/presets/rel.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export DISABLED_SERVICES=(jupiter-controller-update.service
export PLYMOUTH_THEME="steamos"
export FINAL_DISTRIB_IMAGE=${BUILDVER}
export KERNELCHOICE="linux"
export BASE_BOOTSTRAP_PKGS="base base-devel linux-firmware amd-ucode intel-ucode sddm-wayland dkms jq btrfs-progs core-${UPSTREAM_VERSION}/grub efibootmgr openssh plymouth"
export BASE_BOOTSTRAP_PKGS="base base-devel linux-firmware amd-ucode intel-ucode sddm-wayland dkms jq btrfs-progs core-${STEAMOS_VERSION}/grub efibootmgr openssh plymouth"
export STEAMOS_PKGS="accounts-qml-module
accountsservice
acl
Expand Down
4 changes: 2 additions & 2 deletions scripts/mkimage
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,10 @@ else
fi

cp -f ${INSTALLER_DIR}/package_lists/${PACKAGESET}.x86_64 ${INSTALLER_DIR}/packages.x86_64
sed -i 's~@UPSTREAM_VERSION@~'${UPSTREAM_VERSION}'~g' ${INSTALLER_DIR}/packages.x86_64
sed -i 's~@STEAMOS_VERSION@~'${STEAMOS_VERSION}'~g' ${INSTALLER_DIR}/packages.x86_64

# Build the SteamFork image
sudo rootfs/steamfork/build-image --flavor ${RELEASE_TYPE} --deployment_rel ${RELEASE_TYPE} --upstream_ver "${UPSTREAM_VERSION}" --snapshot_ver "${BUILD_VER}" --workdir "${WORK_DIR}" --output-dir "${IMAGE_DIR}" --add-release
sudo rootfs/steamfork/build-image --flavor ${RELEASE_TYPE} --deployment_rel ${RELEASE_TYPE} --upstream_ver "${STEAMOS_VERSION}" --snapshot_ver "${BUILD_VER}" --workdir "${WORK_DIR}" --output-dir "${IMAGE_DIR}" --add-release

# Prep for the installation image
source ${IMAGE_DIR}/latest_${RELEASE_TYPE}.releasemeta
Expand Down
4 changes: 2 additions & 2 deletions scripts/mkpackage
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ do
KEY="$1"
case ${KEY} in
--branch)
UPSTREAM_VERSION="$2"
STEAMOS_VERSION="$2"
shift # past argument
shift # past value
;;
Expand All @@ -53,7 +53,7 @@ fi

BUILDUSER=${USER}
WORK_DIR="${WORK_DIR}/packages/${1}"
REPO_DIR="${REPO_DIR}/${UPSTREAM_VERSION}"
REPO_DIR="${REPO_DIR}/${STEAMOS_VERSION}"

sudo steamos-readonly disable
sudo rm -rf /var/lib/pacman/db.lck ${WORK_DIR}
Expand Down
6 changes: 3 additions & 3 deletions scripts/modules/github-tag
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ PACKAGE="${1}"
DATA_SOURCE="https://api.github.com/repos/${2}/tags"
WORK_DIR="${HOME}/.update_tmp/${PACKAGE}"

UPSTREAM_VERSION=$(curl --url "${DATA_SOURCE}" 2>/dev/null | jq -r '.[0].name')
STEAMOS_VERSION=$(curl --url "${DATA_SOURCE}" 2>/dev/null | jq -r '.[0].name')
if [ ! -d "${DATA_DIR}" ]
then
mkdir -p ${DATA_DIR}
Expand All @@ -18,7 +18,7 @@ then
DOWNSTREAM_VERSION="$(cat ${DATA_DIR}/${PACKAGE})"
fi

if [ ! "${UPSTREAM_VERSION}" = "${DOWNSTREAM_VERSION}" ]
if [ ! "${STEAMOS_VERSION}" = "${DOWNSTREAM_VERSION}" ]
then
echo "${UPSTREAM_VERSION}" | tee ${DATA_DIR}/${PACKAGE}
echo "${STEAMOS_VERSION}" | tee ${DATA_DIR}/${PACKAGE}
fi
6 changes: 3 additions & 3 deletions scripts/modules/gitlab-tag
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ fi
DATA_SOURCE="https://${BASE_URL}/api/v4/projects/${2}/repository/tags"
WORK_DIR="${HOME}/.update_tmp/${PACKAGE}"

UPSTREAM_VERSION=$(curl --url "${DATA_SOURCE}" 2>/dev/null | jq -r '.[0] | .name')
STEAMOS_VERSION=$(curl --url "${DATA_SOURCE}" 2>/dev/null | jq -r '.[0] | .name')
if [ ! -d "${DATA_DIR}" ]
then
mkdir -p ${DATA_DIR}
Expand All @@ -24,7 +24,7 @@ then
DOWNSTREAM_VERSION="$(cat ${DATA_DIR}/${PACKAGE})"
fi

if [ ! "${UPSTREAM_VERSION#*-}" = "${DOWNSTREAM_VERSION}" ]
if [ ! "${STEAMOS_VERSION#*-}" = "${DOWNSTREAM_VERSION}" ]
then
echo "${UPSTREAM_VERSION#*-}" | tee ${DATA_DIR}/${PACKAGE}
echo "${STEAMOS_VERSION#*-}" | tee ${DATA_DIR}/${PACKAGE}
fi
6 changes: 3 additions & 3 deletions scripts/modules/linux-tag
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ else
fi

cd ${WORK_DIR}/${PACKAGE}
UPSTREAM_VERSION="$(git tag | sort -V | grep -v 'rc' | tail -n 1)"
STEAMOS_VERSION="$(git tag | sort -V | grep -v 'rc' | tail -n 1)"

if [ ! -d "${DATA_DIR}" ]
then
Expand All @@ -35,7 +35,7 @@ then
DOWNSTREAM_VERSION="$(cat ${DATA_DIR}/${PACKAGE})"
fi

if [ ! "${UPSTREAM_VERSION}" = "${DOWNSTREAM_VERSION}" ]
if [ ! "${STEAMOS_VERSION}" = "${DOWNSTREAM_VERSION}" ]
then
echo "${UPSTREAM_VERSION}" | tee ${DATA_DIR}/${PACKAGE}
echo "${STEAMOS_VERSION}" | tee ${DATA_DIR}/${PACKAGE}
fi

0 comments on commit c99adbd

Please sign in to comment.