Compare commits
191 commits
rcu/initia
...
edge
Author | SHA1 | Date | |
---|---|---|---|
396c98208d | |||
b345573aa1 | |||
257e019992 | |||
97ed4992d7 | |||
7814f05e1c | |||
9bf9771b8c | |||
6e698a0974 | |||
367a606da2 | |||
26657f4d57 | |||
9e2e00cd44 | |||
5771d09151 | |||
0414f86242 | |||
fb7a3fe81b | |||
3ffe64d0d4 | |||
15d01121ba | |||
d24323205e | |||
eef1e89d88 | |||
623d98575e | |||
b306518289 | |||
63f6a6099f | |||
7e21600868 | |||
714437157c | |||
f82ac83d0b | |||
b9b609bedf | |||
8ffac41cb8 | |||
7ffb4b3105 | |||
743ceb8dbe | |||
021b81131e | |||
d00a14e695 | |||
a6e60edfd9 | |||
68130cdf8a | |||
888654be5c | |||
d6e00b6395 | |||
77dc41c8aa | |||
1478a9f5c7 | |||
fc3cfbc01c | |||
659bd20ba1 | |||
970fd7297f | |||
135bcd5a89 | |||
e7bef354af | |||
260b8c3da6 | |||
9a81361936 | |||
f124e1fd95 | |||
3a9141372b | |||
e0a5952518 | |||
14348459f1 | |||
92b265a1d0 | |||
07ce4b2776 | |||
9b5788e012 | |||
580e136768 | |||
32a461c894 | |||
9320defbce | |||
9c03466cc0 | |||
177efa00c2 | |||
438d6d6e3e | |||
638732a089 | |||
d09e518d1f | |||
ece30e0fbb | |||
8a2a28342a | |||
9d6bf2f5a2 | |||
10821c427a | |||
bc63f1ddb8 | |||
187eb88770 | |||
60b6bb1f9a | |||
5edd40d7f0 | |||
7870ee72dc | |||
2f4998dfb6 | |||
783a964410 | |||
ff94611df0 | |||
bdc0c313c6 | |||
21082688af | |||
a0993c9e31 | |||
686e6a6504 | |||
497771fe9e | |||
0807d658c5 | |||
7320512e66 | |||
475c43723c | |||
ad7d9444cc | |||
87e02ab716 | |||
7671a9d567 | |||
65f2a53a44 | |||
4d473acf9e | |||
59705e3486 | |||
72ad06acd7 | |||
e5f83095e3 | |||
eb0374cfba | |||
07ea5d4b03 | |||
091908e87e | |||
0b3331610d | |||
948e244824 | |||
3124031a00 | |||
64d88aa2e1 | |||
a5cd9ca969 | |||
ddb15faac6 | |||
bdb37e35ee | |||
1c7eeb3dce | |||
08ee79d032 | |||
81ac0611da | |||
f57dc997f7 | |||
7440e781b8 | |||
65a5f41649 | |||
507663db3b | |||
f5bbad0712 | |||
ecc61a2182 | |||
1f7767fc5b | |||
e5237392b1 | |||
43905a4a72 | |||
2a72f32a3a | |||
b29ff4dcae | |||
d87a333de8 | |||
849cc1d7b3 | |||
ae8c40104c | |||
29d690fe52 | |||
ab3231afda | |||
8ac74918a3 | |||
d3888ec0a3 | |||
c9d0bd0b1e | |||
e9d494a147 | |||
fddd91b20c | |||
104708e9a6 | |||
34e0757763 | |||
068b275bf0 | |||
0c00fe0b12 | |||
4c1e2a5ad1 | |||
aa38757ca4 | |||
01bb50572f | |||
3ab0e08102 | |||
cead3482d0 | |||
0fda66c95d | |||
536488e38a | |||
99aad33f76 | |||
1687c6e040 | |||
72ee0d8d1a | |||
c1565cc31e | |||
d070b3f938 | |||
9115f3f438 | |||
70a9a1d2ef | |||
7f99c70ce5 | |||
c2f2218c0a | |||
2932096ea6 | |||
34a6944283 | |||
78d9f34889 | |||
d9314aa56b | |||
d8dcb89d2d | |||
2e84eef9d9 | |||
a4df28e246 | |||
53a721ead8 | |||
b84114435d | |||
ec037fc6fd | |||
e1da3f4eb1 | |||
8f83341ebe | |||
7380fdd1ac | |||
8ea01a36bf | |||
e7e9e8df9c | |||
78a43bb4de | |||
de61d62ece | |||
58efa9d1c5 | |||
e1c4603357 | |||
0b85dd2b35 | |||
22a9e782c2 | |||
8447cddacb | |||
04adb3958c | |||
ad6af41168 | |||
6c21bf267a | |||
106ef2e7c0 | |||
c2788b3527 | |||
7fe91bbe55 | |||
123f23ae47 | |||
bace283c40 | |||
027acc5f24 | |||
d180f3c84e | |||
5fb9235a6f | |||
293424b1fc | |||
dd14ec4214 | |||
f8f3c3f623 | |||
b82a63b4f3 | |||
ccf45ced96 | |||
fd52fe031b | |||
2054dc7f6c | |||
2c693a0735 | |||
aa5271111c | |||
ecb91c7a17 | |||
caf4fa9ccd | |||
da47967494 | |||
0c3e1a5643 | |||
dd4806d73f | |||
7a6e398a09 | |||
b2496b6e09 | |||
97356cba4f | |||
5b0ae29dca | |||
708afd7f0e |
290 changed files with 3398 additions and 11876 deletions
|
@ -1,27 +1,26 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
# shellcheck disable=SC3043
|
# shellcheck disable=SC3043
|
||||||
|
|
||||||
. $CI_PROJECT_DIR/.gitlab/bin/functions.sh
|
. /usr/local/lib/functions.sh
|
||||||
|
|
||||||
# shellcheck disable=SC3040
|
# shellcheck disable=SC3040
|
||||||
set -eu -o pipefail
|
set -eu -o pipefail
|
||||||
|
|
||||||
readonly APORTSDIR=$CI_PROJECT_DIR
|
readonly APORTSDIR=$CI_PROJECT_DIR
|
||||||
readonly REPOS="cross backports user testing community"
|
readonly REPOS="backports user"
|
||||||
readonly ALPINE_REPOS="main community"
|
readonly ALPINE_REPOS="main community testing"
|
||||||
readonly ARCH=$(apk --print-arch)
|
readonly ARCH=$(apk --print-arch)
|
||||||
# gitlab variables
|
# gitlab variables
|
||||||
readonly BASEBRANCH=$CI_MERGE_REQUEST_TARGET_BRANCH_NAME
|
readonly BASEBRANCH=$CI_MERGE_REQUEST_TARGET_BRANCH_NAME
|
||||||
|
|
||||||
: "${REPODEST:=$HOME/packages}"
|
: "${REPODEST:=$HOME/packages}"
|
||||||
: "${MIRROR:=https://lab.ilot.io/ayakael/repo-apk/-/raw}"
|
: "${MIRROR:=https://ayakael.net/api/packages/forge/alpine}"
|
||||||
: "${ALPINE_MIRROR:=http://dl-cdn.alpinelinux.org/alpine}"
|
: "${ALPINE_MIRROR:=http://dl-cdn.alpinelinux.org/alpine}"
|
||||||
: "${MAX_ARTIFACT_SIZE:=300000000}" #300M
|
: "${MAX_ARTIFACT_SIZE:=300000000}" #300M
|
||||||
: "${CI_DEBUG_BUILD:=}"
|
: "${CI_DEBUG_BUILD:=}"
|
||||||
|
|
||||||
: "${CI_ALPINE_BUILD_OFFSET:=0}"
|
: "${CI_ALPINE_BUILD_OFFSET:=0}"
|
||||||
: "${CI_ALPINE_BUILD_LIMIT:=9999}"
|
: "${CI_ALPINE_BUILD_LIMIT:=9999}"
|
||||||
: "${CI_ALPINE_TARGET_ARCH:=$(uname -m)}"
|
|
||||||
|
|
||||||
msg() {
|
msg() {
|
||||||
local color=${2:-green}
|
local color=${2:-green}
|
||||||
|
@ -71,7 +70,7 @@ report() {
|
||||||
|
|
||||||
get_release() {
|
get_release() {
|
||||||
case $BASEBRANCH in
|
case $BASEBRANCH in
|
||||||
v*) echo "${BASEBRANCH%-*}";;
|
v*) echo "$BASEBRANCH";;
|
||||||
edge) echo edge;;
|
edge) echo edge;;
|
||||||
*) die "Branch \"$BASEBRANCH\" not supported!"
|
*) die "Branch \"$BASEBRANCH\" not supported!"
|
||||||
esac
|
esac
|
||||||
|
@ -80,9 +79,8 @@ get_release() {
|
||||||
build_aport() {
|
build_aport() {
|
||||||
local repo="$1" aport="$2"
|
local repo="$1" aport="$2"
|
||||||
cd "$APORTSDIR/$repo/$aport"
|
cd "$APORTSDIR/$repo/$aport"
|
||||||
export CHOST=$CI_ALPINE_TARGET_ARCH
|
|
||||||
if abuild -r 2>&1 | report "build-$aport"; then
|
if abuild -r 2>&1 | report "build-$aport"; then
|
||||||
checkapk | report "checkapk-$aport" || true
|
checkapk 2>&1 | report "checkapk-$aport" || true
|
||||||
aport_ok="$aport_ok $repo/$aport"
|
aport_ok="$aport_ok $repo/$aport"
|
||||||
else
|
else
|
||||||
aport_ng="$aport_ng $repo/$aport"
|
aport_ng="$aport_ng $repo/$aport"
|
||||||
|
@ -92,12 +90,6 @@ build_aport() {
|
||||||
check_aport() {
|
check_aport() {
|
||||||
local repo="$1" aport="$2"
|
local repo="$1" aport="$2"
|
||||||
cd "$APORTSDIR/$repo/$aport"
|
cd "$APORTSDIR/$repo/$aport"
|
||||||
export CHOST=$CI_ALPINE_TARGET_ARCH
|
|
||||||
# TODO: this enables crossbuild only on user, this should be cleaner
|
|
||||||
if [ "$repo" != "user" ] && [ "$repo" != "backports" ] && [ "$CI_ALPINE_TARGET_ARCH" != "$ARCH" ]; then
|
|
||||||
aport_na="$aport_na $repo/$aport"
|
|
||||||
return 1
|
|
||||||
fi
|
|
||||||
if ! abuild check_arch 2>/dev/null; then
|
if ! abuild check_arch 2>/dev/null; then
|
||||||
aport_na="$aport_na $repo/$aport"
|
aport_na="$aport_na $repo/$aport"
|
||||||
return 1
|
return 1
|
||||||
|
@ -110,16 +102,13 @@ set_repositories_for() {
|
||||||
|
|
||||||
release=$(get_release)
|
release=$(get_release)
|
||||||
for repo in $REPOS; do
|
for repo in $REPOS; do
|
||||||
|
[ "$repo" = "non-free" ] && continue
|
||||||
|
[ "$release" == "edge" ] && [ "$repo" == "backports" ] && continue
|
||||||
repos="$repos $MIRROR/$release/$repo $REPODEST/$repo"
|
repos="$repos $MIRROR/$release/$repo $REPODEST/$repo"
|
||||||
[ "$repo" = "$target_repo" ] && break
|
[ "$repo" = "$target_repo" ] && break
|
||||||
done
|
done
|
||||||
sudo sh -c "printf '%s\n' $repos >> /etc/apk/repositories"
|
doas sh -c "printf '%s\n' $repos >> /etc/apk/repositories"
|
||||||
sudo apk update || true
|
doas apk update
|
||||||
if [ "$CI_ALPINE_TARGET_ARCH" != "$ARCH" ]; then
|
|
||||||
sudo sh -c "printf '%s\n' $repos >> $HOME/sysroot-$CI_ALPINE_TARGET_ARCH/etc/apk/repositories"
|
|
||||||
sudo cp -R /etc/apk/keys/* $HOME/sysroot-$CI_ALPINE_TARGET_ARCH/etc/apk/keys/.
|
|
||||||
sudo apk --root=$HOME/sysroot-$CI_ALPINE_TARGET_ARCH update || true
|
|
||||||
fi
|
|
||||||
}
|
}
|
||||||
|
|
||||||
apply_offset_limit() {
|
apply_offset_limit() {
|
||||||
|
@ -139,22 +128,10 @@ setup_system() {
|
||||||
[ "$release" != "edge" ] && [ "$repo" == "testing" ] && continue
|
[ "$release" != "edge" ] && [ "$repo" == "testing" ] && continue
|
||||||
repos="$repos $ALPINE_MIRROR/$release/$repo"
|
repos="$repos $ALPINE_MIRROR/$release/$repo"
|
||||||
done
|
done
|
||||||
repos="$repos $MIRROR/$release/cross"
|
doas sh -c "printf '%s\n' $repos > /etc/apk/repositories"
|
||||||
sudo sh -c "printf '%s\n' $repos > /etc/apk/repositories"
|
doas apk -U upgrade -a || apk fix || die "Failed to up/downgrade system"
|
||||||
sudo apk -U upgrade -a || sudo apk fix || die "Failed to up/downgrade system"
|
abuild-keygen -ain
|
||||||
if [ "$CI_ALPINE_TARGET_ARCH" != "$ARCH" ]; then
|
doas sed -i -E 's/export JOBS=[0-9]+$/export JOBS=$(nproc)/' /etc/abuild.conf
|
||||||
sudo apk add gcc-$CI_ALPINE_TARGET_ARCH
|
|
||||||
fi
|
|
||||||
gitlab_key_to_rsa $ABUILD_KEY rsa-private $HOME/.abuild/$ABUILD_KEY_NAME.rsa
|
|
||||||
gitlab_key_to_rsa $ABUILD_KEY_PUB rsa-public $HOME/.abuild/$ABUILD_KEY_NAME.rsa.pub
|
|
||||||
chmod 700 $HOME/.abuild/$ABUILD_KEY_NAME.rsa
|
|
||||||
echo "PACKAGER_PRIVKEY=$HOME/.abuild/$ABUILD_KEY_NAME.rsa" >> $HOME/.abuild/abuild.conf
|
|
||||||
sudo cp $HOME/.abuild/$ABUILD_KEY_NAME.rsa.pub /etc/apk/keys/$ABUILD_KEY_NAME.rsa.pub
|
|
||||||
|
|
||||||
# patch abuild for crosscompiling
|
|
||||||
sudo patch -p1 -d / -i $CI_PROJECT_DIR/.gitlab/patches/abuild-cross.patch
|
|
||||||
|
|
||||||
sudo sed -i -E 's/export JOBS=[0-9]+$/export JOBS=$(nproc)/' /etc/abuild.conf
|
|
||||||
( . /etc/abuild.conf && echo "Building with $JOBS jobs" )
|
( . /etc/abuild.conf && echo "Building with $JOBS jobs" )
|
||||||
mkdir -p "$REPODEST"
|
mkdir -p "$REPODEST"
|
||||||
git config --global init.defaultBranch master
|
git config --global init.defaultBranch master
|
||||||
|
@ -203,7 +180,7 @@ sysinfo || true
|
||||||
setup_system || die "Failed to setup system"
|
setup_system || die "Failed to setup system"
|
||||||
|
|
||||||
# git no longer allows to execute in repositories owned by different users
|
# git no longer allows to execute in repositories owned by different users
|
||||||
sudo chown -R $USER: .
|
doas chown -R buildozer: .
|
||||||
|
|
||||||
fetch_flags="-qn"
|
fetch_flags="-qn"
|
||||||
debugging && fetch_flags="-v"
|
debugging && fetch_flags="-v"
|
||||||
|
@ -226,7 +203,6 @@ build_start=$CI_ALPINE_BUILD_OFFSET
|
||||||
build_limit=$CI_ALPINE_BUILD_LIMIT
|
build_limit=$CI_ALPINE_BUILD_LIMIT
|
||||||
|
|
||||||
for repo in $(changed_repos); do
|
for repo in $(changed_repos); do
|
||||||
mkdir -p "$APORTSDIR"/logs "$APORTSDIR"/packages "$APORTSDIR"/keys
|
|
||||||
set_repositories_for "$repo"
|
set_repositories_for "$repo"
|
||||||
built_aports=0
|
built_aports=0
|
||||||
changed_aports_in_repo=$(changed_aports "$repo")
|
changed_aports_in_repo=$(changed_aports "$repo")
|
||||||
|
@ -267,7 +243,7 @@ for ok in $aport_ok; do
|
||||||
done
|
done
|
||||||
|
|
||||||
for na in $aport_na; do
|
for na in $aport_na; do
|
||||||
msg "$na: disabled for $CI_ALPINE_TARGET_ARCH" yellow
|
msg "$na: disabled for $ARCH" yellow
|
||||||
done
|
done
|
||||||
|
|
||||||
for ng in $aport_ng; do
|
for ng in $aport_ng; do
|
||||||
|
@ -281,3 +257,4 @@ if [ "$failed" = true ]; then
|
||||||
elif [ -z "$aport_ok" ]; then
|
elif [ -z "$aport_ok" ]; then
|
||||||
msg "No packages found to be built." yellow
|
msg "No packages found to be built." yellow
|
||||||
fi
|
fi
|
||||||
|
|
31
.forgejo/bin/check_ver.sh
Executable file
31
.forgejo/bin/check_ver.sh
Executable file
|
@ -0,0 +1,31 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# expects the following env variables:
|
||||||
|
# downstream: downstream repo
|
||||||
|
|
||||||
|
repo=${downstream/*\/}
|
||||||
|
|
||||||
|
curl --silent $downstream/x86_64/APKINDEX.tar.gz | tar -O -zx APKINDEX > APKINDEX
|
||||||
|
|
||||||
|
owned_by_you=$(awk -v RS= -v ORS="\n\n" '/m:Antoine Martin \(ayakael\) <dev@ayakael.net>/' APKINDEX | awk -F ':' '{if($1=="o"){print $2}}' | sort | uniq)
|
||||||
|
|
||||||
|
echo "Found $(printf '%s\n' $owned_by_you | wc -l ) packages owned by you"
|
||||||
|
|
||||||
|
rm -f out_of_date not_in_anitya
|
||||||
|
|
||||||
|
for pkg in $owned_by_you; do
|
||||||
|
upstream_version=$(curl --fail -X GET -sS -H 'Content-Type: application/json' "https://release-monitoring.org/api/v2/packages/?name=$pkg&distribution=Alpine" | jq -r '.items.[].stable_version')
|
||||||
|
downstream_version=$(sed -n "/^P:$pkg$/,/^$/p" APKINDEX | awk -F ':' '{if($1=="V"){print $2}}' | sort -V | tail -n 1)
|
||||||
|
downstream_version=${downstream_version/-*}
|
||||||
|
|
||||||
|
if [ -z "$upstream_version" ]; then
|
||||||
|
echo "$pkg not in anitya"
|
||||||
|
echo "$pkg" >> not_in_anitya
|
||||||
|
elif [ "$downstream_version" != "$(printf '%s\n' $upstream_version $downstream_version | sort -V | head -n 1)" ]; then
|
||||||
|
echo "$pkg higher downstream"
|
||||||
|
continue
|
||||||
|
elif [ "$upstream_version" != "$downstream_version" ]; then
|
||||||
|
echo "$pkg upstream version $upstream_version does not match downstream version $downstream_version"
|
||||||
|
echo "$pkg $downstream_version $upstream_version $repo" >> out_of_date
|
||||||
|
fi
|
||||||
|
done
|
165
.forgejo/bin/create_issue.sh
Executable file
165
.forgejo/bin/create_issue.sh
Executable file
|
@ -0,0 +1,165 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# expects:
|
||||||
|
# env variable FORGEJO_TOKEN
|
||||||
|
# file out_of_date
|
||||||
|
|
||||||
|
IFS='
|
||||||
|
'
|
||||||
|
repo=${downstream/*\/}
|
||||||
|
|
||||||
|
does_it_exist() {
|
||||||
|
name=$1
|
||||||
|
downstream_version=$2
|
||||||
|
upstream_version=$3
|
||||||
|
repo=$4
|
||||||
|
|
||||||
|
query="$repo/$name: upgrade to $upstream_version"
|
||||||
|
query="$(echo $query | sed 's| |%20|g' | sed 's|:|%3A|g' | sed 's|/|%2F|g' )"
|
||||||
|
|
||||||
|
result="$(curl --silent -X 'GET' \
|
||||||
|
"$GITHUB_SERVER_URL/api/v1/repos/$GITHUB_REPOSITORY/issues?state=open&q=$query&type=issues" \
|
||||||
|
-H 'accept: application/json' \
|
||||||
|
-H "authorization: Basic $FORGEJO_TOKEN"
|
||||||
|
)"
|
||||||
|
|
||||||
|
if [ "$result" == "[]" ]; then
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
is_it_old() {
|
||||||
|
name=$1
|
||||||
|
downstream_version=$2
|
||||||
|
upstream_version=$3
|
||||||
|
repo=$4
|
||||||
|
|
||||||
|
query="$repo/$name: upgrade to"
|
||||||
|
query="$(echo $query | sed 's| |%20|g' | sed 's|:|%3A|g' | sed 's|/|%2F|g' )"
|
||||||
|
|
||||||
|
result="$(curl --silent -X 'GET' \
|
||||||
|
"$GITHUB_SERVER_URL/api/v1/repos/$GITHUB_REPOSITORY/issues?state=open&q=$query&type=issues" \
|
||||||
|
-H 'accept: application/json' \
|
||||||
|
-H "authorization: Basic $FORGEJO_TOKEN"
|
||||||
|
)"
|
||||||
|
|
||||||
|
result_title="$(echo $result | jq -r '.[].title' )"
|
||||||
|
result_id="$(echo $result | jq -r '.[].number' )"
|
||||||
|
result_upstream_version="$(echo $result_title | awk '{print $4}')"
|
||||||
|
|
||||||
|
if [ "$upstream_version" != "$result_upstream_version" ]; then
|
||||||
|
echo $result_id
|
||||||
|
else
|
||||||
|
echo 0
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
update_title() {
|
||||||
|
name=$1
|
||||||
|
downstream_version=$2
|
||||||
|
upstream_version=$3
|
||||||
|
repo=$4
|
||||||
|
id=$5
|
||||||
|
|
||||||
|
result=$(curl --silent -X 'PATCH' \
|
||||||
|
"$GITHUB_SERVER_URL/api/v1/repos/$GITHUB_REPOSITORY/issues/$id" \
|
||||||
|
-H 'accept: application/json' \
|
||||||
|
-H "authorization: Basic $FORGEJO_TOKEN" \
|
||||||
|
-H 'Content-Type: application/json' \
|
||||||
|
-d "{
|
||||||
|
\"title\": \"$repo/$name: upgrade to $upstream_version\"
|
||||||
|
}"
|
||||||
|
)
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
create_issue() {
|
||||||
|
name=$1
|
||||||
|
downstream_version=$2
|
||||||
|
upstream_version=$3
|
||||||
|
repo=$4
|
||||||
|
|
||||||
|
result=$(curl --silent -X 'POST' \
|
||||||
|
"$GITHUB_SERVER_URL/api/v1/repos/$GITHUB_REPOSITORY/issues" \
|
||||||
|
-H 'accept: application/json' \
|
||||||
|
-H "authorization: Basic $FORGEJO_TOKEN" \
|
||||||
|
-H 'Content-Type: application/json' \
|
||||||
|
-d "{
|
||||||
|
\"title\": \"$repo/$name: upgrade to $upstream_version\",
|
||||||
|
\"labels\": [
|
||||||
|
$LABEL_NUMBER
|
||||||
|
]
|
||||||
|
}")
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
if [ -f out_of_date ]; then
|
||||||
|
out_of_date="$(cat out_of_date)"
|
||||||
|
|
||||||
|
echo "Detected $(wc -l out_of_date) out-of-date packages, creating issues"
|
||||||
|
|
||||||
|
for pkg in $out_of_date; do
|
||||||
|
name="$(echo $pkg | awk '{print $1}')"
|
||||||
|
downstream_version="$(echo $pkg | awk '{print $2}')"
|
||||||
|
upstream_version="$(echo $pkg | awk '{print $3}')"
|
||||||
|
repo="$(echo $pkg | awk '{print $4}')"
|
||||||
|
|
||||||
|
if does_it_exist $name $downstream_version $upstream_version $repo; then
|
||||||
|
echo "Issue for $repo/$name already exists"
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
|
id=$(is_it_old $name $downstream_version $upstream_version $repo)
|
||||||
|
|
||||||
|
if [ "$id" != "0" ] && [ -n "$id" ]; then
|
||||||
|
echo "Issue for $repo/$name needs updating"
|
||||||
|
update_title $name $downstream_version $upstream_version $repo $id
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "Creating issue for $repo/$name"
|
||||||
|
create_issue $name $downstream_version $upstream_version $repo
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -f not_in_anitya ]; then
|
||||||
|
query="Add missing $repo packages to anitya"
|
||||||
|
query="$(echo $query | sed 's| |%20|g')"
|
||||||
|
|
||||||
|
result="$(curl --silent -X 'GET' \
|
||||||
|
"$GITHUB_SERVER_URL/api/v1/repos/$GITHUB_REPOSITORY/issues?state=open&q=$query&type=issues" \
|
||||||
|
-H 'accept: application/json' \
|
||||||
|
-H "authorization: Basic $FORGEJO_TOKEN"
|
||||||
|
)"
|
||||||
|
|
||||||
|
if [ "$result" == "[]" ]; then
|
||||||
|
echo "Creating anitya issue"
|
||||||
|
result=$(curl --silent -X 'POST' \
|
||||||
|
"$GITHUB_SERVER_URL/api/v1/repos/$GITHUB_REPOSITORY/issues" \
|
||||||
|
-H 'accept: application/json' \
|
||||||
|
-H "authorization: Basic $FORGEJO_TOKEN" \
|
||||||
|
-H 'Content-Type: application/json' \
|
||||||
|
-d "{
|
||||||
|
\"title\": \"Add missing $repo packages to anitya\",
|
||||||
|
\"body\": \"- [ ] $(sed '{:q;N;s/\n/\\n- [ ] /g;t q}' not_in_anitya)\",
|
||||||
|
\"labels\": [
|
||||||
|
$LABEL_NUMBER
|
||||||
|
]
|
||||||
|
}")
|
||||||
|
|
||||||
|
else
|
||||||
|
echo "Updating anitya issue"
|
||||||
|
result_id="$(echo $result | jq -r '.[].number' )"
|
||||||
|
result=$(curl --silent -X 'PATCH' \
|
||||||
|
"$GITHUB_SERVER_URL/api/v1/repos/$GITHUB_REPOSITORY/issues/$result_id" \
|
||||||
|
-H 'accept: application/json' \
|
||||||
|
-H "authorization: Basic $FORGEJO_TOKEN" \
|
||||||
|
-H 'Content-Type: application/json' \
|
||||||
|
-d "{
|
||||||
|
\"body\": \"- [ ] $(sed '{:q;N;s/\n/\\n- [ ] /g;t q}' not_in_anitya)\"
|
||||||
|
}"
|
||||||
|
)
|
||||||
|
fi
|
||||||
|
fi
|
26
.forgejo/bin/deploy.sh
Executable file
26
.forgejo/bin/deploy.sh
Executable file
|
@ -0,0 +1,26 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
# shellcheck disable=SC3040
|
||||||
|
set -eu -o pipefail
|
||||||
|
|
||||||
|
readonly REPOS="backports user"
|
||||||
|
readonly BASEBRANCH=$GITHUB_BASE_REF
|
||||||
|
readonly TARGET_REPO=$CI_ALPINE_REPO
|
||||||
|
|
||||||
|
apkgs=$(find package -type f -name "*.apk")
|
||||||
|
|
||||||
|
for apk in $apkgs; do
|
||||||
|
branch=$(echo $apk | awk -F '/' '{print $2}')
|
||||||
|
arch=$(echo $apk | awk -F '/' '{print $3}')
|
||||||
|
name=$(echo $apk | awk -F '/' '{print $4}')
|
||||||
|
|
||||||
|
echo "Sending $name of arch $arch to $TARGET_REPO/$BASEBRANCH/$branch"
|
||||||
|
return=$(curl -s --user $FORGE_REPO_USER:$FORGE_REPO_TOKEN --upload-file $apk $TARGET_REPO/$BASEBRANCH/$branch 2>&1)
|
||||||
|
echo $return
|
||||||
|
if [ "$return" == "package file already exists" ]; then
|
||||||
|
echo "Package already exists, refreshing..."
|
||||||
|
curl -s --user $FORGE_REPO_USER:$FORGE_REPO_TOKEN -X DELETE $TARGET_REPO/$BASEBRANCH/$branch/$arch/$name
|
||||||
|
curl -s --user $FORGE_REPO_USER:$FORGE_REPO_TOKEN --upload-file $apk $TARGET_REPO/$BASEBRANCH/$branch
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
52
.forgejo/workflows/build-aarch64.yaml
Normal file
52
.forgejo/workflows/build-aarch64.yaml
Normal file
|
@ -0,0 +1,52 @@
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
types: [ assigned, opened, synchronize, reopened ]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-aarch64:
|
||||||
|
runs-on: aarch64
|
||||||
|
container:
|
||||||
|
image: alpinelinux/alpine-gitlab-ci:latest
|
||||||
|
env:
|
||||||
|
CI_PROJECT_DIR: ${{ github.workspace }}
|
||||||
|
CI_DEBUG_BUILD: ${{ runner.debug }}
|
||||||
|
CI_MERGE_REQUEST_PROJECT_URL: ${{ github.server_url }}/${{ github.repository }}
|
||||||
|
CI_MERGE_REQUEST_TARGET_BRANCH_NAME: ${{ github.base_ref }}
|
||||||
|
steps:
|
||||||
|
- name: Environment setup
|
||||||
|
run: |
|
||||||
|
doas apk add nodejs git patch curl
|
||||||
|
cd /etc/apk/keys
|
||||||
|
doas curl -JO https://ayakael.net/api/packages/forge/alpine/key
|
||||||
|
- name: Repo pull
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 500
|
||||||
|
- name: Package build
|
||||||
|
run: |
|
||||||
|
${{ github.workspace }}/.forgejo/bin/build.sh
|
||||||
|
touch packages/dummy
|
||||||
|
- name: Package upload
|
||||||
|
uses: forgejo/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: package
|
||||||
|
path: packages
|
||||||
|
|
||||||
|
deploy-aarch64:
|
||||||
|
needs: [build-aarch64]
|
||||||
|
runs-on: aarch64
|
||||||
|
container:
|
||||||
|
image: alpine:latest
|
||||||
|
env:
|
||||||
|
CI_ALPINE_REPO: 'https://ayakael.net/api/packages/forge/alpine'
|
||||||
|
FORGE_REPO_TOKEN: ${{ secrets.FORGE_REPO_TOKEN }}
|
||||||
|
FORGE_REPO_USER: ${{ vars.FORGE_REPO_USER }}
|
||||||
|
steps:
|
||||||
|
- name: Setting up environment
|
||||||
|
run: apk add nodejs curl findutils git gawk
|
||||||
|
- name: Repo pull
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
- name: Package download
|
||||||
|
uses: forgejo/download-artifact@v3
|
||||||
|
- name: Package deployment
|
||||||
|
run: ${{ github.workspace }}/.forgejo/bin/deploy.sh
|
52
.forgejo/workflows/build-x86_64.yaml
Normal file
52
.forgejo/workflows/build-x86_64.yaml
Normal file
|
@ -0,0 +1,52 @@
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
types: [ assigned, opened, synchronize, reopened ]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-x86_64:
|
||||||
|
runs-on: x86_64
|
||||||
|
container:
|
||||||
|
image: alpinelinux/alpine-gitlab-ci:latest
|
||||||
|
env:
|
||||||
|
CI_PROJECT_DIR: ${{ github.workspace }}
|
||||||
|
CI_DEBUG_BUILD: ${{ runner.debug }}
|
||||||
|
CI_MERGE_REQUEST_PROJECT_URL: ${{ github.server_url }}/${{ github.repository }}
|
||||||
|
CI_MERGE_REQUEST_TARGET_BRANCH_NAME: ${{ github.base_ref }}
|
||||||
|
steps:
|
||||||
|
- name: Environment setup
|
||||||
|
run: |
|
||||||
|
doas apk add nodejs git patch curl
|
||||||
|
cd /etc/apk/keys
|
||||||
|
doas curl -JO https://ayakael.net/api/packages/forge/alpine/key
|
||||||
|
- name: Repo pull
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 500
|
||||||
|
- name: Package build
|
||||||
|
run: |
|
||||||
|
${{ github.workspace }}/.forgejo/bin/build.sh
|
||||||
|
touch packages/dummy
|
||||||
|
- name: Package upload
|
||||||
|
uses: forgejo/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: package
|
||||||
|
path: packages
|
||||||
|
|
||||||
|
deploy-x86_64:
|
||||||
|
needs: [build-x86_64]
|
||||||
|
runs-on: x86_64
|
||||||
|
container:
|
||||||
|
image: alpine:latest
|
||||||
|
env:
|
||||||
|
CI_ALPINE_REPO: 'https://ayakael.net/api/packages/forge/alpine'
|
||||||
|
FORGE_REPO_TOKEN: ${{ secrets.FORGE_REPO_TOKEN }}
|
||||||
|
FORGE_REPO_USER: ${{ vars.FORGE_REPO_USER }}
|
||||||
|
steps:
|
||||||
|
- name: Setting up environment
|
||||||
|
run: apk add nodejs curl findutils git gawk
|
||||||
|
- name: Repo pull
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
- name: Package download
|
||||||
|
uses: forgejo/download-artifact@v3
|
||||||
|
- name: Package deployment
|
||||||
|
run: ${{ github.workspace }}/.forgejo/bin/deploy.sh
|
27
.forgejo/workflows/check-community.yml
Normal file
27
.forgejo/workflows/check-community.yml
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
schedule:
|
||||||
|
- cron: '0 5 * * *'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
check-community:
|
||||||
|
name: Check community repo
|
||||||
|
runs-on: x86_64
|
||||||
|
container:
|
||||||
|
image: alpine:latest
|
||||||
|
env:
|
||||||
|
downstream: https://dl-cdn.alpinelinux.org/alpine/edge/community
|
||||||
|
FORGEJO_TOKEN: ${{ secrets.forgejo_token }}
|
||||||
|
LABEL_NUMBER: 4
|
||||||
|
steps:
|
||||||
|
- name: Environment setup
|
||||||
|
run: apk add grep coreutils gawk curl wget bash nodejs git jq sed
|
||||||
|
- name: Get scripts
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 1
|
||||||
|
- name: Check out-of-date packages
|
||||||
|
run: ${{ github.workspace }}/.forgejo/bin/check_ver.sh
|
||||||
|
- name: Create issues
|
||||||
|
run: ${{ github.workspace }}/.forgejo/bin/create_issue.sh
|
27
.forgejo/workflows/check-testing.yml
Normal file
27
.forgejo/workflows/check-testing.yml
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
schedule:
|
||||||
|
- cron: '0 5 * * *'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
check-community:
|
||||||
|
name: Check testing repo
|
||||||
|
runs-on: x86_64
|
||||||
|
container:
|
||||||
|
image: alpine:latest
|
||||||
|
env:
|
||||||
|
downstream: https://dl-cdn.alpinelinux.org/alpine/edge/testing
|
||||||
|
FORGEJO_TOKEN: ${{ secrets.forgejo_token }}
|
||||||
|
LABEL_NUMBER: 4
|
||||||
|
steps:
|
||||||
|
- name: Environment setup
|
||||||
|
run: apk add grep coreutils gawk curl wget bash nodejs git jq sed
|
||||||
|
- name: Get scripts
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 1
|
||||||
|
- name: Check out-of-date packages
|
||||||
|
run: ${{ github.workspace }}/.forgejo/bin/check_ver.sh
|
||||||
|
- name: Create issues
|
||||||
|
run: ${{ github.workspace }}/.forgejo/bin/create_issue.sh
|
27
.forgejo/workflows/check-user.yml
Normal file
27
.forgejo/workflows/check-user.yml
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
schedule:
|
||||||
|
- cron: '0 5 * * *'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
check-user:
|
||||||
|
name: Check user repo
|
||||||
|
runs-on: x86_64
|
||||||
|
container:
|
||||||
|
image: alpine:latest
|
||||||
|
env:
|
||||||
|
downstream: https://ayakael.net/api/packages/forge/alpine/edge/user
|
||||||
|
FORGEJO_TOKEN: ${{ secrets.forgejo_token }}
|
||||||
|
LABEL_NUMBER: 4
|
||||||
|
steps:
|
||||||
|
- name: Environment setup
|
||||||
|
run: apk add grep coreutils gawk curl wget bash nodejs git jq sed
|
||||||
|
- name: Get scripts
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 1
|
||||||
|
- name: Check out-of-date packages
|
||||||
|
run: ${{ github.workspace }}/.forgejo/bin/check_ver.sh
|
||||||
|
- name: Create issues
|
||||||
|
run: ${{ github.workspace }}/.forgejo/bin/create_issue.sh
|
21
.forgejo/workflows/lint.yaml
Normal file
21
.forgejo/workflows/lint.yaml
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
types: [ assigned, opened, synchronize, reopened ]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
lint:
|
||||||
|
run-name: lint
|
||||||
|
runs-on: x86_64
|
||||||
|
container:
|
||||||
|
image: alpinelinux/apkbuild-lint-tools:latest
|
||||||
|
env:
|
||||||
|
CI_PROJECT_DIR: ${{ github.workspace }}
|
||||||
|
CI_DEBUG_BUILD: ${{ runner.debug }}
|
||||||
|
CI_MERGE_REQUEST_PROJECT_URL: ${{ github.server_url }}/${{ github.repository }}
|
||||||
|
CI_MERGE_REQUEST_TARGET_BRANCH_NAME: ${{ github.base_ref }}
|
||||||
|
steps:
|
||||||
|
- run: doas apk add nodejs git
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 500
|
||||||
|
- run: lint
|
109
.gitlab-ci.yml
109
.gitlab-ci.yml
|
@ -1,109 +0,0 @@
|
||||||
stages:
|
|
||||||
- verify
|
|
||||||
- build
|
|
||||||
- deploy
|
|
||||||
|
|
||||||
variables:
|
|
||||||
GIT_STRATEGY: clone
|
|
||||||
GIT_DEPTH: "500"
|
|
||||||
|
|
||||||
lint:
|
|
||||||
stage: verify
|
|
||||||
interruptible: true
|
|
||||||
script:
|
|
||||||
- |
|
|
||||||
sudo apk add shellcheck atools sudo abuild
|
|
||||||
export PATH="$PATH:$CI_PROJECT_DIR/.gitlab/bin"
|
|
||||||
lint
|
|
||||||
allow_failure: true
|
|
||||||
only:
|
|
||||||
- merge_requests
|
|
||||||
tags:
|
|
||||||
- apk-$CI_MERGE_REQUEST_TARGET_BRANCH_NAME-x86_64
|
|
||||||
|
|
||||||
.build:
|
|
||||||
stage: build
|
|
||||||
interruptible: true
|
|
||||||
script:
|
|
||||||
- |
|
|
||||||
sudo apk add alpine-sdk lua-aports sudo
|
|
||||||
sudo addgroup $USER abuild
|
|
||||||
export PATH="$PATH:$CI_PROJECT_DIR/.gitlab/bin"
|
|
||||||
sudo -Eu $USER build.sh
|
|
||||||
artifacts:
|
|
||||||
paths:
|
|
||||||
- packages/
|
|
||||||
- keys/
|
|
||||||
- logs/
|
|
||||||
expire_in: 7 days
|
|
||||||
when: always
|
|
||||||
only:
|
|
||||||
- merge_requests
|
|
||||||
|
|
||||||
.cross:
|
|
||||||
stage: build
|
|
||||||
interruptible: true
|
|
||||||
script:
|
|
||||||
- |
|
|
||||||
sudo apk add alpine-sdk lua-aports sudo gzip xz qemu-$CI_QEMU_TARGET_ARCH
|
|
||||||
sudo addgroup $USER abuild
|
|
||||||
export PATH="$PATH:$CI_PROJECT_DIR/.gitlab/bin"
|
|
||||||
build-rootfs.sh alpine${CI_MERGE_REQUEST_TARGET_BRANCH_NAME/v} $CI_ALPINE_TARGET_ARCH --rootfsdir $HOME/sysroot-$CI_ALPINE_TARGET_ARCH
|
|
||||||
cp /etc/apk/repositories $HOME/sysroot-$CI_ALPINE_TARGET_ARCH/etc/apk/.
|
|
||||||
sudo -Eu $USER CHOST=$CI_TARGET_ALPINE_ARCH build.sh
|
|
||||||
artifacts:
|
|
||||||
paths:
|
|
||||||
- packages/
|
|
||||||
- keys/
|
|
||||||
- logs/
|
|
||||||
expire_in: 7 days
|
|
||||||
when: always
|
|
||||||
only:
|
|
||||||
- merge_requests
|
|
||||||
|
|
||||||
build-x86_64:
|
|
||||||
extends: .build
|
|
||||||
when: always
|
|
||||||
tags:
|
|
||||||
- apk-$CI_MERGE_REQUEST_TARGET_BRANCH_NAME-x86_64
|
|
||||||
|
|
||||||
build-aarch64:
|
|
||||||
extends: .build
|
|
||||||
when: always
|
|
||||||
tags:
|
|
||||||
- apk-$CI_MERGE_REQUEST_TARGET_BRANCH_NAME-aarch64
|
|
||||||
|
|
||||||
build-ppc64le:
|
|
||||||
extends: .build
|
|
||||||
when: manual
|
|
||||||
tags:
|
|
||||||
- apk-$CI_MERGE_REQUEST_TARGET_BRANCH_NAME-ppc64le
|
|
||||||
|
|
||||||
build-s390x:
|
|
||||||
extends: .build
|
|
||||||
when: manual
|
|
||||||
tags:
|
|
||||||
- apk-$CI_MERGE_REQUEST_TARGET_BRANCH_NAME-s390x
|
|
||||||
|
|
||||||
build-armv7:
|
|
||||||
extends: .cross
|
|
||||||
when: manual
|
|
||||||
tags:
|
|
||||||
- apk-$CI_MERGE_REQUEST_TARGET_BRANCH_NAME-x86_64
|
|
||||||
variables:
|
|
||||||
CI_ALPINE_TARGET_ARCH: armv7
|
|
||||||
CI_QEMU_TARGET_ARCH: arm
|
|
||||||
|
|
||||||
push:
|
|
||||||
interruptible: true
|
|
||||||
stage: deploy
|
|
||||||
script:
|
|
||||||
- |
|
|
||||||
sudo apk add abuild git-lfs findutils
|
|
||||||
export PATH="$PATH:$CI_PROJECT_DIR/.gitlab/bin"
|
|
||||||
push.sh
|
|
||||||
rules:
|
|
||||||
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
|
|
||||||
when: manual
|
|
||||||
tags:
|
|
||||||
- repo
|
|
|
@ -1,111 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
set -e
|
|
||||||
|
|
||||||
arch=
|
|
||||||
builddir=
|
|
||||||
checkdepends=
|
|
||||||
depends=
|
|
||||||
depends_dev=
|
|
||||||
depends_doc=
|
|
||||||
depends_libs=
|
|
||||||
depends_openrc=
|
|
||||||
depends_static=
|
|
||||||
install=
|
|
||||||
install_if=
|
|
||||||
langdir=
|
|
||||||
ldpath=
|
|
||||||
license=
|
|
||||||
makedepends=
|
|
||||||
makedepends_build=
|
|
||||||
makedepends_host=
|
|
||||||
md5sums=
|
|
||||||
options=
|
|
||||||
patch_args=
|
|
||||||
pkgbasedir=
|
|
||||||
pkgdesc=
|
|
||||||
pkgdir=
|
|
||||||
pkgname=
|
|
||||||
pkgrel=
|
|
||||||
pkgver=
|
|
||||||
pkggroups=
|
|
||||||
pkgusers=
|
|
||||||
provides=
|
|
||||||
provider_priority=
|
|
||||||
replaces=
|
|
||||||
sha256sums=
|
|
||||||
sha512sums=
|
|
||||||
sonameprefix=
|
|
||||||
source=
|
|
||||||
srcdir=
|
|
||||||
startdir=
|
|
||||||
subpackages=
|
|
||||||
subpkgdir=
|
|
||||||
subpkgname=
|
|
||||||
triggers=
|
|
||||||
url=
|
|
||||||
|
|
||||||
# abuild.conf
|
|
||||||
|
|
||||||
CFLAGS=
|
|
||||||
CXXFLAGS=
|
|
||||||
CPPFLAGS=
|
|
||||||
LDFLAGS=
|
|
||||||
JOBS=
|
|
||||||
MAKEFLAGS=
|
|
||||||
CMAKE_CROSSOPTS=
|
|
||||||
|
|
||||||
. ./APKBUILD
|
|
||||||
|
|
||||||
: "$arch"
|
|
||||||
: "$builddir"
|
|
||||||
: "$checkdepends"
|
|
||||||
: "$depends"
|
|
||||||
: "$depends_dev"
|
|
||||||
: "$depends_doc"
|
|
||||||
: "$depends_libs"
|
|
||||||
: "$depends_openrc"
|
|
||||||
: "$depends_static"
|
|
||||||
: "$install"
|
|
||||||
: "$install_if"
|
|
||||||
: "$langdir"
|
|
||||||
: "$ldpath"
|
|
||||||
: "$license"
|
|
||||||
: "$makedepends"
|
|
||||||
: "$makedepends_build"
|
|
||||||
: "$makedepends_host"
|
|
||||||
: "$md5sums"
|
|
||||||
: "$options"
|
|
||||||
: "$patch_args"
|
|
||||||
: "$pkgbasedir"
|
|
||||||
: "$pkgdesc"
|
|
||||||
: "$pkgdir"
|
|
||||||
: "$pkgname"
|
|
||||||
: "$pkgrel"
|
|
||||||
: "$pkgver"
|
|
||||||
: "$pkggroups"
|
|
||||||
: "$pkgusers"
|
|
||||||
: "$provides"
|
|
||||||
: "$provider_priority"
|
|
||||||
: "$replaces"
|
|
||||||
: "$sha256sums"
|
|
||||||
: "$sha512sums"
|
|
||||||
: "$sonameprefix"
|
|
||||||
: "$source"
|
|
||||||
: "$srcdir"
|
|
||||||
: "$startdir"
|
|
||||||
: "$subpackages"
|
|
||||||
: "$subpkgdir"
|
|
||||||
: "$subpkgname"
|
|
||||||
: "$triggers"
|
|
||||||
: "$url"
|
|
||||||
|
|
||||||
# abuild.conf
|
|
||||||
|
|
||||||
: "$CFLAGS"
|
|
||||||
: "$CXXFLAGS"
|
|
||||||
: "$CPPFLAGS"
|
|
||||||
: "$LDFLAGS"
|
|
||||||
: "$JOBS"
|
|
||||||
: "$MAKEFLAGS"
|
|
||||||
: "$CMAKE_CROSSOPTS"
|
|
|
@ -1,16 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
shellcheck -s ash \
|
|
||||||
-e SC3043 \
|
|
||||||
-e SC3057 \
|
|
||||||
-e SC3060 \
|
|
||||||
-e SC2016 \
|
|
||||||
-e SC2086 \
|
|
||||||
-e SC2169 \
|
|
||||||
-e SC2155 \
|
|
||||||
-e SC2100 \
|
|
||||||
-e SC2209 \
|
|
||||||
-e SC2030 \
|
|
||||||
-e SC2031 \
|
|
||||||
-e SC1090 \
|
|
||||||
-xa $CI_PROJECT_DIR/.gitlab/bin/APKBUILD_SHIM
|
|
|
@ -1,556 +0,0 @@
|
||||||
#!/usr/bin/env bash
|
|
||||||
# Availabl here: https://lab.ilot.io/dotnet/arcade/-/blob/7f6d9796cc7f594772f798358dbdd8c69b6a97af/eng/common/cross/build-rootfs.sh
|
|
||||||
# Only modification: qemu-$arch-static becomes qemu-$arch
|
|
||||||
|
|
||||||
set -e
|
|
||||||
|
|
||||||
usage()
|
|
||||||
{
|
|
||||||
echo "Usage: $0 [BuildArch] [CodeName] [lldbx.y] [llvmx[.y]] [--skipunmount] --rootfsdir <directory>]"
|
|
||||||
echo "BuildArch can be: arm(default), arm64, armel, armv6, ppc64le, riscv64, s390x, x64, x86"
|
|
||||||
echo "CodeName - optional, Code name for Linux, can be: xenial(default), zesty, bionic, alpine"
|
|
||||||
echo " for alpine can be specified with version: alpineX.YY or alpineedge"
|
|
||||||
echo " for FreeBSD can be: freebsd12, freebsd13"
|
|
||||||
echo " for illumos can be: illumos"
|
|
||||||
echo " for Haiku can be: haiku."
|
|
||||||
echo "lldbx.y - optional, LLDB version, can be: lldb3.9(default), lldb4.0, lldb5.0, lldb6.0 no-lldb. Ignored for alpine and FreeBSD"
|
|
||||||
echo "llvmx[.y] - optional, LLVM version for LLVM related packages."
|
|
||||||
echo "--skipunmount - optional, will skip the unmount of rootfs folder."
|
|
||||||
echo "--use-mirror - optional, use mirror URL to fetch resources, when available."
|
|
||||||
echo "--jobs N - optional, restrict to N jobs."
|
|
||||||
exit 1
|
|
||||||
}
|
|
||||||
|
|
||||||
__CodeName=xenial
|
|
||||||
__CrossDir=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
|
|
||||||
__BuildArch=arm
|
|
||||||
__AlpineArch=armv7
|
|
||||||
__FreeBSDArch=arm
|
|
||||||
__FreeBSDMachineArch=armv7
|
|
||||||
__IllumosArch=arm7
|
|
||||||
__QEMUArch=arm
|
|
||||||
__UbuntuArch=armhf
|
|
||||||
__UbuntuRepo="http://ports.ubuntu.com/"
|
|
||||||
__LLDB_Package="liblldb-3.9-dev"
|
|
||||||
__SkipUnmount=0
|
|
||||||
|
|
||||||
# base development support
|
|
||||||
__UbuntuPackages="build-essential"
|
|
||||||
|
|
||||||
__AlpinePackages="alpine-base"
|
|
||||||
__AlpinePackages+=" build-base"
|
|
||||||
|
|
||||||
# symlinks fixer
|
|
||||||
__UbuntuPackages+=" symlinks"
|
|
||||||
|
|
||||||
# runtime dependencies
|
|
||||||
__UbuntuPackages+=" libicu-dev"
|
|
||||||
__UbuntuPackages+=" liblttng-ust-dev"
|
|
||||||
__UbuntuPackages+=" libunwind8-dev"
|
|
||||||
__UbuntuPackages+=" libnuma-dev"
|
|
||||||
|
|
||||||
# runtime libraries' dependencies
|
|
||||||
__UbuntuPackages+=" libcurl4-openssl-dev"
|
|
||||||
__UbuntuPackages+=" libkrb5-dev"
|
|
||||||
__UbuntuPackages+=" libssl-dev"
|
|
||||||
__UbuntuPackages+=" zlib1g-dev"
|
|
||||||
|
|
||||||
__FreeBSDBase="12.3-RELEASE"
|
|
||||||
__FreeBSDPkg="1.17.0"
|
|
||||||
__FreeBSDABI="12"
|
|
||||||
__FreeBSDPackages="libunwind"
|
|
||||||
__FreeBSDPackages+=" icu"
|
|
||||||
__FreeBSDPackages+=" libinotify"
|
|
||||||
__FreeBSDPackages+=" openssl"
|
|
||||||
__FreeBSDPackages+=" krb5"
|
|
||||||
__FreeBSDPackages+=" terminfo-db"
|
|
||||||
|
|
||||||
__IllumosPackages="icu"
|
|
||||||
__IllumosPackages+=" mit-krb5"
|
|
||||||
__IllumosPackages+=" openssl"
|
|
||||||
__IllumosPackages+=" zlib"
|
|
||||||
|
|
||||||
__HaikuPackages="gmp"
|
|
||||||
__HaikuPackages+=" gmp_devel"
|
|
||||||
__HaikuPackages+=" krb5"
|
|
||||||
__HaikuPackages+=" krb5_devel"
|
|
||||||
__HaikuPackages+=" libiconv"
|
|
||||||
__HaikuPackages+=" libiconv_devel"
|
|
||||||
__HaikuPackages+=" llvm12_libunwind"
|
|
||||||
__HaikuPackages+=" llvm12_libunwind_devel"
|
|
||||||
__HaikuPackages+=" mpfr"
|
|
||||||
__HaikuPackages+=" mpfr_devel"
|
|
||||||
|
|
||||||
# ML.NET dependencies
|
|
||||||
__UbuntuPackages+=" libomp5"
|
|
||||||
__UbuntuPackages+=" libomp-dev"
|
|
||||||
|
|
||||||
__Keyring=
|
|
||||||
__UseMirror=0
|
|
||||||
|
|
||||||
__UnprocessedBuildArgs=
|
|
||||||
while :; do
|
|
||||||
if [[ "$#" -le 0 ]]; then
|
|
||||||
break
|
|
||||||
fi
|
|
||||||
|
|
||||||
lowerI="$(echo "$1" | tr "[:upper:]" "[:lower:]")"
|
|
||||||
case $lowerI in
|
|
||||||
-\?|-h|--help)
|
|
||||||
usage
|
|
||||||
exit 1
|
|
||||||
;;
|
|
||||||
arm)
|
|
||||||
__BuildArch=arm
|
|
||||||
__UbuntuArch=armhf
|
|
||||||
__AlpineArch=armv7
|
|
||||||
__QEMUArch=arm
|
|
||||||
;;
|
|
||||||
arm64)
|
|
||||||
__BuildArch=arm64
|
|
||||||
__UbuntuArch=arm64
|
|
||||||
__AlpineArch=aarch64
|
|
||||||
__QEMUArch=aarch64
|
|
||||||
__FreeBSDArch=arm64
|
|
||||||
__FreeBSDMachineArch=aarch64
|
|
||||||
;;
|
|
||||||
armel)
|
|
||||||
__BuildArch=armel
|
|
||||||
__UbuntuArch=armel
|
|
||||||
__UbuntuRepo="http://ftp.debian.org/debian/"
|
|
||||||
__CodeName=jessie
|
|
||||||
;;
|
|
||||||
armv6)
|
|
||||||
__BuildArch=armv6
|
|
||||||
__UbuntuArch=armhf
|
|
||||||
__QEMUArch=arm
|
|
||||||
__UbuntuRepo="http://raspbian.raspberrypi.org/raspbian/"
|
|
||||||
__CodeName=buster
|
|
||||||
__LLDB_Package="liblldb-6.0-dev"
|
|
||||||
|
|
||||||
if [[ -e "/usr/share/keyrings/raspbian-archive-keyring.gpg" ]]; then
|
|
||||||
__Keyring="--keyring /usr/share/keyrings/raspbian-archive-keyring.gpg"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
riscv64)
|
|
||||||
__BuildArch=riscv64
|
|
||||||
__AlpineArch=riscv64
|
|
||||||
__QEMUArch=riscv64
|
|
||||||
__UbuntuArch=riscv64
|
|
||||||
__UbuntuRepo="http://deb.debian.org/debian-ports"
|
|
||||||
__UbuntuPackages="${__UbuntuPackages// libunwind8-dev/}"
|
|
||||||
unset __LLDB_Package
|
|
||||||
|
|
||||||
if [[ -e "/usr/share/keyrings/debian-ports-archive-keyring.gpg" ]]; then
|
|
||||||
__Keyring="--keyring /usr/share/keyrings/debian-ports-archive-keyring.gpg --include=debian-ports-archive-keyring"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
ppc64le)
|
|
||||||
__BuildArch=ppc64le
|
|
||||||
__AlpineArch=ppc64le
|
|
||||||
__QEMUArch=ppc64le
|
|
||||||
__UbuntuArch=ppc64el
|
|
||||||
__UbuntuRepo="http://ports.ubuntu.com/ubuntu-ports/"
|
|
||||||
__UbuntuPackages="${__UbuntuPackages// libunwind8-dev/}"
|
|
||||||
__UbuntuPackages="${__UbuntuPackages// libomp-dev/}"
|
|
||||||
__UbuntuPackages="${__UbuntuPackages// libomp5/}"
|
|
||||||
unset __LLDB_Package
|
|
||||||
;;
|
|
||||||
s390x)
|
|
||||||
__BuildArch=s390x
|
|
||||||
__AlpineArch=s390x
|
|
||||||
__QEMUArch=s390x
|
|
||||||
__UbuntuArch=s390x
|
|
||||||
__UbuntuRepo="http://ports.ubuntu.com/ubuntu-ports/"
|
|
||||||
__UbuntuPackages="${__UbuntuPackages// libunwind8-dev/}"
|
|
||||||
__UbuntuPackages="${__UbuntuPackages// libomp-dev/}"
|
|
||||||
__UbuntuPackages="${__UbuntuPackages// libomp5/}"
|
|
||||||
unset __LLDB_Package
|
|
||||||
;;
|
|
||||||
x64)
|
|
||||||
__BuildArch=x64
|
|
||||||
__AlpineArch=x86_64
|
|
||||||
__QEMUArch=x86_64
|
|
||||||
__UbuntuArch=amd64
|
|
||||||
__FreeBSDArch=amd64
|
|
||||||
__FreeBSDMachineArch=amd64
|
|
||||||
__illumosArch=x86_64
|
|
||||||
__UbuntuRepo=
|
|
||||||
;;
|
|
||||||
x86)
|
|
||||||
__BuildArch=x86
|
|
||||||
__AlpineArch=i386
|
|
||||||
__QEMUArch=i386
|
|
||||||
__UbuntuArch=i386
|
|
||||||
__AlpineArch=x86
|
|
||||||
__UbuntuRepo="http://archive.ubuntu.com/ubuntu/"
|
|
||||||
;;
|
|
||||||
lldb*)
|
|
||||||
version="${lowerI/lldb/}"
|
|
||||||
parts=(${version//./ })
|
|
||||||
|
|
||||||
# for versions > 6.0, lldb has dropped the minor version
|
|
||||||
if [[ "${parts[0]}" -gt 6 ]]; then
|
|
||||||
version="${parts[0]}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
__LLDB_Package="liblldb-${version}-dev"
|
|
||||||
;;
|
|
||||||
no-lldb)
|
|
||||||
unset __LLDB_Package
|
|
||||||
;;
|
|
||||||
llvm*)
|
|
||||||
version="${lowerI/llvm/}"
|
|
||||||
parts=(${version//./ })
|
|
||||||
__LLVM_MajorVersion="${parts[0]}"
|
|
||||||
__LLVM_MinorVersion="${parts[1]}"
|
|
||||||
|
|
||||||
# for versions > 6.0, llvm has dropped the minor version
|
|
||||||
if [[ -z "$__LLVM_MinorVersion" && "$__LLVM_MajorVersion" -le 6 ]]; then
|
|
||||||
__LLVM_MinorVersion=0;
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
xenial) # Ubuntu 16.04
|
|
||||||
if [[ "$__CodeName" != "jessie" ]]; then
|
|
||||||
__CodeName=xenial
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
zesty) # Ubuntu 17.04
|
|
||||||
if [[ "$__CodeName" != "jessie" ]]; then
|
|
||||||
__CodeName=zesty
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
bionic) # Ubuntu 18.04
|
|
||||||
if [[ "$__CodeName" != "jessie" ]]; then
|
|
||||||
__CodeName=bionic
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
focal) # Ubuntu 20.04
|
|
||||||
if [[ "$__CodeName" != "jessie" ]]; then
|
|
||||||
__CodeName=focal
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
jammy) # Ubuntu 22.04
|
|
||||||
if [[ "$__CodeName" != "jessie" ]]; then
|
|
||||||
__CodeName=jammy
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
jessie) # Debian 8
|
|
||||||
__CodeName=jessie
|
|
||||||
|
|
||||||
if [[ -z "$__UbuntuRepo" ]]; then
|
|
||||||
__UbuntuRepo="http://ftp.debian.org/debian/"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
stretch) # Debian 9
|
|
||||||
__CodeName=stretch
|
|
||||||
__LLDB_Package="liblldb-6.0-dev"
|
|
||||||
|
|
||||||
if [[ -z "$__UbuntuRepo" ]]; then
|
|
||||||
__UbuntuRepo="http://ftp.debian.org/debian/"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
buster) # Debian 10
|
|
||||||
__CodeName=buster
|
|
||||||
__LLDB_Package="liblldb-6.0-dev"
|
|
||||||
|
|
||||||
if [[ -z "$__UbuntuRepo" ]]; then
|
|
||||||
__UbuntuRepo="http://ftp.debian.org/debian/"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
bullseye) # Debian 11
|
|
||||||
__CodeName=bullseye
|
|
||||||
|
|
||||||
if [[ -z "$__UbuntuRepo" ]]; then
|
|
||||||
__UbuntuRepo="http://ftp.debian.org/debian/"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
sid) # Debian sid
|
|
||||||
__CodeName=sid
|
|
||||||
|
|
||||||
if [[ -z "$__UbuntuRepo" ]]; then
|
|
||||||
__UbuntuRepo="http://ftp.debian.org/debian/"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
tizen)
|
|
||||||
__CodeName=
|
|
||||||
__UbuntuRepo=
|
|
||||||
__Tizen=tizen
|
|
||||||
;;
|
|
||||||
alpine*)
|
|
||||||
__CodeName=alpine
|
|
||||||
__UbuntuRepo=
|
|
||||||
version="${lowerI/alpine/}"
|
|
||||||
|
|
||||||
if [[ "$version" == "edge" ]]; then
|
|
||||||
__AlpineVersion=edge
|
|
||||||
else
|
|
||||||
parts=(${version//./ })
|
|
||||||
__AlpineMajorVersion="${parts[0]}"
|
|
||||||
__AlpineMinoVersion="${parts[1]}"
|
|
||||||
__AlpineVersion="$__AlpineMajorVersion.$__AlpineMinoVersion"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
freebsd12)
|
|
||||||
__CodeName=freebsd
|
|
||||||
__SkipUnmount=1
|
|
||||||
;;
|
|
||||||
freebsd13)
|
|
||||||
__CodeName=freebsd
|
|
||||||
__FreeBSDBase="13.0-RELEASE"
|
|
||||||
__FreeBSDABI="13"
|
|
||||||
__SkipUnmount=1
|
|
||||||
;;
|
|
||||||
illumos)
|
|
||||||
__CodeName=illumos
|
|
||||||
__SkipUnmount=1
|
|
||||||
;;
|
|
||||||
haiku)
|
|
||||||
__CodeName=haiku
|
|
||||||
__BuildArch=x64
|
|
||||||
__SkipUnmount=1
|
|
||||||
;;
|
|
||||||
--skipunmount)
|
|
||||||
__SkipUnmount=1
|
|
||||||
;;
|
|
||||||
--rootfsdir|-rootfsdir)
|
|
||||||
shift
|
|
||||||
__RootfsDir="$1"
|
|
||||||
;;
|
|
||||||
--use-mirror)
|
|
||||||
__UseMirror=1
|
|
||||||
;;
|
|
||||||
--use-jobs)
|
|
||||||
shift
|
|
||||||
MAXJOBS=$1
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
__UnprocessedBuildArgs="$__UnprocessedBuildArgs $1"
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
shift
|
|
||||||
done
|
|
||||||
|
|
||||||
if [[ "$__BuildArch" == "armel" ]]; then
|
|
||||||
__LLDB_Package="lldb-3.5-dev"
|
|
||||||
fi
|
|
||||||
|
|
||||||
__UbuntuPackages+=" ${__LLDB_Package:-}"
|
|
||||||
|
|
||||||
if [[ -n "$__LLVM_MajorVersion" ]]; then
|
|
||||||
__UbuntuPackages+=" libclang-common-${__LLVM_MajorVersion}${__LLVM_MinorVersion:+.$__LLVM_MinorVersion}-dev"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ -z "$__RootfsDir" && -n "$ROOTFS_DIR" ]]; then
|
|
||||||
__RootfsDir="$ROOTFS_DIR"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ -z "$__RootfsDir" ]]; then
|
|
||||||
__RootfsDir="$__CrossDir/../../../.tools/rootfs/$__BuildArch"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ -d "$__RootfsDir" ]]; then
|
|
||||||
if [[ "$__SkipUnmount" == "0" ]]; then
|
|
||||||
umount "$__RootfsDir"/* || true
|
|
||||||
fi
|
|
||||||
rm -rf "$__RootfsDir"
|
|
||||||
fi
|
|
||||||
|
|
||||||
mkdir -p "$__RootfsDir"
|
|
||||||
__RootfsDir="$( cd "$__RootfsDir" && pwd )"
|
|
||||||
|
|
||||||
if [[ "$__CodeName" == "alpine" ]]; then
|
|
||||||
__ApkToolsVersion=2.12.11
|
|
||||||
__ApkToolsDir="$(mktemp -d)"
|
|
||||||
|
|
||||||
wget "https://gitlab.alpinelinux.org/api/v4/projects/5/packages/generic//v$__ApkToolsVersion/x86_64/apk.static" -P "$__ApkToolsDir"
|
|
||||||
chmod +x "$__ApkToolsDir/apk.static"
|
|
||||||
|
|
||||||
mkdir -p "$__RootfsDir"/usr/bin
|
|
||||||
cp -v "/usr/bin/qemu-$__QEMUArch" "$__RootfsDir/usr/bin"
|
|
||||||
|
|
||||||
if [[ "$__AlpineVersion" == "edge" ]]; then
|
|
||||||
version=edge
|
|
||||||
else
|
|
||||||
version="v$__AlpineVersion"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# initialize DB
|
|
||||||
"$__ApkToolsDir/apk.static" \
|
|
||||||
-X "http://dl-cdn.alpinelinux.org/alpine/$version/main" \
|
|
||||||
-X "http://dl-cdn.alpinelinux.org/alpine/$version/community" \
|
|
||||||
-U --allow-untrusted --root "$__RootfsDir" --arch "$__AlpineArch" --initdb add
|
|
||||||
|
|
||||||
if [[ "$__AlpineLlvmLibsLookup" == 1 ]]; then
|
|
||||||
__AlpinePackages+=" $("$__ApkToolsDir/apk.static" \
|
|
||||||
-X "http://dl-cdn.alpinelinux.org/alpine/$version/main" \
|
|
||||||
-X "http://dl-cdn.alpinelinux.org/alpine/$version/community" \
|
|
||||||
-U --allow-untrusted --root "$__RootfsDir" --arch "$__AlpineArch" \
|
|
||||||
search 'llvm*-libs' | sort | tail -1 | sed 's/-[^-]*//2g')"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# install all packages in one go
|
|
||||||
"$__ApkToolsDir/apk.static" \
|
|
||||||
-X "http://dl-cdn.alpinelinux.org/alpine/$version/main" \
|
|
||||||
-X "http://dl-cdn.alpinelinux.org/alpine/$version/community" \
|
|
||||||
-U --allow-untrusted --no-scripts --root "$__RootfsDir" --arch "$__AlpineArch" \
|
|
||||||
add $__AlpinePackages
|
|
||||||
|
|
||||||
rm -r "$__ApkToolsDir"
|
|
||||||
elif [[ "$__CodeName" == "freebsd" ]]; then
|
|
||||||
mkdir -p "$__RootfsDir"/usr/local/etc
|
|
||||||
JOBS=${MAXJOBS:="$(getconf _NPROCESSORS_ONLN)"}
|
|
||||||
wget -O - "https://download.freebsd.org/ftp/releases/${__FreeBSDArch}/${__FreeBSDMachineArch}/${__FreeBSDBase}/base.txz" | tar -C "$__RootfsDir" -Jxf - ./lib ./usr/lib ./usr/libdata ./usr/include ./usr/share/keys ./etc ./bin/freebsd-version
|
|
||||||
echo "ABI = \"FreeBSD:${__FreeBSDABI}:${__FreeBSDMachineArch}\"; FINGERPRINTS = \"${__RootfsDir}/usr/share/keys\"; REPOS_DIR = [\"${__RootfsDir}/etc/pkg\"]; REPO_AUTOUPDATE = NO; RUN_SCRIPTS = NO;" > "${__RootfsDir}"/usr/local/etc/pkg.conf
|
|
||||||
echo "FreeBSD: { url: \"pkg+http://pkg.FreeBSD.org/\${ABI}/quarterly\", mirror_type: \"srv\", signature_type: \"fingerprints\", fingerprints: \"${__RootfsDir}/usr/share/keys/pkg\", enabled: yes }" > "${__RootfsDir}"/etc/pkg/FreeBSD.conf
|
|
||||||
mkdir -p "$__RootfsDir"/tmp
|
|
||||||
# get and build package manager
|
|
||||||
wget -O - "https://github.com/freebsd/pkg/archive/${__FreeBSDPkg}.tar.gz" | tar -C "$__RootfsDir"/tmp -zxf -
|
|
||||||
cd "$__RootfsDir/tmp/pkg-${__FreeBSDPkg}"
|
|
||||||
# needed for install to succeed
|
|
||||||
mkdir -p "$__RootfsDir"/host/etc
|
|
||||||
./autogen.sh && ./configure --prefix="$__RootfsDir"/host && make -j "$JOBS" && make install
|
|
||||||
rm -rf "$__RootfsDir/tmp/pkg-${__FreeBSDPkg}"
|
|
||||||
# install packages we need.
|
|
||||||
INSTALL_AS_USER=$(whoami) "$__RootfsDir"/host/sbin/pkg -r "$__RootfsDir" -C "$__RootfsDir"/usr/local/etc/pkg.conf update
|
|
||||||
INSTALL_AS_USER=$(whoami) "$__RootfsDir"/host/sbin/pkg -r "$__RootfsDir" -C "$__RootfsDir"/usr/local/etc/pkg.conf install --yes $__FreeBSDPackages
|
|
||||||
elif [[ "$__CodeName" == "illumos" ]]; then
|
|
||||||
mkdir "$__RootfsDir/tmp"
|
|
||||||
pushd "$__RootfsDir/tmp"
|
|
||||||
JOBS=${MAXJOBS:="$(getconf _NPROCESSORS_ONLN)"}
|
|
||||||
echo "Downloading sysroot."
|
|
||||||
wget -O - https://github.com/illumos/sysroot/releases/download/20181213-de6af22ae73b-v1/illumos-sysroot-i386-20181213-de6af22ae73b-v1.tar.gz | tar -C "$__RootfsDir" -xzf -
|
|
||||||
echo "Building binutils. Please wait.."
|
|
||||||
wget -O - https://ftp.gnu.org/gnu/binutils/binutils-2.33.1.tar.bz2 | tar -xjf -
|
|
||||||
mkdir build-binutils && cd build-binutils
|
|
||||||
../binutils-2.33.1/configure --prefix="$__RootfsDir" --target="${__illumosArch}-sun-solaris2.10" --program-prefix="${__illumosArch}-illumos-" --with-sysroot="$__RootfsDir"
|
|
||||||
make -j "$JOBS" && make install && cd ..
|
|
||||||
echo "Building gcc. Please wait.."
|
|
||||||
wget -O - https://ftp.gnu.org/gnu/gcc/gcc-8.4.0/gcc-8.4.0.tar.xz | tar -xJf -
|
|
||||||
CFLAGS="-fPIC"
|
|
||||||
CXXFLAGS="-fPIC"
|
|
||||||
CXXFLAGS_FOR_TARGET="-fPIC"
|
|
||||||
CFLAGS_FOR_TARGET="-fPIC"
|
|
||||||
export CFLAGS CXXFLAGS CXXFLAGS_FOR_TARGET CFLAGS_FOR_TARGET
|
|
||||||
mkdir build-gcc && cd build-gcc
|
|
||||||
../gcc-8.4.0/configure --prefix="$__RootfsDir" --target="${__illumosArch}-sun-solaris2.10" --program-prefix="${__illumosArch}-illumos-" --with-sysroot="$__RootfsDir" --with-gnu-as \
|
|
||||||
--with-gnu-ld --disable-nls --disable-libgomp --disable-libquadmath --disable-libssp --disable-libvtv --disable-libcilkrts --disable-libada --disable-libsanitizer \
|
|
||||||
--disable-libquadmath-support --disable-shared --enable-tls
|
|
||||||
make -j "$JOBS" && make install && cd ..
|
|
||||||
BaseUrl=https://pkgsrc.smartos.org
|
|
||||||
if [[ "$__UseMirror" == 1 ]]; then
|
|
||||||
BaseUrl=https://pkgsrc.smartos.skylime.net
|
|
||||||
fi
|
|
||||||
BaseUrl="$BaseUrl/packages/SmartOS/trunk/${__illumosArch}/All"
|
|
||||||
echo "Downloading manifest"
|
|
||||||
wget "$BaseUrl"
|
|
||||||
echo "Downloading dependencies."
|
|
||||||
read -ra array <<<"$__IllumosPackages"
|
|
||||||
for package in "${array[@]}"; do
|
|
||||||
echo "Installing '$package'"
|
|
||||||
# find last occurrence of package in listing and extract its name
|
|
||||||
package="$(sed -En '/.*href="('"$package"'-[0-9].*).tgz".*/h;$!d;g;s//\1/p' All)"
|
|
||||||
echo "Resolved name '$package'"
|
|
||||||
wget "$BaseUrl"/"$package".tgz
|
|
||||||
ar -x "$package".tgz
|
|
||||||
tar --skip-old-files -xzf "$package".tmp.tg* -C "$__RootfsDir" 2>/dev/null
|
|
||||||
done
|
|
||||||
echo "Cleaning up temporary files."
|
|
||||||
popd
|
|
||||||
rm -rf "$__RootfsDir"/{tmp,+*}
|
|
||||||
mkdir -p "$__RootfsDir"/usr/include/net
|
|
||||||
mkdir -p "$__RootfsDir"/usr/include/netpacket
|
|
||||||
wget -P "$__RootfsDir"/usr/include/net https://raw.githubusercontent.com/illumos/illumos-gate/master/usr/src/uts/common/io/bpf/net/bpf.h
|
|
||||||
wget -P "$__RootfsDir"/usr/include/net https://raw.githubusercontent.com/illumos/illumos-gate/master/usr/src/uts/common/io/bpf/net/dlt.h
|
|
||||||
wget -P "$__RootfsDir"/usr/include/netpacket https://raw.githubusercontent.com/illumos/illumos-gate/master/usr/src/uts/common/inet/sockmods/netpacket/packet.h
|
|
||||||
wget -P "$__RootfsDir"/usr/include/sys https://raw.githubusercontent.com/illumos/illumos-gate/master/usr/src/uts/common/sys/sdt.h
|
|
||||||
elif [[ "$__CodeName" == "haiku" ]]; then
|
|
||||||
JOBS=${MAXJOBS:="$(getconf _NPROCESSORS_ONLN)"}
|
|
||||||
|
|
||||||
echo "Building Haiku sysroot for x86_64"
|
|
||||||
mkdir -p "$__RootfsDir/tmp"
|
|
||||||
cd "$__RootfsDir/tmp"
|
|
||||||
git clone -b hrev56235 https://review.haiku-os.org/haiku
|
|
||||||
git clone -b btrev43195 https://review.haiku-os.org/buildtools
|
|
||||||
cd "$__RootfsDir/tmp/buildtools" && git checkout 7487388f5110021d400b9f3b88e1a7f310dc066d
|
|
||||||
|
|
||||||
# Fetch some unmerged patches
|
|
||||||
cd "$__RootfsDir/tmp/haiku"
|
|
||||||
## Add development build profile (slimmer than nightly)
|
|
||||||
git fetch origin refs/changes/64/4164/1 && git -c commit.gpgsign=false cherry-pick FETCH_HEAD
|
|
||||||
|
|
||||||
# Build jam
|
|
||||||
cd "$__RootfsDir/tmp/buildtools/jam"
|
|
||||||
make
|
|
||||||
|
|
||||||
# Configure cross tools
|
|
||||||
echo "Building cross-compiler"
|
|
||||||
mkdir -p "$__RootfsDir/generated"
|
|
||||||
cd "$__RootfsDir/generated"
|
|
||||||
"$__RootfsDir/tmp/haiku/configure" -j"$JOBS" --sysroot "$__RootfsDir" --cross-tools-source "$__RootfsDir/tmp/buildtools" --build-cross-tools x86_64
|
|
||||||
|
|
||||||
# Build Haiku packages
|
|
||||||
echo "Building Haiku"
|
|
||||||
echo 'HAIKU_BUILD_PROFILE = "development-raw" ;' > UserProfileConfig
|
|
||||||
"$__RootfsDir/tmp/buildtools/jam/jam0" -j"$JOBS" -q '<build>package' '<repository>Haiku'
|
|
||||||
|
|
||||||
BaseUrl="https://depot.haiku-os.org/__api/v2/pkg/get-pkg"
|
|
||||||
|
|
||||||
# Download additional packages
|
|
||||||
echo "Downloading additional required packages"
|
|
||||||
read -ra array <<<"$__HaikuPackages"
|
|
||||||
for package in "${array[@]}"; do
|
|
||||||
echo "Downloading $package..."
|
|
||||||
# API documented here: https://github.com/haiku/haikudepotserver/blob/master/haikudepotserver-api2/src/main/resources/api2/pkg.yaml#L60
|
|
||||||
# The schema here: https://github.com/haiku/haikudepotserver/blob/master/haikudepotserver-api2/src/main/resources/api2/pkg.yaml#L598
|
|
||||||
hpkgDownloadUrl="$(wget -qO- --post-data='{"name":"'"$package"'","repositorySourceCode":"haikuports_x86_64","versionType":"LATEST","naturalLanguageCode":"en"}' \
|
|
||||||
--header='Content-Type:application/json' "$BaseUrl" | jq -r '.result.versions[].hpkgDownloadURL')"
|
|
||||||
wget -P "$__RootfsDir/generated/download" "$hpkgDownloadUrl"
|
|
||||||
done
|
|
||||||
|
|
||||||
# Setup the sysroot
|
|
||||||
echo "Setting up sysroot and extracting needed packages"
|
|
||||||
mkdir -p "$__RootfsDir/boot/system"
|
|
||||||
for file in "$__RootfsDir/generated/objects/haiku/x86_64/packaging/packages/"*.hpkg; do
|
|
||||||
"$__RootfsDir/generated/objects/linux/x86_64/release/tools/package/package" extract -C "$__RootfsDir/boot/system" "$file"
|
|
||||||
done
|
|
||||||
for file in "$__RootfsDir/generated/download/"*.hpkg; do
|
|
||||||
"$__RootfsDir/generated/objects/linux/x86_64/release/tools/package/package" extract -C "$__RootfsDir/boot/system" "$file"
|
|
||||||
done
|
|
||||||
|
|
||||||
# Cleaning up temporary files
|
|
||||||
echo "Cleaning up temporary files"
|
|
||||||
rm -rf "$__RootfsDir/tmp"
|
|
||||||
for name in "$__RootfsDir/generated/"*; do
|
|
||||||
if [[ "$name" =~ "cross-tools-" ]]; then
|
|
||||||
: # Keep the cross-compiler
|
|
||||||
else
|
|
||||||
rm -rf "$name"
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
elif [[ -n "$__CodeName" ]]; then
|
|
||||||
qemu-debootstrap $__Keyring --arch "$__UbuntuArch" "$__CodeName" "$__RootfsDir" "$__UbuntuRepo"
|
|
||||||
cp "$__CrossDir/$__BuildArch/sources.list.$__CodeName" "$__RootfsDir/etc/apt/sources.list"
|
|
||||||
chroot "$__RootfsDir" apt-get update
|
|
||||||
chroot "$__RootfsDir" apt-get -f -y install
|
|
||||||
chroot "$__RootfsDir" apt-get -y install $__UbuntuPackages
|
|
||||||
chroot "$__RootfsDir" symlinks -cr /usr
|
|
||||||
chroot "$__RootfsDir" apt-get clean
|
|
||||||
|
|
||||||
if [[ "$__SkipUnmount" == "0" ]]; then
|
|
||||||
umount "$__RootfsDir"/* || true
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ "$__BuildArch" == "armel" && "$__CodeName" == "jessie" ]]; then
|
|
||||||
pushd "$__RootfsDir"
|
|
||||||
patch -p1 < "$__CrossDir/$__BuildArch/armel.jessie.patch"
|
|
||||||
popd
|
|
||||||
fi
|
|
||||||
elif [[ "$__Tizen" == "tizen" ]]; then
|
|
||||||
ROOTFS_DIR="$__RootfsDir" "$__CrossDir/tizen-build-rootfs.sh" "$__BuildArch"
|
|
||||||
else
|
|
||||||
echo "Unsupported target platform."
|
|
||||||
usage;
|
|
||||||
exit 1
|
|
||||||
fi
|
|
|
@ -1,20 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
if [ $# -lt 1 ]; then
|
|
||||||
echo "Usage: $0 <basebranch>"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
if ! git rev-parse --is-inside-work-tree >/dev/null 2>&1; then
|
|
||||||
echo "Fatal: not inside a git repository"
|
|
||||||
exit 2
|
|
||||||
fi
|
|
||||||
|
|
||||||
basebranch=$1
|
|
||||||
|
|
||||||
if ! git rev-parse --verify --quiet $basebranch >/dev/null; then
|
|
||||||
# The base branch does not eixst, probably due to a shallow clone
|
|
||||||
git fetch -v $CI_MERGE_REQUEST_PROJECT_URL.git +refs/heads/$basebranch:refs/heads/$basebranch
|
|
||||||
fi
|
|
||||||
|
|
||||||
git --no-pager diff --diff-filter=ACMR --name-only $basebranch...HEAD -- "*/APKBUILD" | xargs -r -n1 dirname
|
|
|
@ -1,74 +0,0 @@
|
||||||
# shellcheck disable=SC3043
|
|
||||||
|
|
||||||
:
|
|
||||||
|
|
||||||
# shellcheck disable=SC3040
|
|
||||||
set -eu -o pipefail
|
|
||||||
|
|
||||||
changed_repos() {
|
|
||||||
: "${APORTSDIR?APORTSDIR missing}"
|
|
||||||
: "${BASEBRANCH?BASEBRANCH missing}"
|
|
||||||
|
|
||||||
cd "$APORTSDIR"
|
|
||||||
for repo in $REPOS; do
|
|
||||||
git diff --diff-filter=ACMR --exit-code "$BASEBRANCH"...HEAD -- "$repo" >/dev/null \
|
|
||||||
|| echo "$repo"
|
|
||||||
done
|
|
||||||
}
|
|
||||||
|
|
||||||
changed_aports() {
|
|
||||||
: "${APORTSDIR?APORTSDIR missing}"
|
|
||||||
: "${BASEBRANCH?BASEBRANCH missing}"
|
|
||||||
|
|
||||||
cd "$APORTSDIR"
|
|
||||||
local repo="$1"
|
|
||||||
local aports
|
|
||||||
|
|
||||||
aports=$(git diff --name-only --diff-filter=ACMR --relative="$repo" \
|
|
||||||
"$BASEBRANCH"...HEAD -- "*/APKBUILD" | xargs -rn1 dirname)
|
|
||||||
|
|
||||||
# shellcheck disable=2086
|
|
||||||
ap builddirs -d "$APORTSDIR/$repo" $aports 2>/dev/null | xargs -rn1 basename
|
|
||||||
}
|
|
||||||
|
|
||||||
section_start() {
|
|
||||||
name=${1?arg 1 name missing}
|
|
||||||
header=${2?arg 2 header missing}
|
|
||||||
collapsed=$2
|
|
||||||
timestamp=$(date +%s)
|
|
||||||
|
|
||||||
options=""
|
|
||||||
case $collapsed in
|
|
||||||
yes|on|collapsed|true) options="[collapsed=true]";;
|
|
||||||
esac
|
|
||||||
|
|
||||||
printf "\e[0Ksection_start:%d:%s%s\r\e[0K%s\n" "$timestamp" "$name" "$options" "$header"
|
|
||||||
}
|
|
||||||
|
|
||||||
section_end() {
|
|
||||||
name=$1
|
|
||||||
timestamp=$(date +%s)
|
|
||||||
|
|
||||||
printf "\e[0Ksection_end:%d:%s\r\e[0K" "$timestamp" "$name"
|
|
||||||
}
|
|
||||||
|
|
||||||
gitlab_key_to_rsa() {
|
|
||||||
KEY=$1
|
|
||||||
TYPE=$2
|
|
||||||
TGT=$3
|
|
||||||
TGT_DIR=${TGT%/*}
|
|
||||||
if [ "$TGT" == "$TGT_DIR" ]; then
|
|
||||||
TGT_DIR="./"
|
|
||||||
fi
|
|
||||||
if [ ! -d "$TGT_DIR" ]; then
|
|
||||||
mkdir -p "$TGT_DIR"
|
|
||||||
fi
|
|
||||||
case $TYPE in
|
|
||||||
rsa-public) local type="PUBLIC";;
|
|
||||||
rsa-private) local type="RSA PRIVATE";;
|
|
||||||
esac
|
|
||||||
echo "-----BEGIN $type KEY-----" > "$TGT"
|
|
||||||
echo $1 | sed 's/.\{64\}/&\
|
|
||||||
/g' >> "$TGT"
|
|
||||||
echo "-----END $type KEY-----" >> "$TGT"
|
|
||||||
}
|
|
|
@ -1,96 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
BLUE="\e[34m"
|
|
||||||
MAGENTA="\e[35m"
|
|
||||||
RESET="\e[0m"
|
|
||||||
|
|
||||||
readonly BASEBRANCH=$CI_MERGE_REQUEST_TARGET_BRANCH_NAME
|
|
||||||
|
|
||||||
verbose() {
|
|
||||||
echo "> " "$@"
|
|
||||||
# shellcheck disable=SC2068
|
|
||||||
$@
|
|
||||||
}
|
|
||||||
|
|
||||||
debugging() {
|
|
||||||
[ -n "$CI_DEBUG_BUILD" ]
|
|
||||||
}
|
|
||||||
|
|
||||||
debug() {
|
|
||||||
if debugging; then
|
|
||||||
verbose "$@"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
# git no longer allows to execute in repositories owned by different users
|
|
||||||
sudo chown -R gitlab-runner: .
|
|
||||||
|
|
||||||
fetch_flags="-qn"
|
|
||||||
debugging && fetch_flags="-v"
|
|
||||||
|
|
||||||
git fetch $fetch_flags "$CI_MERGE_REQUEST_PROJECT_URL" \
|
|
||||||
"+refs/heads/$BASEBRANCH:refs/heads/$BASEBRANCH"
|
|
||||||
|
|
||||||
if debugging; then
|
|
||||||
merge_base=$(git merge-base "$BASEBRANCH" HEAD)
|
|
||||||
echo "$merge_base"
|
|
||||||
git --version
|
|
||||||
git config -l
|
|
||||||
git tag merge-base "$merge_base" || { echo "Could not determine merge-base"; exit 50; }
|
|
||||||
git log --oneline --graph --decorate --all
|
|
||||||
fi
|
|
||||||
|
|
||||||
has_problems=0
|
|
||||||
|
|
||||||
for PKG in $(changed-aports "$BASEBRANCH"); do
|
|
||||||
printf "$BLUE==>$RESET Linting $PKG\n"
|
|
||||||
|
|
||||||
(
|
|
||||||
cd "$PKG"
|
|
||||||
|
|
||||||
repo=$(basename $(dirname $PKG));
|
|
||||||
|
|
||||||
if [ "$repo" == "backports" ]; then
|
|
||||||
echo "Skipping $PKG as backports (we don't care)"
|
|
||||||
continue
|
|
||||||
fi
|
|
||||||
|
|
||||||
printf "\n\n"
|
|
||||||
printf "$BLUE"
|
|
||||||
printf '======================================================\n'
|
|
||||||
printf " parse APKBUILD:\n"
|
|
||||||
printf '======================================================'
|
|
||||||
printf "$RESET\n\n"
|
|
||||||
( . ./APKBUILD ) || has_problems=1
|
|
||||||
|
|
||||||
printf "\n\n"
|
|
||||||
printf "$BLUE"
|
|
||||||
printf '======================================================\n'
|
|
||||||
printf " abuild sanitycheck:\n"
|
|
||||||
printf '======================================================'
|
|
||||||
printf "$RESET\n\n"
|
|
||||||
abuild sanitycheck || has_problems=1
|
|
||||||
|
|
||||||
printf "\n\n"
|
|
||||||
printf "$BLUE"
|
|
||||||
printf '======================================================\n'
|
|
||||||
printf " apkbuild-shellcheck:\n"
|
|
||||||
printf '======================================================'
|
|
||||||
printf "$RESET\n"
|
|
||||||
apkbuild-shellcheck || has_problems=1
|
|
||||||
|
|
||||||
printf "\n\n"
|
|
||||||
printf "$BLUE"
|
|
||||||
printf '======================================================\n'
|
|
||||||
printf " apkbuild-lint:\n"
|
|
||||||
printf '======================================================'
|
|
||||||
printf "$RESET\n\n"
|
|
||||||
apkbuild-lint APKBUILD || has_problems=1
|
|
||||||
|
|
||||||
return $has_problems
|
|
||||||
) || has_problems=1
|
|
||||||
|
|
||||||
echo
|
|
||||||
done
|
|
||||||
|
|
||||||
exit $has_problems
|
|
|
@ -1,56 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
# shellcheck disable=SC3043
|
|
||||||
|
|
||||||
. $CI_PROJECT_DIR/.gitlab/bin/functions.sh
|
|
||||||
|
|
||||||
# shellcheck disable=SC3040
|
|
||||||
set -eu -o pipefail
|
|
||||||
|
|
||||||
readonly APORTSDIR=$CI_PROJECT_DIR
|
|
||||||
readonly REPOS="backports user"
|
|
||||||
readonly BASEBRANCH=$CI_MERGE_REQUEST_TARGET_BRANCH_NAME
|
|
||||||
|
|
||||||
export GIT_SSH_COMMAND="ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no"
|
|
||||||
|
|
||||||
gitlab_key_to_rsa $ABUILD_KEY rsa-private $HOME/.abuild/$ABUILD_KEY_NAME.rsa
|
|
||||||
gitlab_key_to_rsa $ABUILD_KEY_PUB rsa-public $HOME/.abuild/$ABUILD_KEY_NAME.rsa.pub
|
|
||||||
gitlab_key_to_rsa $SSH_KEY rsa-private $HOME/.ssh/id_rsa
|
|
||||||
chmod 700 "$HOME"/.ssh/id_rsa
|
|
||||||
chmod 700 "$HOME"/.abuild/$ABUILD_KEY_NAME.rsa
|
|
||||||
|
|
||||||
echo "PACKAGER_PRIVKEY=$HOME/.abuild/$ABUILD_KEY_NAME.rsa" > $HOME/.abuild/abuild.conf
|
|
||||||
echo "REPODEST=$HOME/repo-apk" >> $HOME/.abuild/abuild.conf
|
|
||||||
sudo cp $HOME/.abuild/$ABUILD_KEY_NAME.rsa.pub /etc/apk/keys/.
|
|
||||||
|
|
||||||
if [ -d $HOME/repo-apk ]; then
|
|
||||||
git -C $HOME/repo-apk fetch
|
|
||||||
git -C $HOME/repo-apk checkout $BASEBRANCH
|
|
||||||
git -C $HOME/repo-apk pull --rebase
|
|
||||||
else
|
|
||||||
git clone git@lab.ilot.io:ayakael/repo-apk -b $BASEBRANCH $HOME/repo-apk
|
|
||||||
fi
|
|
||||||
|
|
||||||
for i in $(find packages -type f -name "*.apk"); do
|
|
||||||
install -vDm644 $i ${i/packages/$HOME\/repo-apk}
|
|
||||||
done
|
|
||||||
|
|
||||||
fetch_flags="-qn"
|
|
||||||
git fetch $fetch_flags "$CI_MERGE_REQUEST_PROJECT_URL" \
|
|
||||||
"+refs/heads/$BASEBRANCH:refs/heads/$BASEBRANCH"
|
|
||||||
|
|
||||||
for repo in $(changed_repos); do
|
|
||||||
rm $HOME/repo-apk/$repo/*/APKINDEX.tar.gz | true
|
|
||||||
mkdir -p $repo/DUMMY
|
|
||||||
echo "pkgname=DUMMY" > $repo/DUMMY/APKBUILD
|
|
||||||
cd $repo/DUMMY
|
|
||||||
for i in $(find $HOME/repo-apk/$repo -maxdepth 1 -mindepth 1 -printf '%P '); do
|
|
||||||
CHOST=$i abuild index
|
|
||||||
done
|
|
||||||
cd "$CI_PROJECT_DIR"
|
|
||||||
rm -R $repo/DUMMY
|
|
||||||
done
|
|
||||||
|
|
||||||
git -C $HOME/repo-apk add .
|
|
||||||
git -C $HOME/repo-apk commit -m "Update from $CI_MERGE_REQUEST_IID - $CI_MERGE_REQUEST_TITLE"
|
|
||||||
git -C $HOME/repo-apk push
|
|
|
@ -1,17 +0,0 @@
|
||||||
diff --git a/usr/bin/abuild.orig b/usr/bin/abuild
|
|
||||||
index 71e0681..d4ae3dd 100755
|
|
||||||
--- a/usr/bin/abuild.orig
|
|
||||||
+++ b/usr/bin/abuild
|
|
||||||
@@ -2231,7 +2231,11 @@ calcdeps() {
|
|
||||||
list_has $i $builddeps && continue
|
|
||||||
subpackages_has ${i%%[<>=]*} || builddeps="$builddeps $i"
|
|
||||||
done
|
|
||||||
- hostdeps="$EXTRADEPENDS_TARGET"
|
|
||||||
+ for i in $EXTRADEPENDS_HOST $EXTRADEPENDS_TARGET $depends $makedepends; do
|
|
||||||
+ [ "$pkgname" = "${i%%[<>=]*}" ] && continue
|
|
||||||
+ list_has $i $hostdeps && continue
|
|
||||||
+ subpackages_has ${i%%[<>=]*} || hostdeps="$hostdeps $i"
|
|
||||||
+ done
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
25
README.md
25
README.md
|
@ -1,32 +1,31 @@
|
||||||
# user-aports
|
# ayaports
|
||||||
Upstream: https://lab.ilot.io/ayakael/user-aports
|
Upstream: https://ayakael.net/forge/ayaports
|
||||||
|
|
||||||
## Description
|
## Description
|
||||||
|
|
||||||
This repository contains aports that are not yet merged in the official Alpine
|
This repository contains aports that are not yet merged in the official Alpine
|
||||||
Linux repository or don’t adhere to Alpine polices. Packages are automatically
|
Linux repository or don’t adhere to Alpine polices. Packages are automatically
|
||||||
built using GitLab CI on my own GitLab instance. Once built, they are deployed
|
built using CI. Once built, they are deployed to a git-lfs repository, making
|
||||||
to a git-lfs repository, making them available to apk.
|
them available to apk.
|
||||||
|
|
||||||
Branches are matched to Alpine releases.
|
Branches are matched to Alpine releases.
|
||||||
|
|
||||||
|
|
||||||
## Repositories
|
## Repositories
|
||||||
|
|
||||||
You can browse all the repositories at https://lab.ilot.io/ayakael/repo-apk.
|
You can browse all the repositories at https://codeberg.org/ayakael/ayaports
|
||||||
Affixed to each repository description is the appropriate link for use in
|
Affixed to each repository description is the appropriate link for use in
|
||||||
`/etc/apk/repositories`.
|
`/etc/apk/repositories`.
|
||||||
|
|
||||||
#### Backports
|
#### Backports
|
||||||
```
|
```
|
||||||
https://lab.ilot.io/ayakael/repo-apk/-/raw/edge/backports
|
https://ayakael.net/api/packages/forge/alpine/edge/backports
|
||||||
```
|
```
|
||||||
|
|
||||||
Aports from the official Alpine repositories backported from edge.
|
Aports from the official Alpine repositories backported from edge.
|
||||||
|
|
||||||
#### User
|
#### User
|
||||||
```
|
```
|
||||||
https://lab.ilot.io/ayakael/repo-apk/-/raw/edge/user
|
https://ayakael.net/api/packages/forge/alpine/edge/user
|
||||||
```
|
```
|
||||||
|
|
||||||
Aports that have yet to be (or may never be) upstreamed to the official
|
Aports that have yet to be (or may never be) upstreamed to the official
|
||||||
|
@ -34,11 +33,11 @@ aports.
|
||||||
|
|
||||||
|
|
||||||
## How to use
|
## How to use
|
||||||
Add security key of the repo-apk repository to your /etc/apk/keys:
|
Add security key of the apk repository to your /etc/apk/keys:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
cd /etc/apk/keys
|
cd /etc/apk/keys
|
||||||
wget https://lab.ilot.io/ayakael/repo-apk/-/raw/edge/antoine.martin@protonmail.com-5b3109ad.rsa.pub
|
curl -JO https://ayakael.net/api/packages/forge/alpine/key
|
||||||
```
|
```
|
||||||
Add repositories that you want to use (see above) to `/etc/apk/repositories`.
|
Add repositories that you want to use (see above) to `/etc/apk/repositories`.
|
||||||
|
|
||||||
|
@ -52,10 +51,10 @@ they will work for you.
|
||||||
|
|
||||||
## Contribution & bug reports
|
## Contribution & bug reports
|
||||||
If you wish to contribute to this aports collection, or wish to report a bug,
|
If you wish to contribute to this aports collection, or wish to report a bug,
|
||||||
you can do so on Alpine's GitLab instance here:
|
you can do so on Codeberg here:
|
||||||
https://gitlab.alpinelinux.org/ayakael/user-aports
|
https://codeberg.org/ayakael/ayaports/issues
|
||||||
|
|
||||||
For packages that are in testing/community, bug reports and merge requests
|
For packages that are in backports, bug reports and merge requests
|
||||||
should be done on Alpine's aports repo instance:
|
should be done on Alpine's aports repo instance:
|
||||||
https://gitlab.alpinelinux.org/alpine/aports
|
https://gitlab.alpinelinux.org/alpine/aports
|
||||||
|
|
||||||
|
|
25
backports/calibre/0001-calibre-no-update.patch
Normal file
25
backports/calibre/0001-calibre-no-update.patch
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
diff --color -Nur calibre-6.17.0.orig/src/calibre/gui2/update.py calibre-6.17.0/src/calibre/gui2/update.py
|
||||||
|
--- calibre-6.17.0.orig/src/calibre/gui2/update.py 2023-05-06 11:36:35.678461036 -0700
|
||||||
|
+++ calibre-6.17.0/src/calibre/gui2/update.py 2023-05-06 11:39:10.365134930 -0700
|
||||||
|
@@ -82,20 +82,6 @@
|
||||||
|
while not self.shutdown_event.is_set():
|
||||||
|
calibre_update_version = NO_CALIBRE_UPDATE
|
||||||
|
plugins_update_found = 0
|
||||||
|
- try:
|
||||||
|
- version = get_newest_version()
|
||||||
|
- if version[:2] > numeric_version[:2]:
|
||||||
|
- calibre_update_version = version
|
||||||
|
- except Exception as e:
|
||||||
|
- prints('Failed to check for calibre update:', as_unicode(e))
|
||||||
|
- try:
|
||||||
|
- update_plugins = get_plugin_updates_available(raise_error=True)
|
||||||
|
- if update_plugins is not None:
|
||||||
|
- plugins_update_found = len(update_plugins)
|
||||||
|
- except Exception as e:
|
||||||
|
- prints('Failed to check for plugin update:', as_unicode(e))
|
||||||
|
- if calibre_update_version != NO_CALIBRE_UPDATE or plugins_update_found > 0:
|
||||||
|
- self.signal.update_found.emit(calibre_update_version, plugins_update_found)
|
||||||
|
self.shutdown_event.wait(self.INTERVAL)
|
||||||
|
|
||||||
|
def shutdown(self):
|
||||||
|
|
116
backports/calibre/APKBUILD
Normal file
116
backports/calibre/APKBUILD
Normal file
|
@ -0,0 +1,116 @@
|
||||||
|
# Maintainer: Cowington Post <cowingtonpost@gmail.com>
|
||||||
|
pkgname=calibre
|
||||||
|
pkgver=7.12.0
|
||||||
|
pkgrel=0
|
||||||
|
pkgdesc="Ebook management application"
|
||||||
|
# qt6-webengine
|
||||||
|
arch="x86_64 aarch64"
|
||||||
|
url="https://calibre-ebook.com"
|
||||||
|
license="GPL-3.0-or-later"
|
||||||
|
depends="
|
||||||
|
font-liberation
|
||||||
|
libwmf
|
||||||
|
mtdev
|
||||||
|
optipng
|
||||||
|
poppler
|
||||||
|
py3-apsw
|
||||||
|
py3-beautifulsoup4
|
||||||
|
py3-css-parser
|
||||||
|
py3-cssselect
|
||||||
|
py3-dateutil
|
||||||
|
py3-dnspython
|
||||||
|
py3-feedparser
|
||||||
|
py3-fonttools
|
||||||
|
py3-html2text
|
||||||
|
py3-html5-parser
|
||||||
|
py3-html5lib
|
||||||
|
py3-jeepney
|
||||||
|
py3-lxml
|
||||||
|
py3-markdown
|
||||||
|
py3-mechanize
|
||||||
|
py3-msgpack
|
||||||
|
py3-netifaces
|
||||||
|
py3-pillow
|
||||||
|
py3-psutil
|
||||||
|
py3-pycryptodome
|
||||||
|
py3-pygments
|
||||||
|
py3-pyqt6-webengine
|
||||||
|
py3-regex
|
||||||
|
py3-xxhash
|
||||||
|
py3-zeroconf
|
||||||
|
qt6-qtimageformats
|
||||||
|
qt6-qtsvg
|
||||||
|
qt6-qtwebengine
|
||||||
|
udisks2
|
||||||
|
"
|
||||||
|
makedepends="
|
||||||
|
cmake
|
||||||
|
curl
|
||||||
|
hunspell-dev
|
||||||
|
hyphen-dev
|
||||||
|
libmtp-dev
|
||||||
|
libstemmer-dev
|
||||||
|
libusb-dev
|
||||||
|
podofo-dev
|
||||||
|
py3-pyqt-builder
|
||||||
|
py3-pyqt6-sip
|
||||||
|
py3-sip
|
||||||
|
python3-dev
|
||||||
|
qt6-qtbase-dev
|
||||||
|
uchardet-dev
|
||||||
|
xdg-utils
|
||||||
|
"
|
||||||
|
subpackages="
|
||||||
|
$pkgname-pyc
|
||||||
|
$pkgname-doc
|
||||||
|
$pkgname-bash-completion
|
||||||
|
$pkgname-zsh-completion
|
||||||
|
"
|
||||||
|
source="https://download.calibre-ebook.com/$pkgver/calibre-$pkgver.tar.xz
|
||||||
|
0001-$pkgname-no-update.patch
|
||||||
|
"
|
||||||
|
# net: downloads iso-codes
|
||||||
|
# !check: no tests ran
|
||||||
|
options="net !check"
|
||||||
|
|
||||||
|
export LANG="en_US.UTF-8"
|
||||||
|
|
||||||
|
prepare() {
|
||||||
|
default_prepare
|
||||||
|
|
||||||
|
rm -f resources/calibre-portable.*
|
||||||
|
}
|
||||||
|
|
||||||
|
build() {
|
||||||
|
python3 setup.py build
|
||||||
|
python3 setup.py iso639
|
||||||
|
python3 setup.py iso3166
|
||||||
|
python3 setup.py liberation_fonts --system-liberation_fonts --path-to-liberation_fonts /usr/share/fonts/liberation
|
||||||
|
python3 setup.py mathjax
|
||||||
|
python3 setup.py gui
|
||||||
|
}
|
||||||
|
|
||||||
|
check() {
|
||||||
|
python3 -m unittest discover
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
# needed for zsh
|
||||||
|
mkdir -p "$pkgdir"/usr/share/zsh/site-functions
|
||||||
|
|
||||||
|
python3 setup.py install \
|
||||||
|
--staging-root="$pkgdir"/usr \
|
||||||
|
--no-compile \
|
||||||
|
--system-plugins-location=/usr/share/calibre/system-plugins
|
||||||
|
|
||||||
|
cp -a man-pages/ "$pkgdir"/usr/share/man
|
||||||
|
|
||||||
|
rm -r "$pkgdir"/usr/share/calibre/rapydscript/
|
||||||
|
|
||||||
|
python3 -m compileall -fq "$pkgdir"/usr
|
||||||
|
}
|
||||||
|
|
||||||
|
sha512sums="
|
||||||
|
ee654260d7047f0579a659b8907439a407fb561affcef84141126840452e7b98d10bb5e0a69e0cc809d9ba68729570900a0e7251f18b2056a94b0213880f1363 calibre-7.12.0.tar.xz
|
||||||
|
eb8e7ce40ff8b8daf6e7e55a5dff8ec4dff06c45744266bb48b3194e92ab1196bc91468203e3c2ca1e5144166a7d6be90e6cf0253513e761b56a4c85be4c2c76 0001-calibre-no-update.patch
|
||||||
|
"
|
|
@ -1,20 +1,19 @@
|
||||||
# Maintainer: Antoine Martin (ayakael) <dev@ayakael.net>
|
|
||||||
# Contributor: Antoine Martin (ayakael) <dev@ayakael.net>
|
# Contributor: Antoine Martin (ayakael) <dev@ayakael.net>
|
||||||
|
# Maintainer: Antoine Martin (ayakael) <dev@ayakael.net>
|
||||||
pkgname=caprine
|
pkgname=caprine
|
||||||
pkgver=2.59.1
|
pkgver=2.60.1
|
||||||
pkgrel=0
|
pkgrel=1
|
||||||
pkgdesc="Elegant Facebook Messenger desktop app"
|
pkgdesc="Elegant Facebook Messenger desktop app"
|
||||||
arch="x86_64 aarch64" # bloced by electron
|
arch="x86_64 aarch64" # blocked by electron
|
||||||
url="https://github.com/sindresorhus/caprine"
|
url="https://github.com/sindresorhus/caprine"
|
||||||
license="MIT"
|
license="MIT"
|
||||||
depends="electron"
|
depends="electron"
|
||||||
makedepends="npm findutils coreutils"
|
makedepends="npm findutils coreutils"
|
||||||
options="!check"
|
options="!check" # No test suite
|
||||||
source="
|
source="
|
||||||
$pkgname-$pkgver.tar.gz::https://github.com/sindresorhus/caprine/archive/refs/tags/v$pkgver.tar.gz
|
$pkgname-$pkgver.tar.gz::https://github.com/sindresorhus/caprine/archive/refs/tags/v$pkgver.tar.gz
|
||||||
caprine.desktop
|
caprine.desktop
|
||||||
caprine.js
|
caprine.sh
|
||||||
"
|
"
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
|
@ -27,7 +26,7 @@ build() {
|
||||||
}
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
local appdir=/usr/lib/$pkgname
|
local appdir=/usr/lib/caprine
|
||||||
|
|
||||||
install -d "$pkgdir"$appdir
|
install -d "$pkgdir"$appdir
|
||||||
cp -r ./* "$pkgdir"$appdir
|
cp -r ./* "$pkgdir"$appdir
|
||||||
|
@ -35,13 +34,13 @@ package() {
|
||||||
install -dm755 "$pkgdir/usr/share/pixmaps"
|
install -dm755 "$pkgdir/usr/share/pixmaps"
|
||||||
install -m644 build/icon.png "$pkgdir/usr/share/pixmaps/$pkgname.png"
|
install -m644 build/icon.png "$pkgdir/usr/share/pixmaps/$pkgname.png"
|
||||||
|
|
||||||
install -Dm755 "$srcdir"/$pkgname.js "$pkgdir"/usr/bin/$pkgname
|
install -Dm755 "$srcdir"/caprine.sh "$pkgdir"/usr/bin/caprine
|
||||||
install -Dm644 "$srcdir"/$pkgname.desktop \
|
install -Dm644 "$srcdir"/caprine.desktop \
|
||||||
"$pkgdir"/usr/share/applications/$pkgname.desktop
|
"$pkgdir"/usr/share/applications/caprine.desktop
|
||||||
|
|
||||||
install -dm755 "$pkgdir"/usr/share/licenses/$pkgname
|
install -dm755 "$pkgdir"/usr/share/licenses/caprine
|
||||||
ln -s "$(realpath -m --relative-to=/usr/share/licenses/$pkgname $appdir/license)" \
|
ln -s "$(realpath -m --relative-to=/usr/share/licenses/caprine $appdir/license)" \
|
||||||
"$pkgdir"/usr/share/licenses/$pkgname
|
"$pkgdir"/usr/share/licenses/caprine
|
||||||
|
|
||||||
# Clean up
|
# Clean up
|
||||||
rm -r "$pkgdir"$appdir/build
|
rm -r "$pkgdir"$appdir/build
|
||||||
|
@ -49,7 +48,7 @@ package() {
|
||||||
rm -r "$pkgdir"$appdir/tsconfig.json
|
rm -r "$pkgdir"$appdir/tsconfig.json
|
||||||
find "$pkgdir"$appdir \
|
find "$pkgdir"$appdir \
|
||||||
-name "package.json" \
|
-name "package.json" \
|
||||||
-exec sed -e "s|$srcdir/$pkgname|$appdir|" \
|
-exec sed -e "s|$srcdir/caprine|$appdir|" \
|
||||||
-i {} \; \
|
-i {} \; \
|
||||||
-or -name ".*" -prune -exec rm -r '{}' \; \
|
-or -name ".*" -prune -exec rm -r '{}' \; \
|
||||||
-or -name "bin" -prune -exec rm -r '{}' \; \
|
-or -name "bin" -prune -exec rm -r '{}' \; \
|
||||||
|
@ -60,7 +59,7 @@ package() {
|
||||||
-or -name "test" -prune -exec rm -r '{}' \;
|
-or -name "test" -prune -exec rm -r '{}' \;
|
||||||
}
|
}
|
||||||
sha512sums="
|
sha512sums="
|
||||||
a525bafb6a53dd2dbdfc4b9b3e96d3939d93be950a3287f2a5ef6465d5a6b64ecda79b6d393023d067f939e1a6e85debc35f83bbb1f758011db9d94dd9ff8a72 caprine-2.59.1.tar.gz
|
0df7f233c91f5a044dcffde94b976c6ad71e6d355518615c48cd825a249c01d63f455de31ece69193a66ca0fd8157506f9b88088da1bd47fc75e9d3800784ed0 caprine-2.60.1.tar.gz
|
||||||
a469e3bea24926119e51642b777ef794c5fa65421107903f967c36d81bbb1adb3d52469ce3a3301b2c890f1aa53ab989ded22a7c6e811fb8cf0a582dbd835e19 caprine.desktop
|
a469e3bea24926119e51642b777ef794c5fa65421107903f967c36d81bbb1adb3d52469ce3a3301b2c890f1aa53ab989ded22a7c6e811fb8cf0a582dbd835e19 caprine.desktop
|
||||||
44280c62ce43bdafa8528729371fccb16b8a0e3db7aca28d5c157ae0144dca5fbb023b8883b561955aa28ab62e967f2674d8c6bcaff186e2cdd0e7ba8beab9ac caprine.js
|
3ad8994c1a0417e73d622587769e527b4236a32c1a89442ff76413b75b4392d667c9e2908979b453e5926e54db6d94b31625340c5a94e84e91ea77f56feae778 caprine.sh
|
||||||
"
|
"
|
2
backports/caprine/caprine.sh
Normal file
2
backports/caprine/caprine.sh
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
#!/bin/sh
|
||||||
|
/usr/bin/electron "/usr/lib/caprine"
|
|
@ -2,7 +2,7 @@
|
||||||
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
||||||
pkgname=coin
|
pkgname=coin
|
||||||
pkgver=4.0.0
|
pkgver=4.0.0
|
||||||
pkgrel=5
|
pkgrel=6
|
||||||
pkgdesc="OpenGL OpenInventor compatible graphics library"
|
pkgdesc="OpenGL OpenInventor compatible graphics library"
|
||||||
url="https://github.com/coin3d/coin"
|
url="https://github.com/coin3d/coin"
|
||||||
license="BSD-3-Clause"
|
license="BSD-3-Clause"
|
||||||
|
|
|
@ -4,7 +4,7 @@ pkgname=cura
|
||||||
# uranium and curaengine packages must be updated in sync with this verion number
|
# uranium and curaengine packages must be updated in sync with this verion number
|
||||||
# py3-pynest2d and fdm-materials should be checked as well, but their versions are not always in sync
|
# py3-pynest2d and fdm-materials should be checked as well, but their versions are not always in sync
|
||||||
pkgver=5.2.2
|
pkgver=5.2.2
|
||||||
pkgrel=0
|
pkgrel=1
|
||||||
pkgdesc="3D printer / slicing GUI built on top of the Uranium framework"
|
pkgdesc="3D printer / slicing GUI built on top of the Uranium framework"
|
||||||
url="https://ultimaker.com/software/ultimaker-cura"
|
url="https://ultimaker.com/software/ultimaker-cura"
|
||||||
arch="noarch !ppc64le !x86 !armhf !riscv64 !s390x !armv7" # ppc64le: no py3-keyring
|
arch="noarch !ppc64le !x86 !armhf !riscv64 !s390x !armv7" # ppc64le: no py3-keyring
|
||||||
|
@ -42,8 +42,10 @@ builddir="$srcdir/Cura-$pkgver"
|
||||||
options="!check" # tests broken after v5.x
|
options="!check" # tests broken after v5.x
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
|
local pyver="$(python3 -c 'import sys; print(f"{sys.version_info.major}.{sys.version_info.minor}")')"
|
||||||
cmake -B build -G Ninja \
|
cmake -B build -G Ninja \
|
||||||
-DCURA_VERSION=$pkgver \
|
-DCURA_VERSION=$pkgver \
|
||||||
|
-DPython_VERSION=$pyver \
|
||||||
-DURANIUM_DIR=/usr/share/uranium \
|
-DURANIUM_DIR=/usr/share/uranium \
|
||||||
-DCMAKE_INSTALL_PREFIX=/usr \
|
-DCMAKE_INSTALL_PREFIX=/usr \
|
||||||
-DCMAKE_INSTALL_LIBDIR=lib \
|
-DCMAKE_INSTALL_LIBDIR=lib \
|
||||||
|
|
|
@ -1,36 +1,41 @@
|
||||||
# Maintainer: lauren n. liberda <lauren@selfisekai.rocks>
|
# Maintainer: lauren n. liberda <lauren@selfisekai.rocks>
|
||||||
pkgname=electron
|
pkgname=electron
|
||||||
pkgver=27.1.2
|
pkgver=30.0.9
|
||||||
_semver="${pkgver/_beta/-beta.}"
|
_semver="${pkgver/_beta/-beta.}"
|
||||||
pkgrel=0
|
pkgrel=0
|
||||||
_chromium=118.0.5993.162
|
_chromium=124.0.6367.233
|
||||||
_depot_tools=b5509953468edd0906f2dc297886939abbd2bed5
|
_copium_tag=124.5
|
||||||
_extra_patches=118.0.5993.11
|
_depot_tools=495b23b39aaba2ca3b55dd27cadc523f1cb17ee6
|
||||||
pkgdesc="Electron cross-platform desktop toolkit"
|
pkgdesc="Electron cross-platform desktop toolkit"
|
||||||
url="https://github.com/electron/electron"
|
url="https://github.com/electron/electron"
|
||||||
arch="aarch64 x86_64" # same as chromium
|
arch="aarch64 x86_64" # same as chromium
|
||||||
license="MIT"
|
license="MIT"
|
||||||
depends="gtk+3.0 so:libudev.so.1 xdg-utils"
|
depends="gtk+3.0 so:libudev.so.1 xdg-utils"
|
||||||
makedepends="
|
makedepends="
|
||||||
|
ada-dev
|
||||||
alsa-lib-dev
|
alsa-lib-dev
|
||||||
aom-dev
|
aom-dev
|
||||||
|
base64-dev
|
||||||
bash
|
bash
|
||||||
brotli-dev
|
brotli-dev
|
||||||
bsd-compat-headers
|
bsd-compat-headers
|
||||||
bzip2-dev
|
bzip2-dev
|
||||||
c-ares-dev
|
c-ares-dev
|
||||||
cairo-dev
|
cairo-dev
|
||||||
clang16-dev
|
clang-dev
|
||||||
clang-extra-tools
|
clang-extra-tools
|
||||||
compiler-rt
|
compiler-rt
|
||||||
|
crc32c-dev
|
||||||
cups-dev
|
cups-dev
|
||||||
curl-dev
|
curl-dev
|
||||||
dav1d-dev
|
dav1d-dev
|
||||||
dbus-glib-dev
|
dbus-glib-dev
|
||||||
|
double-conversion-dev
|
||||||
eudev-dev
|
eudev-dev
|
||||||
ffmpeg-dev
|
ffmpeg-dev
|
||||||
findutils
|
findutils
|
||||||
flac-dev
|
flac-dev
|
||||||
|
flatbuffers-dev
|
||||||
flex
|
flex
|
||||||
freetype-dev
|
freetype-dev
|
||||||
gperf
|
gperf
|
||||||
|
@ -38,23 +43,26 @@ makedepends="
|
||||||
gn
|
gn
|
||||||
gzip
|
gzip
|
||||||
harfbuzz-dev
|
harfbuzz-dev
|
||||||
|
hdrhistogram-c-dev
|
||||||
|
highway-dev
|
||||||
hunspell-dev
|
hunspell-dev
|
||||||
http-parser-dev
|
http-parser-dev
|
||||||
hwdata-dev
|
hwdata-dev
|
||||||
java-jdk
|
java-jdk
|
||||||
jpeg-dev
|
jpeg-dev
|
||||||
jsoncpp-dev
|
|
||||||
krb5-dev
|
krb5-dev
|
||||||
lcms2-dev
|
lcms2-dev
|
||||||
libarchive-tools
|
libarchive-tools
|
||||||
libavif-dev
|
libavif-dev
|
||||||
libbsd-dev
|
libbsd-dev
|
||||||
libcap-dev
|
libcap-dev
|
||||||
|
libdrm-dev
|
||||||
libevent-dev
|
libevent-dev
|
||||||
libexif-dev
|
libexif-dev
|
||||||
libgcrypt-dev
|
libgcrypt-dev
|
||||||
libjpeg-turbo-dev
|
libjpeg-turbo-dev
|
||||||
libnotify-dev
|
libnotify-dev
|
||||||
|
libsecret-dev
|
||||||
libusb-dev
|
libusb-dev
|
||||||
libva-dev
|
libva-dev
|
||||||
libwebp-dev
|
libwebp-dev
|
||||||
|
@ -67,31 +75,31 @@ makedepends="
|
||||||
libxslt-dev
|
libxslt-dev
|
||||||
linux-headers
|
linux-headers
|
||||||
lld
|
lld
|
||||||
llvm16
|
llvm
|
||||||
mesa-dev
|
mesa-dev
|
||||||
minizip-dev
|
minizip-dev
|
||||||
nghttp2-dev
|
nghttp2-dev
|
||||||
nodejs
|
nodejs
|
||||||
npm
|
npm
|
||||||
nss-dev
|
nss-dev
|
||||||
|
openh264-dev
|
||||||
opus-dev
|
opus-dev
|
||||||
pciutils-dev
|
pciutils-dev
|
||||||
perl
|
perl
|
||||||
pipewire-dev
|
pipewire-dev
|
||||||
pulseaudio-dev
|
pulseaudio-dev
|
||||||
py3-httplib2
|
py3-httplib2
|
||||||
|
py3-jinja2
|
||||||
py3-parsing
|
py3-parsing
|
||||||
|
py3-setuptools
|
||||||
py3-six
|
py3-six
|
||||||
python3
|
python3
|
||||||
qt5-qtbase-dev
|
qt5-qtbase-dev
|
||||||
re2-dev
|
|
||||||
rsync
|
rsync
|
||||||
rust
|
rust
|
||||||
samurai
|
samurai
|
||||||
snappy-dev
|
|
||||||
speex-dev
|
speex-dev
|
||||||
sqlite-dev
|
sqlite-dev
|
||||||
woff2-dev
|
|
||||||
xcb-proto
|
xcb-proto
|
||||||
yarn
|
yarn
|
||||||
zlib-dev
|
zlib-dev
|
||||||
|
@ -99,59 +107,82 @@ makedepends="
|
||||||
"
|
"
|
||||||
subpackages="$pkgname-lang $pkgname-dev"
|
subpackages="$pkgname-lang $pkgname-dev"
|
||||||
# the lower patches are specific to electron, the top ones are from the equivalent chromium version
|
# the lower patches are specific to electron, the top ones are from the equivalent chromium version
|
||||||
source="https://s3.sakamoto.pl/lnl-aports-snapshots/electron-$_semver-$_chromium.tar.zst
|
source="https://ab-sn.lnl.gay/electron-$_semver-$_chromium.tar.zst
|
||||||
https://gitlab.com/Matt.Jolly/chromium-patches/-/archive/$_extra_patches/chromium-patches-$_extra_patches.tar.gz
|
copium-$_copium_tag.tar.gz::https://codeberg.org/selfisekai/copium/archive/$_copium_tag.tar.gz
|
||||||
chromium-revert-drop-of-system-java.patch
|
chromium-revert-drop-of-system-java.patch
|
||||||
chromium-use-alpine-target.patch
|
compiler.patch
|
||||||
|
disable-dns_config_service.patch
|
||||||
|
disable-failing-tests.patch
|
||||||
|
fc-cache-version.patch
|
||||||
fix-missing-cstdint-include-musl.patch
|
fix-missing-cstdint-include-musl.patch
|
||||||
|
fix-opus.patch
|
||||||
|
fstatat-32bit.patch
|
||||||
gdbinit.patch
|
gdbinit.patch
|
||||||
|
generic-sensor-include.patch
|
||||||
import-version.patch
|
import-version.patch
|
||||||
libstdc++13.patch
|
libstdc++13.patch
|
||||||
mman.patch
|
mman.patch
|
||||||
|
musl-auxv.patch
|
||||||
musl-sandbox.patch
|
musl-sandbox.patch
|
||||||
musl-tid-caching.patch
|
musl-tid-caching.patch
|
||||||
musl-v8-monotonic-pthread-cont_timedwait.patch
|
musl-v8-monotonic-pthread-cont_timedwait.patch
|
||||||
no-execinfo.patch
|
no-execinfo.patch
|
||||||
no-mallinfo.patch
|
no-mallinfo.patch
|
||||||
no-mte.patch
|
|
||||||
no-res-ninit-nclose.patch
|
no-res-ninit-nclose.patch
|
||||||
no-sandbox-settls.patch
|
no-sandbox-settls.patch
|
||||||
|
partalloc-no-tagging-arm64.patch
|
||||||
|
perfetto-libstdc++.patch
|
||||||
|
pvalloc.patch
|
||||||
|
random-fixes.patch
|
||||||
|
quiche-array.patch
|
||||||
|
system-zstd.patch
|
||||||
temp-failure-retry.patch
|
temp-failure-retry.patch
|
||||||
|
yes-musl.patch
|
||||||
|
|
||||||
icon.patch
|
icon.patch
|
||||||
python-jinja-3.10.patch
|
python-jinja-3.10.patch
|
||||||
vector-const.patch
|
|
||||||
webpack-hash.patch
|
webpack-hash.patch
|
||||||
chromium-icu-74.patch
|
unbundle-node.patch
|
||||||
|
|
||||||
default.conf
|
default.conf
|
||||||
electron.desktop
|
electron.desktop
|
||||||
electron-launcher.sh
|
electron-launcher.sh
|
||||||
"
|
"
|
||||||
|
_copium_patches="
|
||||||
|
cr124-iwyu-sys-select-dawn-terminal.patch
|
||||||
|
cr124-libwebp-shim-sharpyuv.patch
|
||||||
|
"
|
||||||
# tests are todo for some base checks
|
# tests are todo for some base checks
|
||||||
options="!check net suid"
|
options="!check net suid"
|
||||||
builddir="$srcdir/electron-$_semver-$_chromium"
|
builddir="$srcdir/electron-$_semver-$_chromium"
|
||||||
|
|
||||||
export PATH="$PATH:/usr/lib/qt5/bin"
|
export PATH="$PATH:/usr/lib/qt5/bin"
|
||||||
|
|
||||||
# clang uses much less memory (and this doesn't support gcc)
|
export CC=clang
|
||||||
export CC=clang-16
|
export CXX=clang++
|
||||||
export CXX=clang++-16
|
|
||||||
|
|
||||||
# required to find the tools
|
# required to find the tools
|
||||||
export AR=llvm16-ar
|
export AR=llvm-ar
|
||||||
export NM=llvm16-nm
|
export NM=llvm-nm
|
||||||
export LD=clang++-16
|
export LD=clang++
|
||||||
|
|
||||||
# less log spam, reproducible
|
# less log spam, reproducible
|
||||||
export CFLAGS="${CFLAGS/-g/} -O2 -Wno-unknown-warning-option -Wno-builtin-macro-redefined -Wno-deprecated-declarations"
|
export CFLAGS="${CFLAGS/-g/} -O2 -Wno-builtin-macro-redefined -Wno-deprecated-declarations -Wno-shift-count-overflow -Wno-ignored-attributes"
|
||||||
export CXXFLAGS="${CXXFLAGS/-g/} -O2 -Wno-unknown-warning-option -Wno-builtin-macro-redefined -Wno-deprecated-declarations"
|
export CXXFLAGS="${CXXFLAGS/-g/} -O2 -Wno-builtin-macro-redefined -Wno-deprecated-declarations -Wno-invalid-constexpr"
|
||||||
export CPPFLAGS="${CPPFLAGS/-g/} -D__DATE__= -D__TIME__= -D__TIMESTAMP__="
|
export CPPFLAGS="${CPPFLAGS/-g/} -D__DATE__= -D__TIME__= -D__TIMESTAMP__="
|
||||||
|
case "$CARCH" in
|
||||||
|
aarch64|arm*|riscv64)
|
||||||
|
# not supported by clang here
|
||||||
|
export CFLAGS="${CFLAGS/-fstack-clash-protection}"
|
||||||
|
export CXXFLAGS="${CXXFLAGS/-fstack-clash-protection}"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
# breaks chromium-based stuff
|
# breaks chromium-based stuff
|
||||||
export CXXFLAGS="${CXXFLAGS/-D_GLIBCXX_ASSERTIONS=1}"
|
export CXXFLAGS="${CXXFLAGS/-D_GLIBCXX_ASSERTIONS=1}"
|
||||||
|
|
||||||
# creates a dist tarball that does not need to git clone everything at build time.
|
# creates a dist tarball that does not need to git clone everything at build time.
|
||||||
|
_distbucket="sakamoto/lnl-aports-snapshots/"
|
||||||
snapshot() {
|
snapshot() {
|
||||||
deps
|
deps
|
||||||
# vpython3 execs system python3 with this set
|
# vpython3 execs system python3 with this set
|
||||||
|
@ -159,14 +190,6 @@ snapshot() {
|
||||||
export CHROMIUM_BUILDTOOLS_PATH="$srcdir/src/buildtools"
|
export CHROMIUM_BUILDTOOLS_PATH="$srcdir/src/buildtools"
|
||||||
mkdir -p "$srcdir"
|
mkdir -p "$srcdir"
|
||||||
cd "$srcdir"
|
cd "$srcdir"
|
||||||
if ! [ -d src ]; then
|
|
||||||
git clone --branch=$_chromium --depth=1 \
|
|
||||||
https://chromium.googlesource.com/chromium/src.git
|
|
||||||
fi
|
|
||||||
|
|
||||||
if ! [ -d electron ]; then
|
|
||||||
git clone https://github.com/electron/electron.git
|
|
||||||
fi
|
|
||||||
|
|
||||||
if ! [ -d depot_tools ]; then
|
if ! [ -d depot_tools ]; then
|
||||||
(
|
(
|
||||||
|
@ -182,19 +205,18 @@ snapshot() {
|
||||||
echo "solutions = [
|
echo "solutions = [
|
||||||
{
|
{
|
||||||
\"name\": \"src/electron\",
|
\"name\": \"src/electron\",
|
||||||
\"url\": \"file://$srcdir/electron@v$_semver\",
|
\"url\": \"https://github.com/electron/electron.git@v$_semver\",
|
||||||
\"deps_file\": \"DEPS\",
|
\"deps_file\": \"DEPS\",
|
||||||
\"managed\": False,
|
\"managed\": False,
|
||||||
\"custom_deps\": {
|
\"custom_deps\": {
|
||||||
\"src\": None,
|
\"src\": \"https://chromium.googlesource.com/chromium/src.git@$_chromium\",
|
||||||
},
|
},
|
||||||
\"custom_vars\": {},
|
\"custom_vars\": {},
|
||||||
},
|
},
|
||||||
]" > .gclient
|
]" > .gclient
|
||||||
|
|
||||||
python3 depot_tools/gclient.py sync \
|
python3 depot_tools/gclient.py sync \
|
||||||
--with_branch_heads \
|
--no-history \
|
||||||
--with_tags \
|
|
||||||
--nohooks
|
--nohooks
|
||||||
|
|
||||||
python3 src/build/landmines.py
|
python3 src/build/landmines.py
|
||||||
|
@ -206,22 +228,11 @@ snapshot() {
|
||||||
python3 src/build/util/lastchange.py -m SKIA_COMMIT_HASH \
|
python3 src/build/util/lastchange.py -m SKIA_COMMIT_HASH \
|
||||||
-s src/third_party/skia --header src/skia/ext/skia_commit_hash.h
|
-s src/third_party/skia --header src/skia/ext/skia_commit_hash.h
|
||||||
|
|
||||||
# why?
|
# rolled newer chromium with it included
|
||||||
cp -r electron/patches/ffmpeg src/electron/patches/
|
sed -i '/reland_mojom_ts_generator_handle_empty_module_path_identically_to.patch/d' src/electron/patches/chromium/.patches
|
||||||
|
|
||||||
python3 electron/script/apply_all_patches.py \
|
python3 src/electron/script/apply_all_patches.py \
|
||||||
electron/patches/config.json
|
src/electron/patches/config.json
|
||||||
|
|
||||||
python3 src/tools/update_pgo_profiles.py \
|
|
||||||
--target=linux \
|
|
||||||
update \
|
|
||||||
--gs-url-base=chromium-optimization-profiles/pgo_profiles
|
|
||||||
|
|
||||||
python3 src/tools/download_optimization_profile.py \
|
|
||||||
--newest_state=src/chrome/android/profiles/newest.txt \
|
|
||||||
--local_state=src/chrome/android/profiles/local.txt \
|
|
||||||
--output_name=src/chrome/android/profiles/afdo.prof \
|
|
||||||
--gs_url_base=chromeos-prebuilt/afdo-job/llvm
|
|
||||||
|
|
||||||
mv src $pkgname-$_semver-$_chromium
|
mv src $pkgname-$_semver-$_chromium
|
||||||
|
|
||||||
|
@ -241,24 +252,28 @@ snapshot() {
|
||||||
--exclude-vcs \
|
--exclude-vcs \
|
||||||
$pkgname-$_semver-$_chromium
|
$pkgname-$_semver-$_chromium
|
||||||
|
|
||||||
zstd --auto-threads=logical --ultra --long -22 -T"${ZSTD_LIMIT:-0}" -vv $pkgname-$_semver-$_chromium.tar
|
zstd --auto-threads=logical --ultra --long -22 -T"${ZSTD_LIMIT:-0}" -vv $pkgname-$_semver-$_chromium.tar -o "$SRCDEST"/$pkgname-$_semver-$_chromium.tar.zst
|
||||||
}
|
mcli cp "$SRCDEST"/$pkgname-$_semver-$_chromium.tar.zst "$_distbucket"
|
||||||
|
|
||||||
_extra_patch() {
|
|
||||||
msg chromium-"$1".patch
|
|
||||||
patch -Np1 < "$srcdir"/chromium-patches-"$_extra_patches"/chromium-"$1".patch
|
|
||||||
}
|
}
|
||||||
|
|
||||||
prepare() {
|
prepare() {
|
||||||
dos2unix third_party/vulkan_memory_allocator/include/vk_mem_alloc.h
|
|
||||||
|
|
||||||
default_prepare
|
default_prepare
|
||||||
|
|
||||||
_extra_patch 118-SensorReadingField-include
|
for i in $_copium_patches; do
|
||||||
_extra_patch 117-material-color-include
|
case "$i" in
|
||||||
_extra_patch 118-system-freetype
|
*.patch)
|
||||||
_extra_patch 117-system-zstd
|
msg "${i%::*}"
|
||||||
_extra_patch 118-compiler
|
patch -p1 -i "$srcdir/copium/$i" || failed="$failed $i"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
if [ ! -z "$failed" ]; then
|
||||||
|
error "The following patches failed to apply:"
|
||||||
|
for i in $failed; do
|
||||||
|
printf " %s\n" "$i" >&2
|
||||||
|
done
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
git init -q .
|
git init -q .
|
||||||
|
|
||||||
|
@ -286,32 +301,39 @@ prepare() {
|
||||||
./update_npm_deps
|
./update_npm_deps
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# reusable system library settings
|
||||||
|
# flatbuffers - tensorflow has a few static_asserts for a specific patch version
|
||||||
|
# libavif - https://github.com/AOMediaCodec/libavif/commit/50a541469c98009016af8dcc9f83a1be79f3a7d9
|
||||||
# libaom - https://aomedia.googlesource.com/aom/+/706ee36dcc82%5E%21/
|
# libaom - https://aomedia.googlesource.com/aom/+/706ee36dcc82%5E%21/
|
||||||
local use_system="
|
# but watch this space: https://aomedia-review.googlesource.com/c/aom/+/188606
|
||||||
|
# jsoncpp, re2, snappy, swiftshader, vulkan, woff2 - needs use_custom_libcxx=false
|
||||||
|
local chromium_use_system="
|
||||||
|
brotli
|
||||||
|
crc32c
|
||||||
dav1d
|
dav1d
|
||||||
|
double-conversion
|
||||||
ffmpeg
|
ffmpeg
|
||||||
flac
|
flac
|
||||||
fontconfig
|
fontconfig
|
||||||
freetype
|
freetype
|
||||||
harfbuzz-ng
|
harfbuzz-ng
|
||||||
|
highway
|
||||||
icu
|
icu
|
||||||
jsoncpp
|
|
||||||
libavif
|
|
||||||
libdrm
|
libdrm
|
||||||
libevent
|
libevent
|
||||||
libjpeg
|
libjpeg
|
||||||
|
libsecret
|
||||||
|
libusb
|
||||||
libwebp
|
libwebp
|
||||||
libxml
|
libxml
|
||||||
libxslt
|
libxslt
|
||||||
|
openh264
|
||||||
opus
|
opus
|
||||||
re2
|
|
||||||
snappy
|
|
||||||
woff2
|
|
||||||
zlib
|
zlib
|
||||||
zstd
|
zstd
|
||||||
"
|
"
|
||||||
|
|
||||||
for _lib in $use_system libjpeg_turbo; do
|
for _lib in $chromium_use_system jinja2 libjpeg_turbo; do
|
||||||
msg "Removing buildscripts for system provided $_lib"
|
msg "Removing buildscripts for system provided $_lib"
|
||||||
find . -type f -path "*third_party/$_lib/*" \
|
find . -type f -path "*third_party/$_lib/*" \
|
||||||
\! -path "*third_party/$_lib/chromium/*" \
|
\! -path "*third_party/$_lib/chromium/*" \
|
||||||
|
@ -321,10 +343,39 @@ prepare() {
|
||||||
\! -path './third_party/pdfium/third_party/freetype/include/pstables.h' \
|
\! -path './third_party/pdfium/third_party/freetype/include/pstables.h' \
|
||||||
\! -path './third_party/harfbuzz-ng/utils/hb_scoped.h' \
|
\! -path './third_party/harfbuzz-ng/utils/hb_scoped.h' \
|
||||||
\! -path './third_party/crashpad/crashpad/third_party/zlib/zlib_crashpad.h' \
|
\! -path './third_party/crashpad/crashpad/third_party/zlib/zlib_crashpad.h' \
|
||||||
\! -regex '.*\.\(gn\|gni\|isolate\|py\)' \
|
\! -regex '.*\.\(gn\|gni\|gyp\|gypi\|isolate\|py\)' \
|
||||||
-delete
|
-delete
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# llhttp - 9.x needed, 8.x in repo (2023-12-17)
|
||||||
|
# ada - needs use_custom_libcxx=false
|
||||||
|
local node_use_system="
|
||||||
|
base64
|
||||||
|
brotli
|
||||||
|
cares
|
||||||
|
corepack
|
||||||
|
histogram
|
||||||
|
nghttp2
|
||||||
|
nghttp3
|
||||||
|
ngtcp2
|
||||||
|
zlib
|
||||||
|
"
|
||||||
|
# some of these are provided by system, e.g. brotli. some are from chromium,
|
||||||
|
# e.g. boringssl (as openssl). some are not in use at all (corepack)
|
||||||
|
for _lib in $node_use_system openssl; do
|
||||||
|
msg "Removing buildscripts for $_lib"
|
||||||
|
find . -type f -path "*third_party/electron_node/deps/$_lib/*" \
|
||||||
|
\! -path "*third_party/electron_node/deps/$_lib/chromium/*" \
|
||||||
|
\! -path "*third_party/electron_node/deps/$_lib/google/*" \
|
||||||
|
\! -regex '.*\.\(gn\|gni\|gyp\|gypi\|isolate\|py\)' \
|
||||||
|
-delete
|
||||||
|
done
|
||||||
|
# XXX: hack. unbundle-node.patch uses this list to switch things
|
||||||
|
# in config.gypi. https://github.com/electron/electron/issues/40836
|
||||||
|
echo $node_use_system > third_party/electron_node/use_system.txt
|
||||||
|
|
||||||
|
rm -rf third_party/electron_node/tools/inspector_protocol/jinja2
|
||||||
|
|
||||||
# https://groups.google.com/a/chromium.org/d/topic/chromium-packagers/9JX1N2nf4PU/discussion
|
# https://groups.google.com/a/chromium.org/d/topic/chromium-packagers/9JX1N2nf4PU/discussion
|
||||||
touch chrome/test/data/webui/i18n_process_css_test.html
|
touch chrome/test/data/webui/i18n_process_css_test.html
|
||||||
# Use the file at run time instead of effectively compiling it in
|
# Use the file at run time instead of effectively compiling it in
|
||||||
|
@ -333,7 +384,7 @@ prepare() {
|
||||||
|
|
||||||
msg "Running debundle script"
|
msg "Running debundle script"
|
||||||
python3 build/linux/unbundle/replace_gn_files.py --system-libraries \
|
python3 build/linux/unbundle/replace_gn_files.py --system-libraries \
|
||||||
$use_system
|
$chromium_use_system
|
||||||
python3 third_party/libaddressinput/chromium/tools/update-strings.py
|
python3 third_party/libaddressinput/chromium/tools/update-strings.py
|
||||||
|
|
||||||
# prevent annoying errors when regenerating gni
|
# prevent annoying errors when regenerating gni
|
||||||
|
@ -358,63 +409,77 @@ _configure() {
|
||||||
cd "$builddir"
|
cd "$builddir"
|
||||||
msg "Configuring build"
|
msg "Configuring build"
|
||||||
|
|
||||||
|
local clang_ver="$(clang -dumpversion)"
|
||||||
|
|
||||||
|
case "$USE_CCACHE" in
|
||||||
|
1)
|
||||||
|
local cc_wrapper="ccache"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
local cc_wrapper=""
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
local maglev=true
|
||||||
|
local symbol_level=0
|
||||||
|
local vaapi=true
|
||||||
|
|
||||||
# shellcheck disable=2089
|
# shellcheck disable=2089
|
||||||
local gn_config="
|
local gn_config="
|
||||||
clang_base_path=\"/usr\"
|
|
||||||
custom_toolchain=\"//build/toolchain/linux/unbundle:default\"
|
|
||||||
host_toolchain=\"//build/toolchain/linux/unbundle:default\"
|
|
||||||
import(\"//electron/build/args/release.gn\")
|
import(\"//electron/build/args/release.gn\")
|
||||||
|
|
||||||
blink_enable_generated_code_formatting=false
|
blink_enable_generated_code_formatting=false
|
||||||
|
cc_wrapper=\"$cc_wrapper\"
|
||||||
chrome_pgo_phase=0
|
chrome_pgo_phase=0
|
||||||
|
clang_base_path=\"/usr\"
|
||||||
clang_use_chrome_plugins=false
|
clang_use_chrome_plugins=false
|
||||||
|
clang_version=\"${clang_ver%%.*}\"
|
||||||
|
custom_toolchain=\"//build/toolchain/linux/unbundle:default\"
|
||||||
|
disable_fieldtrial_testing_config=true
|
||||||
|
enable_hangout_services_extension=true
|
||||||
|
enable_nacl=false
|
||||||
|
enable_nocompile_tests=false
|
||||||
|
enable_stripping=false
|
||||||
|
enable_rust=true
|
||||||
|
enable_vr=false
|
||||||
fatal_linker_warnings=false
|
fatal_linker_warnings=false
|
||||||
ffmpeg_branding=\"Chrome\"
|
ffmpeg_branding=\"Chrome\"
|
||||||
icu_use_data_file=true
|
host_toolchain=\"//build/toolchain/linux/unbundle:default\"
|
||||||
|
icu_use_data_file=false
|
||||||
is_cfi=false
|
is_cfi=false
|
||||||
is_clang=true
|
is_clang=true
|
||||||
is_component_ffmpeg=true
|
is_component_ffmpeg=true
|
||||||
is_debug=false
|
is_debug=false
|
||||||
is_official_build=true
|
is_official_build=true
|
||||||
symbol_level=0
|
|
||||||
treat_warnings_as_errors=false
|
|
||||||
|
|
||||||
angle_enable_gl_null=false
|
|
||||||
build_tflite_with_xnnpack=false
|
|
||||||
build_with_tflite_lib=true
|
|
||||||
disable_fieldtrial_testing_config=true
|
|
||||||
enable_hangout_services_extension=true
|
|
||||||
enable_library_cdms=false
|
|
||||||
enable_media_remoting=false
|
|
||||||
enable_nacl=false
|
|
||||||
enable_paint_preview=false
|
|
||||||
enable_reading_list=false
|
|
||||||
enable_remoting=false
|
|
||||||
enable_reporting=false
|
|
||||||
enable_rust=false
|
|
||||||
enable_screen_ai_service=false
|
|
||||||
enable_service_discovery=false
|
|
||||||
enable_stripping=false
|
|
||||||
enable_vr=false
|
|
||||||
ozone_platform_headless=false
|
|
||||||
|
|
||||||
link_pulseaudio=true
|
link_pulseaudio=true
|
||||||
proprietary_codecs=true
|
proprietary_codecs=true
|
||||||
|
regenerate_x11_protos=true
|
||||||
rtc_link_pipewire=true
|
rtc_link_pipewire=true
|
||||||
rtc_use_pipewire=true
|
rtc_use_pipewire=true
|
||||||
use_custom_libcxx=false
|
rustc_version=\"yes\"
|
||||||
use_dawn=false
|
rust_sysroot_absolute=\"/usr\"
|
||||||
|
symbol_level=$symbol_level
|
||||||
|
treat_warnings_as_errors=false
|
||||||
|
use_custom_libcxx=true
|
||||||
|
use_lld=true
|
||||||
use_pulseaudio=true
|
use_pulseaudio=true
|
||||||
use_sysroot=false
|
use_safe_libstdcxx=false
|
||||||
use_system_cares=true
|
|
||||||
use_system_freetype=true
|
|
||||||
use_system_harfbuzz=true
|
|
||||||
use_system_lcms2=true
|
|
||||||
use_system_libdrm=true
|
|
||||||
use_system_libffi=true
|
use_system_libffi=true
|
||||||
use_system_libjpeg=true
|
use_sysroot=false
|
||||||
|
use_thin_lto=false
|
||||||
|
use_vaapi=$vaapi
|
||||||
|
v8_enable_maglev=$maglev
|
||||||
|
|
||||||
|
skia_use_dawn=false
|
||||||
|
use_dawn=false
|
||||||
|
use_system_ada=false
|
||||||
|
use_system_base64=true
|
||||||
|
use_system_cares=true
|
||||||
|
use_system_histogram=true
|
||||||
|
use_system_lcms2=true
|
||||||
|
use_system_libffi=true
|
||||||
|
use_system_llhttp=false
|
||||||
use_system_nghttp2=true
|
use_system_nghttp2=true
|
||||||
use_vaapi=true
|
|
||||||
"
|
"
|
||||||
|
|
||||||
# shellcheck disable=2086,2090,2116
|
# shellcheck disable=2086,2090,2116
|
||||||
|
@ -425,11 +490,15 @@ _configure() {
|
||||||
build() {
|
build() {
|
||||||
export PATH="$PATH:/usr/lib/qt5/bin"
|
export PATH="$PATH:/usr/lib/qt5/bin"
|
||||||
|
|
||||||
ninja -C out/Release \
|
# ~1 GB per concurrent job is not enough with gcc
|
||||||
|
_njobs="${NJOBS:-"$(python3 -c 'import os; print(max((os.cpu_count() - (10 if os.uname().machine == "aarch64" else 8), 1)))')"}"
|
||||||
|
|
||||||
|
ninja -C out/Release -j$_njobs \
|
||||||
electron_dist_zip \
|
electron_dist_zip \
|
||||||
node_gypi_headers \
|
node_gypi_headers \
|
||||||
node_version_header \
|
node_version_header
|
||||||
tar_headers
|
|
||||||
|
cp -vf out/Release/gen/node_headers/include/node/config.gypi third_party/electron_node/config.gypi
|
||||||
}
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
|
@ -444,7 +513,12 @@ package() {
|
||||||
|
|
||||||
mkdir -p "$pkgdir"/usr/include/electron
|
mkdir -p "$pkgdir"/usr/include/electron
|
||||||
|
|
||||||
mv -v "$builddir"/out/Release/gen/node_headers "$pkgdir"/usr/include/electron
|
(
|
||||||
|
cd third_party/electron_node/
|
||||||
|
HEADERS_ONLY=1 python3 ./tools/install.py install "$pkgdir" "/usr/include/electron/node_headers"
|
||||||
|
)
|
||||||
|
# required overrides
|
||||||
|
install -Dm644 out/Release/gen/node_headers/include/node/* -t "$pkgdir"/usr/include/electron/node_headers/include/node
|
||||||
ln -sv /usr/include/electron/node_headers/include/node "$pkgdir"/usr/include/electron/node
|
ln -sv /usr/include/electron/node_headers/include/node "$pkgdir"/usr/include/electron/node
|
||||||
|
|
||||||
mkdir -p "$pkgdir"/usr/include/electron/node_headers/include/nan
|
mkdir -p "$pkgdir"/usr/include/electron/node_headers/include/nan
|
||||||
|
@ -470,30 +544,42 @@ lang() {
|
||||||
}
|
}
|
||||||
|
|
||||||
sha512sums="
|
sha512sums="
|
||||||
07f653f24e7fe1ef96a0ff676fa3c987fd0826980b5e9611705cb7fc44f00182fa62e67e67c6df5a3b1b4c063d99a3266054a83aa67fb44b11ffffcd8e23c3eb electron-27.1.2-118.0.5993.162.tar.zst
|
97024407a16fb41ec56fcc6df5552165ce4eea34fc51b17ecbf30a7e35406baccf8a3001a795a06d1e92d32e134d9d7a18d59fa74eda1b1bc23b59bc4947929b electron-30.0.9-124.0.6367.233.tar.zst
|
||||||
194c3a7a0fa03a85df6fe52ece3d53d4d15b9d0cb440b56a2ccb1b5c0d3f6481b6f7287aa705c596ceea92d475677ddaf58926f3b31c03a3c20e80ad7e481ce7 chromium-patches-118.0.5993.11.tar.gz
|
13c647dc2024e27ae8a4d7e8f1202037a342f4a7054477226665c332029e1b6f1d8b99004c2b2809bcf1e6c19b1359ef5e1c971552d7ced59c5b43d5a836af88 copium-124.5.tar.gz
|
||||||
29bb685e03356a77df5fd347cdf55194cc8b3265c421cc76e54d64edefc329dbcb052deb26b22e8f587ce68456876c071de1b7d258dd0fcc6ee66c875ec4a020 chromium-revert-drop-of-system-java.patch
|
29bb685e03356a77df5fd347cdf55194cc8b3265c421cc76e54d64edefc329dbcb052deb26b22e8f587ce68456876c071de1b7d258dd0fcc6ee66c875ec4a020 chromium-revert-drop-of-system-java.patch
|
||||||
fa291e941076146d0edd5b96c088240a44a6e0aca3dfc744929655607182d2dc47e6c35ecb419f7c623fcf7f26dc3c4dd924dbf5ed10c3b986283f5ef2f72573 chromium-use-alpine-target.patch
|
54eb147c0af2ba096d1df375a289b339ee855ab1a9114e7c747753f0274a6bafb7212c1859b7885454c4529d9a5e3bd9559fc14e8e006f23ccd381895fa68d15 compiler.patch
|
||||||
|
4057cc78f10bfd64092bc35a373869abb1d68b880cdbca70422f39ffd78a929c19c7728d4d4c40709aaba25581148a93ae5343e724849fd35323062ed68753fa disable-dns_config_service.patch
|
||||||
|
111bc22fb704d97759988268a40d6b356c51b0bd7a8119a694e905ffe21850ff64e91566cd0dd0c9d62fcb46dca8acc821436c34eb0ba78be872ee4f7ec88a7b disable-failing-tests.patch
|
||||||
|
5fc5c012c1db6cf1ba82f38c6f3f4f5ca3a209e47ac708a74de379b018e0649b7694877c9571ef79002dde875ffc07b458a3355425f1c01867f362c66c2bc1bf fc-cache-version.patch
|
||||||
9200f78bad70e95c648a5e8392d50642190600f655c6baa366ff6467ebad52d3b3f305dad58f3610da67136f4b723557653b174ec5c25be8d8737ee04d9ee09f fix-missing-cstdint-include-musl.patch
|
9200f78bad70e95c648a5e8392d50642190600f655c6baa366ff6467ebad52d3b3f305dad58f3610da67136f4b723557653b174ec5c25be8d8737ee04d9ee09f fix-missing-cstdint-include-musl.patch
|
||||||
|
b24563e9a738c00fce7ff2fbdee3d7c024d9125d7c74d9ab90af6bdb16f7ec8419f2c8aa78c0640f6d5d81c17dc2c673a194401d354f466749672729b48ed068 fix-opus.patch
|
||||||
|
c63dee5044353eb306a39ca1526158c0f003ab310ecb03d1c368dc2a979454590c84b8d3c15484517d5e66bb8add9b231da9abbadf2e50850abd72ac1345c4ab fstatat-32bit.patch
|
||||||
33ee60863cc438ef57ffef92ba4cf67a856a5ffc16138bce241bcf87e47b15154aa86918e793c26f7ec4dc62a445257ad5673ed7001daf22c4043cf6cc57da7f gdbinit.patch
|
33ee60863cc438ef57ffef92ba4cf67a856a5ffc16138bce241bcf87e47b15154aa86918e793c26f7ec4dc62a445257ad5673ed7001daf22c4043cf6cc57da7f gdbinit.patch
|
||||||
|
36a764fa73443b47d38050b52dbe6ad2fa8d67201ff4ccdbad13b52308ef165ca046aac6f9609fe35890a6485f0f3e672e78cc41e3e44f3cdc7f145e540524e8 generic-sensor-include.patch
|
||||||
8de65109ece27ea63bd469f2220c56b8c752ba0a50fdf390082a2d5ae74b8e010199126175569f6d5084270dd4e0571e68aec32c0bca8211a6699925b3a09124 import-version.patch
|
8de65109ece27ea63bd469f2220c56b8c752ba0a50fdf390082a2d5ae74b8e010199126175569f6d5084270dd4e0571e68aec32c0bca8211a6699925b3a09124 import-version.patch
|
||||||
49851d42ce8ccd533d01d1bb2477930802b0bcebab8dd52f2da292088378c6ed9b74146e7dad55edfe096281fc84b2c55abaf832744fd4553a97c38ed891df3a libstdc++13.patch
|
c49a1b06e061faa430d66dd5b404ef6c843e4d8a6e9012e963009a161b4726f8eb92c4da8fa710f8861f6e4daa8be5f68abee41a7d9fc02f2a0eb61ce53b5fdd libstdc++13.patch
|
||||||
0e991842e23a4b9133898125eeb39e45e3f86f886eef5d2f0d9a72ee143a3e124b3b4f60be94edd57ce4185bcd69704edb51f76d08fdb6207f5559a08dd41ab0 mman.patch
|
e75f57ae34c97ca1caf15fa4b4106c6c1e79c31ed66869cf92ed9ea0c449886c9511e455047c17c1e9ad8b9a46ad4948511a4f2995a4b6030fb4d1c7ae21d038 mman.patch
|
||||||
|
99bcc7dd485b404a90c606a96addab1d900852128d44fb8cea8acc7303189ef87c89a7b0e749fd0e10c5ef5f6bf1fadeb5c16a34503cab6a59938ce2653d887e musl-auxv.patch
|
||||||
50c274a420bb8a7f14fcb56e40920dac8f708792a4520789b4987facea459bef88113d5a2b60fa8c57bee6e92bff3617d6b73fa305c8c44614c638971cffd440 musl-sandbox.patch
|
50c274a420bb8a7f14fcb56e40920dac8f708792a4520789b4987facea459bef88113d5a2b60fa8c57bee6e92bff3617d6b73fa305c8c44614c638971cffd440 musl-sandbox.patch
|
||||||
e7163ac5810ac85366cef2447412287c856e3d67c6b77f219a6e5a418b1965b98e449c409424ad0704a5bded9355dd0aec3dc4585918ce5a2ab36c079707afe2 musl-tid-caching.patch
|
e7163ac5810ac85366cef2447412287c856e3d67c6b77f219a6e5a418b1965b98e449c409424ad0704a5bded9355dd0aec3dc4585918ce5a2ab36c079707afe2 musl-tid-caching.patch
|
||||||
92eb002718026611f5542362ad69b67f0a398ff71b3fca5c05d55cb5c6f9f29334e5e127bb4860cfaa3fba0f0d4c901e2b98808217e7dc02e254a64a5c9521aa musl-v8-monotonic-pthread-cont_timedwait.patch
|
92eb002718026611f5542362ad69b67f0a398ff71b3fca5c05d55cb5c6f9f29334e5e127bb4860cfaa3fba0f0d4c901e2b98808217e7dc02e254a64a5c9521aa musl-v8-monotonic-pthread-cont_timedwait.patch
|
||||||
8cc774e8d84e434960222c0497ad8193ae35c0732f98d3282d5fd4b4930f914809eec97832c199517ca89ca6b9d1d011db5ce533c40c68ce5fa464609d131a23 no-execinfo.patch
|
73bca6c6f9873f2f11cef04f3f41f71e0ae86e7e2d77e14db4298675fec390744c5081f6fdb14052e5ee2b5885be1198c3aa6068eb2b656d1a665c0c3f36e708 no-execinfo.patch
|
||||||
b5479874d125ee95a311295f227f8881a83023ec34fded7a6160b3ae32ea3ba0f2b833a9fb264c57f3d22746b6d8b00bdc8eb2ff86c43c412d6d3b55ae15b16b no-mallinfo.patch
|
8e17101d69e23b456a9c03dc2fe95bcd56846389707ba6f4720192a9e9168406d20d9168dbebbb3a47d921ec92e478f0e390f46e6b9bb43a34dda217c6e6448b no-mallinfo.patch
|
||||||
8a52ff52201a5e20344f5497ee2ffef0520f7b2d934be92227e49c3f2c12a94c33650eefc88a0e451a6b81d44ce197db421aaec7388e6bb1cb525a43628779d3 no-mte.patch
|
|
||||||
e4c4e5bc6f828f9c883dd418c0ba01887949c29c311f76206a1ec29f620b0c0ba0452949dc2778a9c46ea066405857536964a36436a68eecf7da7952736333cf no-res-ninit-nclose.patch
|
e4c4e5bc6f828f9c883dd418c0ba01887949c29c311f76206a1ec29f620b0c0ba0452949dc2778a9c46ea066405857536964a36436a68eecf7da7952736333cf no-res-ninit-nclose.patch
|
||||||
6dc4d8dc92e685dace62265a1ddb3aebc558aed54d20ff6d36b030be0c48d7e84662326c31363612492574d9a03c62653cdc21a60995b97dee1d75cae86a9f9b no-sandbox-settls.patch
|
6dc4d8dc92e685dace62265a1ddb3aebc558aed54d20ff6d36b030be0c48d7e84662326c31363612492574d9a03c62653cdc21a60995b97dee1d75cae86a9f9b no-sandbox-settls.patch
|
||||||
|
d4ac7f350806b4410ccb1df3b0ad7e90a7b6d724a16919761aa2d47a6f21008c7374da528b05b754ee712b85d23adfb113c7f7b9ca2ed5b47644fe3ea0cb9119 partalloc-no-tagging-arm64.patch
|
||||||
|
8e1aca983890c78d81a6f888b2cf1aa42878d1f8523e87d63b800e1e468cbfd33e5ff6a0975775ca222fe82f30c6497da95505da01b091c8776a44c98ac86f0f perfetto-libstdc++.patch
|
||||||
|
2eb434b4fc6aee77026492644cd86772a543d9845f112a75cd4c3e1f25c9435cc31f8454c1c73223451fc9be69b86e822ff68821978f67f2fc8bcba50296d8e0 pvalloc.patch
|
||||||
|
803b8117c65132f76bec42054a4b2257a078b15b07fd08645fec2dfd51aa4e0075a9015300cd579d4ae0d757d9850b9988e080cfc2eea093f6684fdf82c4722c random-fixes.patch
|
||||||
|
86f612dd2b39602984a75b1b11c2ab8bc8cc6b4e78fae998570a777a6901ae45fdcdb22e46dd006dab703a0674e64c72cf8120af2dc5b9e78004f402c7e65358 quiche-array.patch
|
||||||
|
b3beb98b539fe160fbc493ba410ae0f68540cc4b6834f1f8ce9a22c3f4f59ef5d583ad48793e10549fd02a701f833a3969791ef4524322cd1e715ca5bf226bc8 system-zstd.patch
|
||||||
e48693e6b7aeebf69a5acbf80d9a35defe4c23835121dfeb58b051ac7c527e758a41004f4d193274fe1b01c0bfb1dbc77b09cb6a404a3fdee507a2918afb0edb temp-failure-retry.patch
|
e48693e6b7aeebf69a5acbf80d9a35defe4c23835121dfeb58b051ac7c527e758a41004f4d193274fe1b01c0bfb1dbc77b09cb6a404a3fdee507a2918afb0edb temp-failure-retry.patch
|
||||||
905565c10f5e5600e7d4db965c892cc45009a258e9995da958974d838ace469e1db1019195307e8807860d5b55ba6bfeea478b1f39a9b99e82c619b2816a1a22 icon.patch
|
914ccf649d7771f19f209ab97f99c481aebc6f66174d68e8b539f6ad4a70bc8cb0fae2df6dadbf0415958ffb3574c420fe029079dcce45f5e5add4db2e903566 yes-musl.patch
|
||||||
|
465107da7818b237e3c144a318ab80c3c9343b51ed38b8971ef204692d13346929becbe94cefad4c153788d3a200642143584d5ca070f6304e768ba2139c19ec icon.patch
|
||||||
e05180199ee1d559e4e577cedd3e589844ecf40d98a86321bf1bea5607b02eeb5feb486deddae40e1005b644550331f6b8500177aa7e79bcb3750d3c1ceb76c3 python-jinja-3.10.patch
|
e05180199ee1d559e4e577cedd3e589844ecf40d98a86321bf1bea5607b02eeb5feb486deddae40e1005b644550331f6b8500177aa7e79bcb3750d3c1ceb76c3 python-jinja-3.10.patch
|
||||||
71571b15cf8bd6259b7fd22bea0e46b64890f3db776365de33fe539f26ce9ef99459e05c3dde9434c3657225bc67160abc915acd93033cb487c770c6a2a5975f vector-const.patch
|
|
||||||
2aa340854316f1284217c0ca17cbf44953684ad6c7da90815117df30928612eb9fb9ffb734b948dfc309cd25d1a67cd57f77aac2d052a3dd9aca07a3a58cbb30 webpack-hash.patch
|
2aa340854316f1284217c0ca17cbf44953684ad6c7da90815117df30928612eb9fb9ffb734b948dfc309cd25d1a67cd57f77aac2d052a3dd9aca07a3a58cbb30 webpack-hash.patch
|
||||||
4c540972fa12acd9f0aafb8dc7e9987c3d6e4f28ff679dde522ebcec2dc5ae1a62d9d255bed0a30b9c79ae3b90ab0f5b9ae1ef5b7bf338612e28d9ef70250ca3 chromium-icu-74.patch
|
ebb18a0e2eba4b4606e900fa82f4b57fe91dcbdc943e17544bccb3c9a011a49b4331cdbee59629e44b80184bad4ea54ec887c0bfcd00cda8d5686060dbf365e3 unbundle-node.patch
|
||||||
07e9203b05402f81c0ded5871a845e37bdc4c09b7bb2839312396f298a9ce8196e2c24508675e3d6f695f1e2b0ff1c2c64f4e9dfff3ff5359a87cb7b9b972393 default.conf
|
e8ea87c547546011c4c8fc2de30e4f443b85cd4cfcff92808e2521d2f9ada03feefb8e1b0cf0f6b460919c146e56ef8d5ad4bb5e2461cc5247c30d92eb4d068e default.conf
|
||||||
191559fc7aa1ea0353c6fb0cc321ee1d5803a0e44848c8be941cfab96277b0de6a59962d373e2a2a1686c8f9be2bcf2d2f33706759a339a959e297d3f7fda463 electron.desktop
|
191559fc7aa1ea0353c6fb0cc321ee1d5803a0e44848c8be941cfab96277b0de6a59962d373e2a2a1686c8f9be2bcf2d2f33706759a339a959e297d3f7fda463 electron.desktop
|
||||||
ff1844036c8ae0a0a57a16211a816bc0ad550ccf6ea1cf718e228b8c95b9c4f5c9772d1a1a23638c0e140703a7b52874371e27a0d9d54a7b9468e5c384759be5 electron-launcher.sh
|
5f7ba5ad005f196facec1c0f26108356b64cafb1e5cfa462ff714a33b8a4c757ac00bfcb080da09eb5b65032f8eb245d9676a61ec554515d125ed63912708648 electron-launcher.sh
|
||||||
"
|
"
|
||||||
|
|
|
@ -1,20 +0,0 @@
|
||||||
See ICU change https://github.com/unicode-org/icu/commit/2e45e6ec0e84a1c01812015a254ea31b286316fb
|
|
||||||
|
|
||||||
Similar has happened in the past. See:
|
|
||||||
https://chromium.googlesource.com/chromium/src/+/e60b571faa3f14dd9119a6792dccf12f8bf80192
|
|
||||||
|
|
||||||
diff --git a/third_party/blink/renderer/platform/text/text_break_iterator.cc b/third_party/blink/renderer/platform/text/text_break_iterator.cc
|
|
||||||
index ddfbd51..247da06 100644
|
|
||||||
--- a/third_party/blink/renderer/platform/text/text_break_iterator.cc
|
|
||||||
+++ b/third_party/blink/renderer/platform/text/text_break_iterator.cc
|
|
||||||
@@ -161,7 +161,9 @@ static const unsigned char kAsciiLineBreakTable[][(kAsciiLineBreakTableLastChar
|
|
||||||
};
|
|
||||||
// clang-format on
|
|
||||||
|
|
||||||
-#if U_ICU_VERSION_MAJOR_NUM >= 58
|
|
||||||
+#if U_ICU_VERSION_MAJOR_NUM >= 74
|
|
||||||
+#define BA_LB_COUNT (U_LB_COUNT - 8)
|
|
||||||
+#elif U_ICU_VERSION_MAJOR_NUM >= 58
|
|
||||||
#define BA_LB_COUNT (U_LB_COUNT - 3)
|
|
||||||
#else
|
|
||||||
#define BA_LB_COUNT U_LB_COUNT
|
|
|
@ -1,30 +0,0 @@
|
||||||
building for arm targets by default passes --target to clang, because it
|
|
||||||
assumes it's cross compiling (so passes --target as if the host is different,
|
|
||||||
instead of assuming default)
|
|
||||||
|
|
||||||
probably also works: removing this entirely. but to be safe, pass the alpine clang host triple
|
|
||||||
--
|
|
||||||
--- a/build/config/compiler/BUILD.gn
|
|
||||||
+++ b/build/config/compiler/BUILD.gn
|
|
||||||
@@ -915,8 +915,8 @@ config("compiler_cpu_abi") {
|
|
||||||
} else if (current_cpu == "arm") {
|
|
||||||
if (is_clang && !is_android && !is_nacl &&
|
|
||||||
!(is_chromeos_lacros && is_chromeos_device)) {
|
|
||||||
- cflags += [ "--target=arm-linux-gnueabihf" ]
|
|
||||||
- ldflags += [ "--target=arm-linux-gnueabihf" ]
|
|
||||||
+ cflags += [ "--target=armv7-alpine-linux-musleabihf" ]
|
|
||||||
+ ldflags += [ "--target=armv7-alpine-linux-musleabihf" ]
|
|
||||||
}
|
|
||||||
if (!is_nacl) {
|
|
||||||
cflags += [
|
|
||||||
@@ -930,8 +930,8 @@ config("compiler_cpu_abi") {
|
|
||||||
} else if (current_cpu == "arm64") {
|
|
||||||
if (is_clang && !is_android && !is_nacl && !is_fuchsia &&
|
|
||||||
!(is_chromeos_lacros && is_chromeos_device)) {
|
|
||||||
- cflags += [ "--target=aarch64-linux-gnu" ]
|
|
||||||
- ldflags += [ "--target=aarch64-linux-gnu" ]
|
|
||||||
+ cflags += [ "--target=aarch64-alpine-linux-musl" ]
|
|
||||||
+ ldflags += [ "--target=aarch64-alpine-linux-musl" ]
|
|
||||||
}
|
|
||||||
if (is_android) {
|
|
||||||
# Outline atomics crash on Exynos 9810. http://crbug.com/1272795
|
|
132
backports/electron/compiler.patch
Normal file
132
backports/electron/compiler.patch
Normal file
|
@ -0,0 +1,132 @@
|
||||||
|
--- ./build/config/compiler/BUILD.gn.orig
|
||||||
|
+++ ./build/config/compiler/BUILD.gn
|
||||||
|
@@ -613,24 +613,6 @@
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
- # TODO(crbug.com/1488374): This causes binary size growth and potentially
|
||||||
|
- # other problems.
|
||||||
|
- # TODO(crbug.com/1491036): This isn't supported by Cronet's mainline llvm version.
|
||||||
|
- if (default_toolchain != "//build/toolchain/cros:target" &&
|
||||||
|
- !llvm_android_mainline) {
|
||||||
|
- cflags += [
|
||||||
|
- "-mllvm",
|
||||||
|
- "-split-threshold-for-reg-with-hint=0",
|
||||||
|
- ]
|
||||||
|
- if (use_thin_lto && is_a_target_toolchain) {
|
||||||
|
- if (is_win) {
|
||||||
|
- ldflags += [ "-mllvm:-split-threshold-for-reg-with-hint=0" ]
|
||||||
|
- } else {
|
||||||
|
- ldflags += [ "-Wl,-mllvm,-split-threshold-for-reg-with-hint=0" ]
|
||||||
|
- }
|
||||||
|
- }
|
||||||
|
- }
|
||||||
|
-
|
||||||
|
# TODO(crbug.com/1235145): Investigate why/if this should be needed.
|
||||||
|
if (is_win) {
|
||||||
|
cflags += [ "/clang:-ffp-contract=off" ]
|
||||||
|
@@ -1005,17 +987,6 @@
|
||||||
|
# `-nodefaultlibs` from the linker invocation from Rust, which would be used
|
||||||
|
# to compile dylibs on Android, such as for constructing unit test APKs.
|
||||||
|
"-Cdefault-linker-libraries",
|
||||||
|
-
|
||||||
|
- # To make Rust .d files compatible with ninja
|
||||||
|
- "-Zdep-info-omit-d-target",
|
||||||
|
-
|
||||||
|
- # If a macro panics during compilation, show which macro and where it is
|
||||||
|
- # defined.
|
||||||
|
- "-Zmacro-backtrace",
|
||||||
|
-
|
||||||
|
- # For deterministic builds, keep the local machine's current working
|
||||||
|
- # directory from appearing in build outputs.
|
||||||
|
- "-Zremap-cwd-prefix=.",
|
||||||
|
]
|
||||||
|
|
||||||
|
if (!is_win || force_rustc_color_output) {
|
||||||
|
@@ -1182,8 +1153,8 @@
|
||||||
|
} else if (current_cpu == "arm") {
|
||||||
|
if (is_clang && !is_android && !is_nacl &&
|
||||||
|
!(is_chromeos_lacros && is_chromeos_device)) {
|
||||||
|
- cflags += [ "--target=arm-linux-gnueabihf" ]
|
||||||
|
- ldflags += [ "--target=arm-linux-gnueabihf" ]
|
||||||
|
+ cflags += [ "--target=armv7-alpine-linux-musleabihf" ]
|
||||||
|
+ ldflags += [ "--target=armv7-alpine-linux-musleabihf" ]
|
||||||
|
}
|
||||||
|
if (!is_nacl) {
|
||||||
|
cflags += [
|
||||||
|
@@ -1197,8 +1168,8 @@
|
||||||
|
} else if (current_cpu == "arm64") {
|
||||||
|
if (is_clang && !is_android && !is_nacl && !is_fuchsia &&
|
||||||
|
!(is_chromeos_lacros && is_chromeos_device)) {
|
||||||
|
- cflags += [ "--target=aarch64-linux-gnu" ]
|
||||||
|
- ldflags += [ "--target=aarch64-linux-gnu" ]
|
||||||
|
+ cflags += [ "--target=aarch64-alpine-linux-musl" ]
|
||||||
|
+ ldflags += [ "--target=aarch64-alpine-linux-musl" ]
|
||||||
|
}
|
||||||
|
} else if (current_cpu == "mipsel" && !is_nacl) {
|
||||||
|
ldflags += [ "-Wl,--hash-style=sysv" ]
|
||||||
|
@@ -1983,7 +1954,7 @@
|
||||||
|
defines = [ "_HAS_NODISCARD" ]
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
- cflags = [ "-Wall" ]
|
||||||
|
+ cflags = []
|
||||||
|
if (is_clang) {
|
||||||
|
# Enable extra warnings for chromium_code when we control the compiler.
|
||||||
|
cflags += [ "-Wextra" ]
|
||||||
|
--- ./build/config/rust.gni.orig
|
||||||
|
+++ ./build/config/rust.gni
|
||||||
|
@@ -186,11 +186,11 @@
|
||||||
|
rust_abi_target = ""
|
||||||
|
if (is_linux || is_chromeos) {
|
||||||
|
if (current_cpu == "arm64") {
|
||||||
|
- rust_abi_target = "aarch64-unknown-linux-gnu"
|
||||||
|
+ rust_abi_target = "aarch64-alpine-linux-musl"
|
||||||
|
} else if (current_cpu == "x86") {
|
||||||
|
- rust_abi_target = "i686-unknown-linux-gnu"
|
||||||
|
+ rust_abi_target = "i586-alpine-linux-musl"
|
||||||
|
} else if (current_cpu == "x64") {
|
||||||
|
- rust_abi_target = "x86_64-unknown-linux-gnu"
|
||||||
|
+ rust_abi_target = "x86_64-alpine-linux-musl"
|
||||||
|
} else if (current_cpu == "arm") {
|
||||||
|
if (arm_float_abi == "hard") {
|
||||||
|
float_suffix = "hf"
|
||||||
|
@@ -199,13 +199,13 @@
|
||||||
|
}
|
||||||
|
if (arm_arch == "armv7-a" || arm_arch == "armv7") {
|
||||||
|
# No way to inform Rust about the -a suffix.
|
||||||
|
- rust_abi_target = "armv7-unknown-linux-gnueabi" + float_suffix
|
||||||
|
+ rust_abi_target = "armv7-alpine-linux-musleabi" + float_suffix
|
||||||
|
} else {
|
||||||
|
- rust_abi_target = "arm-unknown-linux-gnueabi" + float_suffix
|
||||||
|
+ rust_abi_target = "armv6-alpine-linux-musleabi" + float_suffix
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
# Best guess for other future platforms.
|
||||||
|
- rust_abi_target = current_cpu + "-unknown-linux-gnu"
|
||||||
|
+ rust_abi_target = current_cpu + "-alpine-linux-musl"
|
||||||
|
}
|
||||||
|
} else if (is_android) {
|
||||||
|
import("//build/config/android/abi.gni")
|
||||||
|
--- ./build/config/clang/BUILD.gn.orig
|
||||||
|
+++ ./build/config/clang/BUILD.gn
|
||||||
|
@@ -128,14 +128,15 @@
|
||||||
|
} else if (is_apple) {
|
||||||
|
_dir = "darwin"
|
||||||
|
} else if (is_linux || is_chromeos) {
|
||||||
|
+ _dir = "linux"
|
||||||
|
if (current_cpu == "x64") {
|
||||||
|
- _dir = "x86_64-unknown-linux-gnu"
|
||||||
|
+ _suffix = "-x86_64"
|
||||||
|
} else if (current_cpu == "x86") {
|
||||||
|
- _dir = "i386-unknown-linux-gnu"
|
||||||
|
+ _suffix = "-i386"
|
||||||
|
} else if (current_cpu == "arm") {
|
||||||
|
- _dir = "armv7-unknown-linux-gnueabihf"
|
||||||
|
+ _suffix = "-armhf"
|
||||||
|
} else if (current_cpu == "arm64") {
|
||||||
|
- _dir = "aarch64-unknown-linux-gnu"
|
||||||
|
+ _suffix = "-aarch64"
|
||||||
|
} else {
|
||||||
|
assert(false) # Unhandled cpu type
|
||||||
|
}
|
|
@ -1,372 +0,0 @@
|
||||||
From d0c1f5ee1f56c165bdf550c9e3be0d7313587b80 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Elly Fong-Jones <ellyjones@chromium.org>
|
|
||||||
Date: Wed, 18 Jan 2023 22:33:11 +0000
|
|
||||||
Subject: [PATCH] media: untangle MediaRouterUI lifetimes
|
|
||||||
|
|
||||||
Currently, MediaRouterUI is owned by MediaItemUIDeviceSelectorView.
|
|
||||||
There is an observer method named "OnControllerInvalidated" which
|
|
||||||
MediaItemUIDeviceSelectorView reacts to by deleting the MediaRouterUI it
|
|
||||||
owns. However, OnControllerInvalidated can actually be called in two
|
|
||||||
different situations:
|
|
||||||
|
|
||||||
* From MediaRouterUI::TakeMediaRouteStarter(), in which case the
|
|
||||||
MediaRouterUI object is *not* being destroyed, but should be, because
|
|
||||||
it can't be safely used after TakeMediaRouteStarter() ends;
|
|
||||||
* From MediaRouterUI::~MediaRouterUI(), in which case the MediaRouterUI
|
|
||||||
object *is* being destroyed already and should not be.
|
|
||||||
|
|
||||||
In the second case, only the fact that libc++ nulls out unique_ptr
|
|
||||||
before destroying the pointed-to object saves us from a use-after-free;
|
|
||||||
under libstdc++, we UaF immediately by re-entering the destructor. Even
|
|
||||||
under libc++ though this is still very dangerous, because any observers
|
|
||||||
that happened to be registered after MediaItemUIDeviceSelectorView will
|
|
||||||
be invoked after the destruction of the object they're observing. Right
|
|
||||||
now there are no such other observers, but the fact remains that this
|
|
||||||
interface is basically a UaF timebomb.
|
|
||||||
|
|
||||||
This change separates "this object is about to be destroyed" (an
|
|
||||||
observable state) from "please destroy this object, it is no longer
|
|
||||||
useful" (a callback that is made to the object's owner) by:
|
|
||||||
|
|
||||||
1. Renaming OnControllerInvalidated to OnControllerDestroying, to make
|
|
||||||
it very clear what is happening to the object, and
|
|
||||||
2. Adding a RegisterDestructor method to CastDialogController, which
|
|
||||||
allows MediaItemUIDeviceSelectorView to pass a callback into
|
|
||||||
MediaRouterUI which MediaRouterUI can use to arrange for its own
|
|
||||||
destruction.
|
|
||||||
|
|
||||||
This is still a bit tangled and ungainly, but it's safe. A fuller
|
|
||||||
writeup is on the linked bug.
|
|
||||||
|
|
||||||
Fixed: 1407202
|
|
||||||
Change-Id: Id9410de1fbf2cb42f13957dde316b7c9259f192f
|
|
||||||
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4165967
|
|
||||||
Reviewed-by: Peter Kasting <pkasting@chromium.org>
|
|
||||||
Reviewed-by: Takumi Fujimoto <takumif@chromium.org>
|
|
||||||
Commit-Queue: Elly Fong-Jones <ellyjones@chromium.org>
|
|
||||||
Cr-Commit-Position: refs/heads/main@{#1094110}
|
|
||||||
---
|
|
||||||
|
|
||||||
diff --git a/chrome/browser/ui/media_router/cast_dialog_controller.h b/chrome/browser/ui/media_router/cast_dialog_controller.h
|
|
||||||
index 2a8de976..c3c0553 100644
|
|
||||||
--- a/chrome/browser/ui/media_router/cast_dialog_controller.h
|
|
||||||
+++ b/chrome/browser/ui/media_router/cast_dialog_controller.h
|
|
||||||
@@ -24,10 +24,12 @@
|
|
||||||
public:
|
|
||||||
virtual ~Observer() = default;
|
|
||||||
|
|
||||||
- virtual void OnModelUpdated(const CastDialogModel& model) = 0;
|
|
||||||
+ virtual void OnModelUpdated(const CastDialogModel& model) {}
|
|
||||||
|
|
||||||
- // Observer should drop its reference to the controller when this is called.
|
|
||||||
- virtual void OnControllerInvalidated() = 0;
|
|
||||||
+ // Notifies observers that the observed object is being destroyed. Observers
|
|
||||||
+ // MUST NOT try to destroy the observed object in response - to manage the
|
|
||||||
+ // lifetime of a CastDialogController, use RegisterDestructor() below.
|
|
||||||
+ virtual void OnControllerDestroying() {}
|
|
||||||
};
|
|
||||||
|
|
||||||
virtual ~CastDialogController() = default;
|
|
||||||
@@ -55,6 +57,16 @@
|
|
||||||
// intended that this API should only be used to transfer ownership to some
|
|
||||||
// new component that will want to start casting on this dialog box's behalf.
|
|
||||||
virtual std::unique_ptr<MediaRouteStarter> TakeMediaRouteStarter() = 0;
|
|
||||||
+
|
|
||||||
+ // Registers a callback for when the CastDialogController has given up
|
|
||||||
+ // ownership of its MediaRouteStarter and is no longer safe to use. The
|
|
||||||
+ // provided closure must destroy |this| or otherwise ensure it is never used
|
|
||||||
+ // again. This method can only be called once.
|
|
||||||
+ //
|
|
||||||
+ // TODO(https://crbug.com/1408494): It's awkward that CastDialogController has
|
|
||||||
+ // a state where it exists but is unsafe to use, and doubly awkward that we
|
|
||||||
+ // have to paper over that with this callback. Can that be fixed?
|
|
||||||
+ virtual void RegisterDestructor(base::OnceClosure destructor) = 0;
|
|
||||||
};
|
|
||||||
|
|
||||||
} // namespace media_router
|
|
||||||
diff --git a/chrome/browser/ui/media_router/media_router_ui.cc b/chrome/browser/ui/media_router/media_router_ui.cc
|
|
||||||
index 1865115f..644d131 100644
|
|
||||||
--- a/chrome/browser/ui/media_router/media_router_ui.cc
|
|
||||||
+++ b/chrome/browser/ui/media_router/media_router_ui.cc
|
|
||||||
@@ -83,6 +83,9 @@
|
|
||||||
MediaRouterUI::~MediaRouterUI() {
|
|
||||||
if (media_route_starter_)
|
|
||||||
DetachFromMediaRouteStarter();
|
|
||||||
+ for (CastDialogController::Observer& observer : observers_) {
|
|
||||||
+ observer.OnControllerDestroying();
|
|
||||||
+ }
|
|
||||||
}
|
|
||||||
|
|
||||||
// static
|
|
||||||
@@ -145,9 +148,6 @@
|
|
||||||
}
|
|
||||||
|
|
||||||
void MediaRouterUI::DetachFromMediaRouteStarter() {
|
|
||||||
- for (CastDialogController::Observer& observer : observers_)
|
|
||||||
- observer.OnControllerInvalidated();
|
|
||||||
-
|
|
||||||
media_route_starter()->RemovePresentationRequestSourceObserver(this);
|
|
||||||
media_route_starter()->RemoveMediaSinkWithCastModesObserver(this);
|
|
||||||
}
|
|
||||||
@@ -181,8 +181,16 @@
|
|
||||||
|
|
||||||
std::unique_ptr<MediaRouteStarter> MediaRouterUI::TakeMediaRouteStarter() {
|
|
||||||
DCHECK(media_route_starter_) << "MediaRouteStarter already taken!";
|
|
||||||
- DetachFromMediaRouteStarter();
|
|
||||||
- return std::move(media_route_starter_);
|
|
||||||
+ auto starter = std::move(media_route_starter_);
|
|
||||||
+ if (destructor_) {
|
|
||||||
+ std::move(destructor_).Run(); // May destroy `this`.
|
|
||||||
+ }
|
|
||||||
+ return starter;
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
+void MediaRouterUI::RegisterDestructor(base::OnceClosure destructor) {
|
|
||||||
+ DCHECK(!destructor_);
|
|
||||||
+ destructor_ = std::move(destructor);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool MediaRouterUI::CreateRoute(const MediaSink::Id& sink_id,
|
|
||||||
diff --git a/chrome/browser/ui/media_router/media_router_ui.h b/chrome/browser/ui/media_router/media_router_ui.h
|
|
||||||
index 5c2f14e..7afe775 100644
|
|
||||||
--- a/chrome/browser/ui/media_router/media_router_ui.h
|
|
||||||
+++ b/chrome/browser/ui/media_router/media_router_ui.h
|
|
||||||
@@ -100,8 +100,10 @@
|
|
||||||
void StopCasting(const std::string& route_id) override;
|
|
||||||
void ClearIssue(const Issue::Id& issue_id) override;
|
|
||||||
// Note that |MediaRouterUI| should not be used after |TakeMediaRouteStarter|
|
|
||||||
- // is called.
|
|
||||||
+ // is called. To enforce that, |TakeMediaRouteStarter| calls the destructor
|
|
||||||
+ // callback given to |RegisterDestructor| to destroy itself.
|
|
||||||
std::unique_ptr<MediaRouteStarter> TakeMediaRouteStarter() override;
|
|
||||||
+ void RegisterDestructor(base::OnceClosure destructor) override;
|
|
||||||
|
|
||||||
// Requests a route be created from the source mapped to
|
|
||||||
// |cast_mode|, to the sink given by |sink_id|.
|
|
||||||
@@ -337,6 +339,8 @@
|
|
||||||
raw_ptr<MediaRouter> router_;
|
|
||||||
raw_ptr<LoggerImpl> logger_;
|
|
||||||
|
|
||||||
+ base::OnceClosure destructor_;
|
|
||||||
+
|
|
||||||
// NOTE: Weak pointers must be invalidated before all other member variables.
|
|
||||||
// Therefore |weak_factory_| must be placed at the end.
|
|
||||||
base::WeakPtrFactory<MediaRouterUI> weak_factory_{this};
|
|
||||||
diff --git a/chrome/browser/ui/media_router/media_router_ui_unittest.cc b/chrome/browser/ui/media_router/media_router_ui_unittest.cc
|
|
||||||
index 2cc243d1..c33437b 100644
|
|
||||||
--- a/chrome/browser/ui/media_router/media_router_ui_unittest.cc
|
|
||||||
+++ b/chrome/browser/ui/media_router/media_router_ui_unittest.cc
|
|
||||||
@@ -80,11 +80,11 @@
|
|
||||||
}
|
|
||||||
|
|
||||||
MOCK_METHOD1(OnModelUpdated, void(const CastDialogModel& model));
|
|
||||||
- void OnControllerInvalidated() override {
|
|
||||||
+ void OnControllerDestroying() override {
|
|
||||||
controller_ = nullptr;
|
|
||||||
- OnControllerInvalidatedInternal();
|
|
||||||
+ OnControllerDestroyingInternal();
|
|
||||||
}
|
|
||||||
- MOCK_METHOD0(OnControllerInvalidatedInternal, void());
|
|
||||||
+ MOCK_METHOD0(OnControllerDestroyingInternal, void());
|
|
||||||
|
|
||||||
private:
|
|
||||||
raw_ptr<CastDialogController> controller_ = nullptr;
|
|
||||||
@@ -295,7 +295,7 @@
|
|
||||||
})));
|
|
||||||
NotifyUiOnRoutesUpdated({route});
|
|
||||||
|
|
||||||
- EXPECT_CALL(observer, OnControllerInvalidatedInternal());
|
|
||||||
+ EXPECT_CALL(observer, OnControllerDestroyingInternal());
|
|
||||||
ui_.reset();
|
|
||||||
}
|
|
||||||
|
|
||||||
diff --git a/chrome/browser/ui/views/global_media_controls/media_item_ui_device_selector_view.cc b/chrome/browser/ui/views/global_media_controls/media_item_ui_device_selector_view.cc
|
|
||||||
index 34dad46..d843bba 100644
|
|
||||||
--- a/chrome/browser/ui/views/global_media_controls/media_item_ui_device_selector_view.cc
|
|
||||||
+++ b/chrome/browser/ui/views/global_media_controls/media_item_ui_device_selector_view.cc
|
|
||||||
@@ -222,6 +222,11 @@
|
|
||||||
if (cast_controller) {
|
|
||||||
cast_controller_ = std::move(cast_controller);
|
|
||||||
cast_controller_->AddObserver(this);
|
|
||||||
+ cast_controller_->RegisterDestructor(
|
|
||||||
+ base::BindOnce(&MediaItemUIDeviceSelectorView::DestroyCastController,
|
|
||||||
+ // Unretained is safe: this callback is held by
|
|
||||||
+ // cast_controller_, which is owned by this object.
|
|
||||||
+ base::Unretained(this)));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -499,10 +504,6 @@
|
|
||||||
observer.OnMediaItemUIDeviceSelectorUpdated(device_entry_ui_map_);
|
|
||||||
}
|
|
||||||
|
|
||||||
-void MediaItemUIDeviceSelectorView::OnControllerInvalidated() {
|
|
||||||
- cast_controller_.reset();
|
|
||||||
-}
|
|
||||||
-
|
|
||||||
void MediaItemUIDeviceSelectorView::OnDeviceSelected(int tag) {
|
|
||||||
auto it = device_entry_ui_map_.find(tag);
|
|
||||||
DCHECK(it != device_entry_ui_map_.end());
|
|
||||||
@@ -658,5 +659,9 @@
|
|
||||||
weak_ptr_factory_.GetWeakPtr()));
|
|
||||||
}
|
|
||||||
|
|
||||||
+void MediaItemUIDeviceSelectorView::DestroyCastController() {
|
|
||||||
+ cast_controller_.reset();
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
BEGIN_METADATA(MediaItemUIDeviceSelectorView, views::View)
|
|
||||||
END_METADATA
|
|
||||||
diff --git a/chrome/browser/ui/views/global_media_controls/media_item_ui_device_selector_view.h b/chrome/browser/ui/views/global_media_controls/media_item_ui_device_selector_view.h
|
|
||||||
index e950565..222fc20 100644
|
|
||||||
--- a/chrome/browser/ui/views/global_media_controls/media_item_ui_device_selector_view.h
|
|
||||||
+++ b/chrome/browser/ui/views/global_media_controls/media_item_ui_device_selector_view.h
|
|
||||||
@@ -81,7 +81,6 @@
|
|
||||||
|
|
||||||
// media_router::CastDialogController::Observer
|
|
||||||
void OnModelUpdated(const media_router::CastDialogModel& model) override;
|
|
||||||
- void OnControllerInvalidated() override;
|
|
||||||
|
|
||||||
// MediaItemUIFooterView::Delegate
|
|
||||||
void OnDeviceSelected(int tag) override;
|
|
||||||
@@ -121,6 +120,7 @@
|
|
||||||
void RecordCastDeviceCount();
|
|
||||||
DeviceEntryUI* GetDeviceEntryUI(views::View* view) const;
|
|
||||||
void RegisterAudioDeviceCallbacks();
|
|
||||||
+ void DestroyCastController();
|
|
||||||
|
|
||||||
bool has_expand_button_been_shown_ = false;
|
|
||||||
bool have_devices_been_shown_ = false;
|
|
||||||
diff --git a/chrome/browser/ui/views/global_media_controls/media_item_ui_device_selector_view_unittest.cc b/chrome/browser/ui/views/global_media_controls/media_item_ui_device_selector_view_unittest.cc
|
|
||||||
index c3bcc6cc..6ae3dde8 100644
|
|
||||||
--- a/chrome/browser/ui/views/global_media_controls/media_item_ui_device_selector_view_unittest.cc
|
|
||||||
+++ b/chrome/browser/ui/views/global_media_controls/media_item_ui_device_selector_view_unittest.cc
|
|
||||||
@@ -156,6 +156,7 @@
|
|
||||||
MOCK_METHOD1(ClearIssue, void(const media_router::Issue::Id& issue_id));
|
|
||||||
MOCK_METHOD0(TakeMediaRouteStarter,
|
|
||||||
std::unique_ptr<media_router::MediaRouteStarter>());
|
|
||||||
+ MOCK_METHOD1(RegisterDestructor, void(base::OnceClosure));
|
|
||||||
};
|
|
||||||
|
|
||||||
} // anonymous namespace
|
|
||||||
diff --git a/chrome/browser/ui/views/media_router/cast_dialog_coordinator_unittest.cc b/chrome/browser/ui/views/media_router/cast_dialog_coordinator_unittest.cc
|
|
||||||
index f6c80d6a..2dedc7e 100644
|
|
||||||
--- a/chrome/browser/ui/views/media_router/cast_dialog_coordinator_unittest.cc
|
|
||||||
+++ b/chrome/browser/ui/views/media_router/cast_dialog_coordinator_unittest.cc
|
|
||||||
@@ -40,6 +40,7 @@
|
|
||||||
MOCK_METHOD(void, StopCasting, (const std::string& route_id));
|
|
||||||
MOCK_METHOD(void, ClearIssue, (const Issue::Id& issue_id));
|
|
||||||
MOCK_METHOD(std::unique_ptr<MediaRouteStarter>, TakeMediaRouteStarter, ());
|
|
||||||
+ MOCK_METHOD(void, RegisterDestructor, (base::OnceClosure));
|
|
||||||
};
|
|
||||||
|
|
||||||
class CastDialogCoordinatorTest : public TestWithBrowserView {
|
|
||||||
diff --git a/chrome/browser/ui/views/media_router/cast_dialog_view.cc b/chrome/browser/ui/views/media_router/cast_dialog_view.cc
|
|
||||||
index e3c7dadb..711d081 100644
|
|
||||||
--- a/chrome/browser/ui/views/media_router/cast_dialog_view.cc
|
|
||||||
+++ b/chrome/browser/ui/views/media_router/cast_dialog_view.cc
|
|
||||||
@@ -125,9 +125,9 @@
|
|
||||||
observer.OnDialogModelUpdated(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
-void CastDialogView::OnControllerInvalidated() {
|
|
||||||
+void CastDialogView::OnControllerDestroying() {
|
|
||||||
controller_ = nullptr;
|
|
||||||
- // We don't destroy the dialog here because if the invalidation was caused by
|
|
||||||
+ // We don't destroy the dialog here because if the destruction was caused by
|
|
||||||
// activating the toolbar icon in order to close the dialog, then it would
|
|
||||||
// cause the dialog to immediately open again.
|
|
||||||
}
|
|
||||||
diff --git a/chrome/browser/ui/views/media_router/cast_dialog_view.h b/chrome/browser/ui/views/media_router/cast_dialog_view.h
|
|
||||||
index d87fdda..d44d4e0 100644
|
|
||||||
--- a/chrome/browser/ui/views/media_router/cast_dialog_view.h
|
|
||||||
+++ b/chrome/browser/ui/views/media_router/cast_dialog_view.h
|
|
||||||
@@ -66,7 +66,7 @@
|
|
||||||
|
|
||||||
// CastDialogController::Observer:
|
|
||||||
void OnModelUpdated(const CastDialogModel& model) override;
|
|
||||||
- void OnControllerInvalidated() override;
|
|
||||||
+ void OnControllerDestroying() override;
|
|
||||||
|
|
||||||
// views::BubbleDialogDelegateView:
|
|
||||||
void OnPaint(gfx::Canvas* canvas) override;
|
|
||||||
diff --git a/chrome/browser/ui/views/media_router/cast_dialog_view_browsertest.cc b/chrome/browser/ui/views/media_router/cast_dialog_view_browsertest.cc
|
|
||||||
index 1c584120..a7af3c8 100644
|
|
||||||
--- a/chrome/browser/ui/views/media_router/cast_dialog_view_browsertest.cc
|
|
||||||
+++ b/chrome/browser/ui/views/media_router/cast_dialog_view_browsertest.cc
|
|
||||||
@@ -70,6 +70,7 @@
|
|
||||||
override {
|
|
||||||
return nullptr;
|
|
||||||
}
|
|
||||||
+ void RegisterDestructor(base::OnceClosure destructor) override {}
|
|
||||||
};
|
|
||||||
|
|
||||||
} // namespace
|
|
||||||
diff --git a/chrome/browser/ui/views/media_router/cast_dialog_view_unittest.cc b/chrome/browser/ui/views/media_router/cast_dialog_view_unittest.cc
|
|
||||||
index 5326467..988cb07a 100644
|
|
||||||
--- a/chrome/browser/ui/views/media_router/cast_dialog_view_unittest.cc
|
|
||||||
+++ b/chrome/browser/ui/views/media_router/cast_dialog_view_unittest.cc
|
|
||||||
@@ -91,6 +91,7 @@
|
|
||||||
MOCK_METHOD1(StopCasting, void(const std::string& route_id));
|
|
||||||
MOCK_METHOD1(ClearIssue, void(const Issue::Id& issue_id));
|
|
||||||
MOCK_METHOD0(TakeMediaRouteStarter, std::unique_ptr<MediaRouteStarter>());
|
|
||||||
+ MOCK_METHOD1(RegisterDestructor, void(base::OnceClosure));
|
|
||||||
};
|
|
||||||
|
|
||||||
class CastDialogViewTest : public ChromeViewsTestBase {
|
|
||||||
diff --git a/chrome/browser/ui/views/media_router/media_router_dialog_controller_views.cc b/chrome/browser/ui/views/media_router/media_router_dialog_controller_views.cc
|
|
||||||
index ad379b2..244d523 100644
|
|
||||||
--- a/chrome/browser/ui/views/media_router/media_router_dialog_controller_views.cc
|
|
||||||
+++ b/chrome/browser/ui/views/media_router/media_router_dialog_controller_views.cc
|
|
||||||
@@ -51,7 +51,7 @@
|
|
||||||
std::move(context));
|
|
||||||
}
|
|
||||||
|
|
||||||
- ShowGlobalMeidaControlsDialog(std::move(context));
|
|
||||||
+ ShowGlobalMediaControlsDialog(std::move(context));
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -155,9 +155,20 @@
|
|
||||||
initiator(), std::move(start_presentation_context_))
|
|
||||||
: MediaRouterUI::CreateWithDefaultMediaSourceAndMirroring(
|
|
||||||
initiator());
|
|
||||||
+ ui_->RegisterDestructor(
|
|
||||||
+ base::BindOnce(&MediaRouterDialogControllerViews::DestroyMediaRouterUI,
|
|
||||||
+ // Safe to use base::Unretained here: the callback being
|
|
||||||
+ // bound is held by the MediaRouterUI we are creating and
|
|
||||||
+ // owning, and ownership of |ui_| is never transferred
|
|
||||||
+ // away from this object.
|
|
||||||
+ base::Unretained(this)));
|
|
||||||
}
|
|
||||||
|
|
||||||
-void MediaRouterDialogControllerViews::ShowGlobalMeidaControlsDialog(
|
|
||||||
+void MediaRouterDialogControllerViews::DestroyMediaRouterUI() {
|
|
||||||
+ ui_.reset();
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
+void MediaRouterDialogControllerViews::ShowGlobalMediaControlsDialog(
|
|
||||||
std::unique_ptr<StartPresentationContext> context) {
|
|
||||||
// Show the WebContents requesting a dialog.
|
|
||||||
initiator()->GetDelegate()->ActivateContents(initiator());
|
|
||||||
diff --git a/chrome/browser/ui/views/media_router/media_router_dialog_controller_views.h b/chrome/browser/ui/views/media_router/media_router_dialog_controller_views.h
|
|
||||||
index 0a5fdb1..7c97211 100644
|
|
||||||
--- a/chrome/browser/ui/views/media_router/media_router_dialog_controller_views.h
|
|
||||||
+++ b/chrome/browser/ui/views/media_router/media_router_dialog_controller_views.h
|
|
||||||
@@ -69,13 +69,14 @@
|
|
||||||
// MediaRouterUIService::Observer:
|
|
||||||
void OnServiceDisabled() override;
|
|
||||||
|
|
||||||
- // Initializes |ui_|.
|
|
||||||
+ // Initializes and destroys |ui_| respectively.
|
|
||||||
void InitializeMediaRouterUI();
|
|
||||||
+ void DestroyMediaRouterUI();
|
|
||||||
|
|
||||||
// If there exists a media button, show the GMC dialog anchored to the media
|
|
||||||
// button. Otherwise, show the dialog anchored to the top center of the web
|
|
||||||
// contents.
|
|
||||||
- void ShowGlobalMeidaControlsDialog(
|
|
||||||
+ void ShowGlobalMediaControlsDialog(
|
|
||||||
std::unique_ptr<StartPresentationContext> context);
|
|
||||||
|
|
||||||
// Returns the media button from the browser that initiates the request to
|
|
|
@ -2,4 +2,8 @@
|
||||||
# the electron launcher.
|
# the electron launcher.
|
||||||
|
|
||||||
# Options to pass to electron.
|
# Options to pass to electron.
|
||||||
ELECTRON_FLAGS="--ozone-platform-hint=auto --enable-features=WebRTCPipeWireCapturer"
|
ELECTRON_FLAGS="--enable-features=WebRTCPipeWireCapturer"
|
||||||
|
|
||||||
|
# This can be 'x11', 'wayland', or 'auto'. Overriding default to 'auto',
|
||||||
|
# but respecting the variable content if any
|
||||||
|
ELECTRON_OZONE_PLATFORM_HINT="${ELECTRON_OZONE_PLATFORM_HINT:-auto}"
|
||||||
|
|
15
backports/electron/disable-dns_config_service.patch
Normal file
15
backports/electron/disable-dns_config_service.patch
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
diff --git a/net/dns/BUILD.gn b/net/dns/BUILD.gn
|
||||||
|
index f36bf68..805d9a6 100644
|
||||||
|
--- a/net/dns/BUILD.gn
|
||||||
|
+++ b/net/dns/BUILD.gn
|
||||||
|
@@ -130,8 +130,8 @@ source_set("dns") {
|
||||||
|
]
|
||||||
|
} else if (is_linux) {
|
||||||
|
sources += [
|
||||||
|
- "dns_config_service_linux.cc",
|
||||||
|
- "dns_config_service_linux.h",
|
||||||
|
+ "dns_config_service_fuchsia.cc",
|
||||||
|
+ "dns_config_service_fuchsia.h",
|
||||||
|
]
|
||||||
|
} else if (is_posix) {
|
||||||
|
sources += [
|
361
backports/electron/disable-failing-tests.patch
Normal file
361
backports/electron/disable-failing-tests.patch
Normal file
|
@ -0,0 +1,361 @@
|
||||||
|
safesprintf emitnull:
|
||||||
|
error: conversion from 'std::nullptr_t' to 'const internal::Arg' is ambiguous
|
||||||
|
const internal::Arg arg_array[] = { args... };
|
||||||
|
|
||||||
|
flatmap incompletetype:
|
||||||
|
error: static assertion failed due to requirement 'std::__is_complete_or_unbounded(std::__type_identity<std::pair<A, A>>{})': template argument must be a complete class or an unbounded array
|
||||||
|
static_assert(std::__is_complete_or_unbounded(__type_identity<_Tp>{}),
|
||||||
|
|
||||||
|
i18n, time:
|
||||||
|
various icu failures (new icu time formatting? internal api difference?)
|
||||||
|
a ton of these fail:
|
||||||
|
|
||||||
|
Expected equality of these values:
|
||||||
|
u"Monday 16 May – Saturday 28 May"
|
||||||
|
Which is: u"Monday 16 May \x2013 Saturday 28 May"
|
||||||
|
DateIntervalFormat(begin_time, end_time, DATE_FORMAT_MONTH_WEEKDAY_DAY)
|
||||||
|
Which is: u"Monday 16\x2009\x2013\x2009Saturday 28 May"
|
||||||
|
|
||||||
|
../../base/i18n/time_formatting_unittest.cc:84: Failure
|
||||||
|
Expected equality of these values:
|
||||||
|
clock12h_pm
|
||||||
|
Which is: u"3:42 PM"
|
||||||
|
TimeFormatTimeOfDay(time)
|
||||||
|
Which is: u"3:42\x202FPM"
|
||||||
|
|
||||||
|
.. and so on
|
||||||
|
|
||||||
|
fileutiltest filetofile:
|
||||||
|
../../base/files/file_util_unittest.cc:2692: Failure
|
||||||
|
Value of: stream
|
||||||
|
Actual: true
|
||||||
|
Expected: false
|
||||||
|
|
||||||
|
stacktracetest: crashes (this doesn't seem to use execinfo so probably relies on glibc internal layout for tracing here)
|
||||||
|
|
||||||
|
platformthreadtest canchangethreadtype:
|
||||||
|
../../base/threading/platform_thread_unittest.cc:445: Failure
|
||||||
|
Expected equality of these values:
|
||||||
|
PlatformThread::CanChangeThreadType(ThreadType::kBackground, ThreadType::kResourceEfficient)
|
||||||
|
Which is: true
|
||||||
|
kCanIncreasePriority
|
||||||
|
Which is: false
|
||||||
|
|
||||||
|
scopedfdownershiptrackingtest crashonunownedclose: fails due to scoped-file-no-close.patch
|
||||||
|
|
||||||
|
stackcontainer customallocator:
|
||||||
|
../../base/containers/stack_container_unittest.cc:211: Failure
|
||||||
|
Expected equality of these values:
|
||||||
|
1
|
||||||
|
Allocator::deallocated
|
||||||
|
Which is: 0
|
||||||
|
|
||||||
|
nativelibrarytest loadlibrarypreferownsymbols: crashes (probably musl dlopen does not play nice here)
|
||||||
|
|
||||||
|
spantest empty: crashes (this looks fishy)
|
||||||
|
|
||||||
|
readelfbuildid: crashes (this looks like glibc dynamic linker semantics)
|
||||||
|
|
||||||
|
nss db unittest: various nss failures: e.g.:
|
||||||
|
../../net/cert/nss_cert_database_unittest.cc:209: Failure
|
||||||
|
Expected equality of these values:
|
||||||
|
OK
|
||||||
|
Which is: 0
|
||||||
|
cert_db_->ImportFromPKCS12(GetPublicSlot(), pkcs12_data, u"12345", true, nullptr)
|
||||||
|
Which is: -702
|
||||||
|
|
||||||
|
processutiltest cloneflags: fails in CI (ulimit? too many threads?)
|
||||||
|
../../base/process/process_util_unittest.cc:1434: Failure
|
||||||
|
Value of: process.IsValid()
|
||||||
|
Actual: false
|
||||||
|
Expected: true
|
||||||
|
|
||||||
|
addresstrackerlinuxnetlinktest:
|
||||||
|
../../net/base/address_tracker_linux_unittest.cc:886: Failure
|
||||||
|
Value of: child.process.IsValid()
|
||||||
|
Actual: false
|
||||||
|
Expected: true
|
||||||
|
|
||||||
|
ToAddressDoesNotDereference: ; Expected `get_for_extraction_cnt` to be 1 but got 0;
|
||||||
|
|
||||||
|
DataCapturedManyThreads: flaky
|
||||||
|
|
||||||
|
ProcessAlternativeServicesTest.Process*: crashed ?
|
||||||
|
|
||||||
|
--- a/base/strings/safe_sprintf_unittest.cc
|
||||||
|
+++ b/base/strings/safe_sprintf_unittest.cc
|
||||||
|
@@ -740,6 +740,7 @@
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
+#if 0
|
||||||
|
TEST(SafeSPrintfTest, EmitNULL) {
|
||||||
|
char buf[40];
|
||||||
|
#if defined(__GNUC__)
|
||||||
|
@@ -756,6 +757,7 @@
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
TEST(SafeSPrintfTest, PointerSize) {
|
||||||
|
// The internal data representation is a 64bit value, independent of the
|
||||||
|
--- a/base/containers/flat_map_unittest.cc
|
||||||
|
+++ b/base/containers/flat_map_unittest.cc
|
||||||
|
@@ -52,6 +52,7 @@
|
||||||
|
|
||||||
|
} // namespace
|
||||||
|
|
||||||
|
+#if 0
|
||||||
|
TEST(FlatMap, IncompleteType) {
|
||||||
|
struct A {
|
||||||
|
using Map = flat_map<A, A>;
|
||||||
|
@@ -65,6 +66,7 @@
|
||||||
|
|
||||||
|
A a;
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
TEST(FlatMap, RangeConstructor) {
|
||||||
|
flat_map<int, int>::value_type input_vals[] = {
|
||||||
|
--- a/base/BUILD.gn
|
||||||
|
+++ b/base/BUILD.gn
|
||||||
|
@@ -3194,21 +3194,6 @@
|
||||||
|
"hash/md5_constexpr_unittest.cc",
|
||||||
|
"hash/md5_unittest.cc",
|
||||||
|
"hash/sha1_unittest.cc",
|
||||||
|
- "i18n/break_iterator_unittest.cc",
|
||||||
|
- "i18n/case_conversion_unittest.cc",
|
||||||
|
- "i18n/char_iterator_unittest.cc",
|
||||||
|
- "i18n/character_encoding_unittest.cc",
|
||||||
|
- "i18n/file_util_icu_unittest.cc",
|
||||||
|
- "i18n/icu_string_conversions_unittest.cc",
|
||||||
|
- "i18n/icu_util_unittest.cc",
|
||||||
|
- "i18n/message_formatter_unittest.cc",
|
||||||
|
- "i18n/number_formatting_unittest.cc",
|
||||||
|
- "i18n/rtl_unittest.cc",
|
||||||
|
- "i18n/streaming_utf8_validator_unittest.cc",
|
||||||
|
- "i18n/string_search_unittest.cc",
|
||||||
|
- "i18n/time_formatting_unittest.cc",
|
||||||
|
- "i18n/timezone_unittest.cc",
|
||||||
|
- "i18n/transliterator_unittest.cc",
|
||||||
|
"immediate_crash_unittest.cc",
|
||||||
|
"json/json_parser_unittest.cc",
|
||||||
|
"json/json_reader_unittest.cc",
|
||||||
|
--- a/base/files/file_util_unittest.cc
|
||||||
|
+++ b/base/files/file_util_unittest.cc
|
||||||
|
@@ -2686,6 +2686,7 @@
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
+#if 0
|
||||||
|
TEST_F(FileUtilTest, FileToFILE) {
|
||||||
|
File file;
|
||||||
|
FILE* stream = FileToFILE(std::move(file), "w");
|
||||||
|
@@ -2700,6 +2701,7 @@
|
||||||
|
EXPECT_FALSE(file.IsValid());
|
||||||
|
EXPECT_TRUE(CloseFile(stream));
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
TEST_F(FileUtilTest, FILEToFile) {
|
||||||
|
ScopedFILE stream;
|
||||||
|
--- a/base/debug/stack_trace_unittest.cc
|
||||||
|
+++ b/base/debug/stack_trace_unittest.cc
|
||||||
|
@@ -345,6 +345,7 @@
|
||||||
|
// sometimes we read fp / pc from the place that previously held
|
||||||
|
// uninitialized value.
|
||||||
|
// TODO(crbug.com/1132511): Enable this test on Fuchsia.
|
||||||
|
+#if 0
|
||||||
|
#if defined(MEMORY_SANITIZER) || BUILDFLAG(IS_FUCHSIA)
|
||||||
|
#define MAYBE_TraceStackFramePointersFromBuffer \
|
||||||
|
DISABLED_TraceStackFramePointersFromBuffer
|
||||||
|
@@ -357,6 +358,7 @@
|
||||||
|
const void* frames[kDepth];
|
||||||
|
ExpectStackFramePointers<kDepth>(frames, kDepth, /*copy_stack=*/true);
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_APPLE)
|
||||||
|
#define MAYBE_StackEnd StackEnd
|
||||||
|
--- a/base/threading/platform_thread_unittest.cc
|
||||||
|
+++ b/base/threading/platform_thread_unittest.cc
|
||||||
|
@@ -416,6 +416,7 @@
|
||||||
|
// platforms for all priorities. This not being the case. This test documents
|
||||||
|
// and hardcodes what we know. Please inform scheduler-dev@chromium.org if this
|
||||||
|
// proprerty changes for a given platform.
|
||||||
|
+#if 0
|
||||||
|
TEST(PlatformThreadTest, CanChangeThreadType) {
|
||||||
|
#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)
|
||||||
|
// On Ubuntu, RLIMIT_NICE and RLIMIT_RTPRIO are 0 by default, so we won't be
|
||||||
|
@@ -472,6 +473,7 @@
|
||||||
|
ThreadType::kBackground));
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
TEST(PlatformThreadTest, SetCurrentThreadTypeTest) {
|
||||||
|
TestPriorityResultingFromThreadType(ThreadType::kBackground,
|
||||||
|
--- a/base/files/scoped_file_linux_unittest.cc
|
||||||
|
+++ b/base/files/scoped_file_linux_unittest.cc
|
||||||
|
@@ -42,11 +42,13 @@
|
||||||
|
EXPECT_DEATH(ScopedFD(fd.get()), "");
|
||||||
|
}
|
||||||
|
|
||||||
|
+#if 0
|
||||||
|
TEST_F(ScopedFDOwnershipTrackingTest, CrashOnUnownedClose) {
|
||||||
|
ScopedFD fd = OpenFD();
|
||||||
|
subtle::EnableFDOwnershipEnforcement(true);
|
||||||
|
EXPECT_DEATH(close(fd.get()), "");
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
#endif // defined(GTEST_HAS_DEATH_TEST)
|
||||||
|
|
||||||
|
--- a/base/native_library_unittest.cc
|
||||||
|
+++ b/base/native_library_unittest.cc
|
||||||
|
@@ -139,6 +139,7 @@
|
||||||
|
// Verifies that the |prefer_own_symbols| option satisfies its guarantee that
|
||||||
|
// a loaded library will always prefer local symbol resolution before
|
||||||
|
// considering global symbols.
|
||||||
|
+#if 0
|
||||||
|
TEST(NativeLibraryTest, LoadLibraryPreferOwnSymbols) {
|
||||||
|
NativeLibraryOptions options;
|
||||||
|
options.prefer_own_symbols = true;
|
||||||
|
@@ -171,6 +172,7 @@
|
||||||
|
EXPECT_EQ(2, NativeLibraryTestIncrement());
|
||||||
|
EXPECT_EQ(3, NativeLibraryTestIncrement());
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
#endif // !BUILDFLAG(IS_ANDROID) && !defined(THREAD_SANITIZER) && \
|
||||||
|
// !defined(MEMORY_SANITIZER)
|
||||||
|
--- a/base/containers/span_unittest.cc
|
||||||
|
+++ b/base/containers/span_unittest.cc
|
||||||
|
@@ -995,6 +995,7 @@
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
+#if 0
|
||||||
|
TEST(SpanTest, Empty) {
|
||||||
|
{
|
||||||
|
span<int> span;
|
||||||
|
@@ -1014,6 +1015,7 @@
|
||||||
|
EXPECT_TRUE(span_of_checked_iterators.empty());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
TEST(SpanTest, OperatorAt) {
|
||||||
|
static constexpr int kArray[] = {1, 6, 1, 8, 0};
|
||||||
|
--- a/base/debug/elf_reader_unittest.cc
|
||||||
|
+++ b/base/debug/elf_reader_unittest.cc
|
||||||
|
@@ -194,6 +194,7 @@
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
+#if 0
|
||||||
|
TEST(ElfReaderTestWithCurrentImage, ReadElfBuildId) {
|
||||||
|
#if BUILDFLAG(IS_ANDROID)
|
||||||
|
// On Android the library loader memory maps the full so file.
|
||||||
|
@@ -229,6 +230,7 @@
|
||||||
|
UnloadNativeLibrary(library);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
} // namespace debug
|
||||||
|
} // namespace base
|
||||||
|
--- a/net/BUILD.gn
|
||||||
|
+++ b/net/BUILD.gn
|
||||||
|
@@ -4826,7 +4826,6 @@
|
||||||
|
sources += [
|
||||||
|
"cert/internal/system_trust_store_nss_unittest.cc",
|
||||||
|
"cert/internal/trust_store_nss_unittest.cc",
|
||||||
|
- "cert/nss_cert_database_unittest.cc",
|
||||||
|
"cert/x509_util_nss_unittest.cc",
|
||||||
|
]
|
||||||
|
if (!is_castos) {
|
||||||
|
--- a/base/process/process_util_unittest.cc
|
||||||
|
+++ b/base/process/process_util_unittest.cc
|
||||||
|
@@ -1419,7 +1419,7 @@
|
||||||
|
return kSuccess;
|
||||||
|
}
|
||||||
|
|
||||||
|
-#if defined(CLONE_NEWUSER) && defined(CLONE_NEWPID)
|
||||||
|
+#if 0 && defined(CLONE_NEWUSER) && defined(CLONE_NEWPID)
|
||||||
|
TEST_F(ProcessUtilTest, CloneFlags) {
|
||||||
|
if (!PathExists(FilePath("/proc/self/ns/user")) ||
|
||||||
|
!PathExists(FilePath("/proc/self/ns/pid"))) {
|
||||||
|
--- a/net/base/address_tracker_linux_unittest.cc
|
||||||
|
+++ b/net/base/address_tracker_linux_unittest.cc
|
||||||
|
@@ -831,6 +831,7 @@
|
||||||
|
//
|
||||||
|
// This test creates multiple concurrent `AddressTrackerLinux` instances in
|
||||||
|
// separate processes, each in their own PID namespaces.
|
||||||
|
+#if 0
|
||||||
|
TEST(AddressTrackerLinuxNetlinkTest, TestInitializeTwoTrackersInPidNamespaces) {
|
||||||
|
// This test initializes `kNumChildren` instances of `AddressTrackerLinux` in
|
||||||
|
// tracking mode, each in their own child process running in a PID namespace.
|
||||||
|
@@ -901,6 +902,7 @@
|
||||||
|
ASSERT_EQ(exit_code, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
MULTIPROCESS_TEST_MAIN(ChildProcessInitializeTrackerForTesting) {
|
||||||
|
base::test::TaskEnvironment task_env(
|
||||||
|
--- a/base/trace_event/trace_event_unittest.cc
|
||||||
|
+++ b/base/trace_event/trace_event_unittest.cc
|
||||||
|
@@ -1368,6 +1368,7 @@
|
||||||
|
}
|
||||||
|
|
||||||
|
// Test that data sent from multiple threads is gathered
|
||||||
|
+#if 0
|
||||||
|
TEST_F(TraceEventTestFixture, DataCapturedManyThreads) {
|
||||||
|
BeginTrace();
|
||||||
|
|
||||||
|
@@ -1408,6 +1409,7 @@
|
||||||
|
delete task_complete_events[i];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
// Test that thread and process names show up in the trace.
|
||||||
|
// In SDK build, thread names are not tracked inside //base. Instead, there's
|
||||||
|
--- a/base/allocator/partition_allocator/src/partition_alloc/pointers/raw_ptr_unittest.cc
|
||||||
|
+++ b/base/allocator/partition_allocator/src/partition_alloc/pointers/raw_ptr_unittest.cc
|
||||||
|
@@ -1481,6 +1481,7 @@
|
||||||
|
// `base::to_address()` will use the dereference operator. This is not
|
||||||
|
// what we want; this test enforces extraction semantics for
|
||||||
|
// `to_address()`.
|
||||||
|
+#if 0
|
||||||
|
TEST_F(RawPtrTest, ToAddressDoesNotDereference) {
|
||||||
|
CountingRawPtr<int> ptr = nullptr;
|
||||||
|
int* raw = base::to_address(ptr);
|
||||||
|
@@ -1492,6 +1493,7 @@
|
||||||
|
.get_for_duplication_cnt = 0}),
|
||||||
|
CountersMatch());
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
TEST_F(RawPtrTest, ToAddressGivesBackRawAddress) {
|
||||||
|
int* raw = nullptr;
|
||||||
|
--- a/net/http/http_stream_factory_unittest.cc
|
||||||
|
+++ b/net/http/http_stream_factory_unittest.cc
|
||||||
|
@@ -3477,6 +3477,7 @@
|
||||||
|
DefaultCTPolicyEnforcer ct_policy_enforcer_;
|
||||||
|
};
|
||||||
|
|
||||||
|
+#if 0
|
||||||
|
TEST_F(ProcessAlternativeServicesTest, ProcessEmptyAltSvc) {
|
||||||
|
session_ =
|
||||||
|
std::make_unique<HttpNetworkSession>(session_params_, session_context_);
|
||||||
|
@@ -3585,6 +3586,7 @@
|
||||||
|
alternatives[0].host_port_pair());
|
||||||
|
EXPECT_EQ(0u, alternatives[0].advertised_versions().size());
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
} // namespace
|
||||||
|
|
|
@ -10,6 +10,8 @@ done
|
||||||
# Prefer user defined ELECTRON_USER_FLAGS (from env) over system
|
# Prefer user defined ELECTRON_USER_FLAGS (from env) over system
|
||||||
# default ELECTRON_FLAGS (from /etc/electron/default.conf).
|
# default ELECTRON_FLAGS (from /etc/electron/default.conf).
|
||||||
export ELECTRON_FLAGS="$ELECTRON_FLAGS ${ELECTRON_USER_FLAGS:-"$ELECTRON_USER_FLAGS"}"
|
export ELECTRON_FLAGS="$ELECTRON_FLAGS ${ELECTRON_USER_FLAGS:-"$ELECTRON_USER_FLAGS"}"
|
||||||
|
# Re-export, for it to be accessible by the process
|
||||||
|
export ELECTRON_OZONE_PLATFORM_HINT="${ELECTRON_OZONE_PLATFORM_HINT}"
|
||||||
|
|
||||||
if [ "$ELECTRON_RUN_AS_NODE" == "1" ] && [ "$ELECTRON_STILL_PASS_THE_DEFAULT_FLAGS" != "1" ]; then
|
if [ "$ELECTRON_RUN_AS_NODE" == "1" ] && [ "$ELECTRON_STILL_PASS_THE_DEFAULT_FLAGS" != "1" ]; then
|
||||||
exec "/usr/lib/electron/electron" "$@"
|
exec "/usr/lib/electron/electron" "$@"
|
||||||
|
|
13
backports/electron/fc-cache-version.patch
Normal file
13
backports/electron/fc-cache-version.patch
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
instead of hardcoding the version, use the defined macro.
|
||||||
|
--
|
||||||
|
--- a/third_party/test_fonts/fontconfig/generate_fontconfig_caches.cc
|
||||||
|
+++ b/third_party/test_fonts/fontconfig/generate_fontconfig_caches.cc
|
||||||
|
@@ -56,7 +56,7 @@
|
||||||
|
FcFini();
|
||||||
|
|
||||||
|
// Check existence of intended fontconfig cache file.
|
||||||
|
- auto cache = fontconfig_caches + "/" + kCacheKey + "-le64.cache-9";
|
||||||
|
+ auto cache = fontconfig_caches + "/" + kCacheKey + "-le64.cache-" + FC_CACHE_VERSION;
|
||||||
|
bool cache_exists = access(cache.c_str(), F_OK) == 0;
|
||||||
|
return !cache_exists;
|
||||||
|
}
|
12
backports/electron/fix-opus.patch
Normal file
12
backports/electron/fix-opus.patch
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
--- a/media/filters/ffmpeg_glue.cc
|
||||||
|
+++ b/media/filters/ffmpeg_glue.cc
|
||||||
|
@@ -142,7 +142,7 @@ const char* FFmpegGlue::GetAllowedAudioDecoders() {
|
||||||
|
static const base::NoDestructor<std::string> kAllowedAudioCodecs([]() {
|
||||||
|
// This should match the configured lists in //third_party/ffmpeg.
|
||||||
|
std::string allowed_decoders(
|
||||||
|
- "vorbis,libopus,flac,pcm_u8,pcm_s16le,pcm_s24le,pcm_s32le,pcm_f32le,"
|
||||||
|
+ "vorbis,opus,libopus,flac,pcm_u8,pcm_s16le,pcm_s24le,pcm_s32le,pcm_f32le,"
|
||||||
|
"mp3,pcm_s16be,pcm_s24be,pcm_mulaw,pcm_alaw");
|
||||||
|
#if BUILDFLAG(USE_PROPRIETARY_CODECS)
|
||||||
|
allowed_decoders += ",aac";
|
||||||
|
|
17
backports/electron/fstatat-32bit.patch
Normal file
17
backports/electron/fstatat-32bit.patch
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
fstatat64 is macrod to fstatat in sys/stat.h in musl- but then that fstatat is
|
||||||
|
used in the _syscall4 macro mapping to __NR_$name, and __NR_fstatat is not
|
||||||
|
defined anywhere here, as it wants the 64 name.
|
||||||
|
|
||||||
|
so, just let it keep the name with an undef of the stat.h macro, then the macro
|
||||||
|
expansion below evaluates correctly.
|
||||||
|
--- a/third_party/lss/linux_syscall_support.h
|
||||||
|
+++ b/third_party/lss/linux_syscall_support.h
|
||||||
|
@@ -4947,7 +4947,8 @@
|
||||||
|
# endif
|
||||||
|
#endif
|
||||||
|
#if defined(__NR_fstatat64)
|
||||||
|
+ #undef fstatat64
|
||||||
|
LSS_INLINE _syscall4(int, fstatat64, int, d,
|
||||||
|
const char *, p,
|
||||||
|
struct kernel_stat64 *, b, int, f)
|
||||||
|
#endif
|
11
backports/electron/generic-sensor-include.patch
Normal file
11
backports/electron/generic-sensor-include.patch
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
--- a/services/device/public/cpp/generic_sensor/sensor_reading.h
|
||||||
|
+++ b/services/device/public/cpp/generic_sensor/sensor_reading.h
|
||||||
|
@@ -5,6 +5,8 @@
|
||||||
|
#ifndef SERVICES_DEVICE_PUBLIC_CPP_GENERIC_SENSOR_SENSOR_READING_H_
|
||||||
|
#define SERVICES_DEVICE_PUBLIC_CPP_GENERIC_SENSOR_SENSOR_READING_H_
|
||||||
|
|
||||||
|
+#include <cstddef>
|
||||||
|
+#include <cstdint>
|
||||||
|
#include <type_traits>
|
||||||
|
|
||||||
|
namespace device {
|
|
@ -1,11 +1,11 @@
|
||||||
--- a/electron/default_app/default_app.ts
|
--- a/electron/default_app/default_app.ts
|
||||||
+++ b/electron/default_app/default_app.ts
|
+++ b/electron/default_app/default_app.ts
|
||||||
@@ -60,7 +60,7 @@
|
@@ -61,7 +61,7 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
if (process.platform === 'linux') {
|
if (process.platform === 'linux') {
|
||||||
- options.icon = path.join(__dirname, 'icon.png');
|
- options.icon = url.fileURLToPath(new URL('icon.png', import.meta.url));
|
||||||
+ options.icon = '/usr/share/icons/hicolor/1024x1024/apps/electron.png';
|
+ options.icon = 'file:///usr/share/icons/hicolor/1024x1024/apps/electron.png';
|
||||||
}
|
}
|
||||||
|
|
||||||
mainWindow = new BrowserWindow(options);
|
mainWindow = new BrowserWindow(options);
|
||||||
|
|
|
@ -1,39 +0,0 @@
|
||||||
Patch-Source: https://github.com/archlinux/svntogit-packages/blob/bf2401407df5bcc938382eb03748fbef41e41c89/trunk/unbundle-jsoncpp-avoid-CFI-faults-with-is_cfi-true.patch
|
|
||||||
From ed8d931e35f81d8566835a579caf7d61368f85b7 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Evangelos Foutras <evangelos@foutrelis.com>
|
|
||||||
Date: Tue, 27 Sep 2022 22:20:41 +0000
|
|
||||||
Subject: [PATCH] unbundle/jsoncpp: avoid CFI faults with is_cfi=true
|
|
||||||
|
|
||||||
Ensure jsoncpp symbols have public visibility and are thus excluded from
|
|
||||||
CFI checks and whole-program optimization. This is achieved by defining
|
|
||||||
JSON_DLL_BUILD which in turn causes json/config.h to define JSON_API as
|
|
||||||
__attribute__((visibility("default"))). The latter macro is used to tag
|
|
||||||
jsoncpp classes and namespace functions throughout jsoncpp's headers.
|
|
||||||
|
|
||||||
BUG=1365218
|
|
||||||
|
|
||||||
Change-Id: I56277737b7d9ecaeb5e17c8d21a2e55f3d5d5bc9
|
|
||||||
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3919652
|
|
||||||
Reviewed-by: Thomas Anderson <thomasanderson@chromium.org>
|
|
||||||
Commit-Queue: Thomas Anderson <thomasanderson@chromium.org>
|
|
||||||
Cr-Commit-Position: refs/heads/main@{#1052077}
|
|
||||||
---
|
|
||||||
build/linux/unbundle/jsoncpp.gn | 5 +++++
|
|
||||||
1 file changed, 5 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/build/linux/unbundle/jsoncpp.gn b/build/linux/unbundle/jsoncpp.gn
|
|
||||||
index 544f9d13c9..e84a0ef27a 100644
|
|
||||||
--- a/build/linux/unbundle/jsoncpp.gn
|
|
||||||
+++ b/build/linux/unbundle/jsoncpp.gn
|
|
||||||
@@ -3,6 +3,11 @@ import("//build/shim_headers.gni")
|
|
||||||
|
|
||||||
pkg_config("jsoncpp_config") {
|
|
||||||
packages = [ "jsoncpp" ]
|
|
||||||
+
|
|
||||||
+ # Defining JSON_DLL_BUILD applies public visibility to jsoncpp classes
|
|
||||||
+ # thus deactivating CFI checks for them. This avoids CFI violations in
|
|
||||||
+ # virtual calls to system jsoncpp library (https://crbug.com/1365218).
|
|
||||||
+ defines = [ "JSON_DLL_BUILD" ]
|
|
||||||
}
|
|
||||||
|
|
||||||
shim_headers("jsoncpp_shim") {
|
|
|
@ -1,15 +1,5 @@
|
||||||
missing libstdc++13 includes
|
missing libstdc++13 includes
|
||||||
--
|
--
|
||||||
--- a/third_party/ruy/src/ruy/profiler/instrumentation.h
|
|
||||||
+++ b/third_party/ruy/src/ruy/profiler/instrumentation.h
|
|
||||||
@@ -19,6 +19,7 @@
|
|
||||||
#ifdef RUY_PROFILER
|
|
||||||
#include <cstdio>
|
|
||||||
#include <mutex>
|
|
||||||
+#include <string>
|
|
||||||
#include <vector>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
--- a/third_party/openscreen/src/platform/base/error.h
|
--- a/third_party/openscreen/src/platform/base/error.h
|
||||||
+++ b/third_party/openscreen/src/platform/base/error.h
|
+++ b/third_party/openscreen/src/platform/base/error.h
|
||||||
@@ -6,6 +6,7 @@
|
@@ -6,6 +6,7 @@
|
||||||
|
@ -20,26 +10,6 @@ missing libstdc++13 includes
|
||||||
#include <ostream>
|
#include <ostream>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
--- a/third_party/vulkan_memory_allocator/include/vk_mem_alloc.h
|
|
||||||
+++ b/third_party/vulkan_memory_allocator/include/vk_mem_alloc.h
|
|
||||||
@@ -2389,6 +2389,7 @@
|
|
||||||
#undef VMA_IMPLEMENTATION
|
|
||||||
|
|
||||||
#include <cstdint>
|
|
||||||
+#include <cstdio>
|
|
||||||
#include <cstdlib>
|
|
||||||
#include <cstring>
|
|
||||||
#include <utility>
|
|
||||||
--- a/third_party/vulkan-deps/vulkan-validation-layers/src/layers/external/vma/vk_mem_alloc.h
|
|
||||||
+++ b/third_party/vulkan-deps/vulkan-validation-layers/src/layers/external/vma/vk_mem_alloc.h
|
|
||||||
@@ -2389,6 +2389,7 @@
|
|
||||||
#undef VMA_IMPLEMENTATION
|
|
||||||
|
|
||||||
#include <cstdint>
|
|
||||||
+#include <cstdio>
|
|
||||||
#include <cstdlib>
|
|
||||||
#include <cstring>
|
|
||||||
#include <utility>
|
|
||||||
--- a/ui/base/prediction/kalman_filter.h
|
--- a/ui/base/prediction/kalman_filter.h
|
||||||
+++ b/ui/base/prediction/kalman_filter.h
|
+++ b/ui/base/prediction/kalman_filter.h
|
||||||
@@ -8,6 +8,8 @@
|
@@ -8,6 +8,8 @@
|
||||||
|
@ -265,16 +235,6 @@ missing libstdc++13 includes
|
||||||
#include <map>
|
#include <map>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
--- a/chrome/browser/privacy_budget/encountered_surface_tracker.h
|
|
||||||
+++ b/chrome/browser/privacy_budget/encountered_surface_tracker.h
|
|
||||||
@@ -5,6 +5,7 @@
|
|
||||||
#ifndef CHROME_BROWSER_PRIVACY_BUDGET_ENCOUNTERED_SURFACE_TRACKER_H_
|
|
||||||
#define CHROME_BROWSER_PRIVACY_BUDGET_ENCOUNTERED_SURFACE_TRACKER_H_
|
|
||||||
|
|
||||||
+#include <cstdint>
|
|
||||||
#include <map>
|
|
||||||
|
|
||||||
#include "base/containers/flat_set.h"
|
|
||||||
--- a/chrome/browser/resource_coordinator/decision_details.h
|
--- a/chrome/browser/resource_coordinator/decision_details.h
|
||||||
+++ b/chrome/browser/resource_coordinator/decision_details.h
|
+++ b/chrome/browser/resource_coordinator/decision_details.h
|
||||||
@@ -5,6 +5,7 @@
|
@@ -5,6 +5,7 @@
|
||||||
|
@ -296,16 +256,6 @@ missing libstdc++13 includes
|
||||||
namespace quic {
|
namespace quic {
|
||||||
|
|
||||||
// This interface writes encoder/decoder data to peer.
|
// This interface writes encoder/decoder data to peer.
|
||||||
--- a/third_party/perfetto/src/trace_processor/sqlite/query_constraints.h
|
|
||||||
+++ b/third_party/perfetto/src/trace_processor/sqlite/query_constraints.h
|
|
||||||
@@ -17,6 +17,7 @@
|
|
||||||
#ifndef SRC_TRACE_PROCESSOR_SQLITE_QUERY_CONSTRAINTS_H_
|
|
||||||
#define SRC_TRACE_PROCESSOR_SQLITE_QUERY_CONSTRAINTS_H_
|
|
||||||
|
|
||||||
+#include <cstdint>
|
|
||||||
#include <limits>
|
|
||||||
#include <vector>
|
|
||||||
|
|
||||||
--- a/third_party/perfetto/include/perfetto/base/export.h
|
--- a/third_party/perfetto/include/perfetto/base/export.h
|
||||||
+++ b/third_party/perfetto/include/perfetto/base/export.h
|
+++ b/third_party/perfetto/include/perfetto/base/export.h
|
||||||
@@ -17,6 +17,8 @@
|
@@ -17,6 +17,8 @@
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
needed for PKEY_DISABLE_WRITE. these are documented as also being from sys/
|
needed for PKEY_DISABLE_WRITE. these are documented as also being from sys/
|
||||||
mman.h with GNU_SOURCE, but musl doesn't do that, so these are strictly from
|
mman.h with GNU_SOURCE, but musl doesn't do that, so these are strictly from
|
||||||
kernel headers
|
kernel headers
|
||||||
--- a/base/allocator/partition_allocator/partition_alloc_unittest.cc
|
--- a/base/allocator/partition_allocator/src/partition_alloc/partition_alloc_unittest.cc
|
||||||
+++ b/base/allocator/partition_allocator/partition_alloc_unittest.cc
|
+++ b/base/allocator/partition_allocator/src/partition_alloc/partition_alloc_unittest.cc
|
||||||
@@ -60,6 +60,7 @@
|
@@ -60,6 +60,7 @@
|
||||||
#include <sys/mman.h>
|
#include <sys/mman.h>
|
||||||
#include <sys/resource.h>
|
#include <sys/resource.h>
|
||||||
|
|
11
backports/electron/musl-auxv.patch
Normal file
11
backports/electron/musl-auxv.patch
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
--- ./v8/src/base/cpu.cc.orig
|
||||||
|
+++ ./v8/src/base/cpu.cc
|
||||||
|
@@ -14,7 +14,7 @@
|
||||||
|
#if V8_OS_LINUX
|
||||||
|
#include <linux/auxvec.h> // AT_HWCAP
|
||||||
|
#endif
|
||||||
|
-#if V8_GLIBC_PREREQ(2, 16) || V8_OS_ANDROID
|
||||||
|
+#if 1
|
||||||
|
#include <sys/auxv.h> // getauxval()
|
||||||
|
#endif
|
||||||
|
#if V8_OS_QNX
|
|
@ -37,25 +37,24 @@ for discussion about this, see https://www.openwall.com/lists/musl/2021/07/16/1
|
||||||
#define HAVE_FCNTL_H 1
|
#define HAVE_FCNTL_H 1
|
||||||
--- a/base/debug/stack_trace.cc
|
--- a/base/debug/stack_trace.cc
|
||||||
+++ b/base/debug/stack_trace.cc
|
+++ b/base/debug/stack_trace.cc
|
||||||
@@ -251,7 +253,9 @@
|
@@ -291,7 +291,7 @@
|
||||||
}
|
|
||||||
|
|
||||||
void StackTrace::OutputToStream(std::ostream* os) const {
|
|
||||||
+#if defined(__GLIBC__) && !defined(_AIX)
|
|
||||||
OutputToStreamWithPrefix(os, nullptr);
|
|
||||||
+#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
std::string StackTrace::ToString() const {
|
|
||||||
@@ -281,7 +281,7 @@
|
|
||||||
}
|
}
|
||||||
std::string StackTrace::ToStringWithPrefix(const char* prefix_string) const {
|
std::string StackTrace::ToStringWithPrefix(const char* prefix_string) const {
|
||||||
std::stringstream stream;
|
std::stringstream stream;
|
||||||
-#if !defined(__UCLIBC__) && !defined(_AIX)
|
-#if !defined(__UCLIBC__) && !defined(_AIX)
|
||||||
+#if defined(__GLIBC__) && !defined(_AIX)
|
+#if defined(__GLIBC__) && !defined(_AIX)
|
||||||
OutputToStreamWithPrefix(&stream, prefix_string);
|
if (ShouldSuppressOutput()) {
|
||||||
#endif
|
return "Backtrace suppressed.";
|
||||||
return stream.str();
|
}
|
||||||
|
@@ -301,7 +301,7 @@
|
||||||
|
}
|
||||||
|
|
||||||
|
std::ostream& operator<<(std::ostream& os, const StackTrace& s) {
|
||||||
|
-#if !defined(__UCLIBC__) && !defined(_AIX)
|
||||||
|
+#if defined(__GLIBC__) && !defined(_AIX)
|
||||||
|
s.OutputToStream(&os);
|
||||||
|
#else
|
||||||
|
os << "StackTrace::OutputToStream not implemented.";
|
||||||
--- a/base/debug/stack_trace_unittest.cc
|
--- a/base/debug/stack_trace_unittest.cc
|
||||||
+++ b/base/debug/stack_trace_unittest.cc
|
+++ b/base/debug/stack_trace_unittest.cc
|
||||||
@@ -33,7 +33,7 @@
|
@@ -33,7 +33,7 @@
|
||||||
|
@ -67,12 +66,3 @@ for discussion about this, see https://www.openwall.com/lists/musl/2021/07/16/1
|
||||||
// StackTrace::OutputToStream() is not implemented under uclibc, nor AIX.
|
// StackTrace::OutputToStream() is not implemented under uclibc, nor AIX.
|
||||||
// See https://crbug.com/706728
|
// See https://crbug.com/706728
|
||||||
|
|
||||||
@@ -156,7 +156,7 @@
|
|
||||||
|
|
||||||
#endif // !defined(__UCLIBC__) && !defined(_AIX)
|
|
||||||
|
|
||||||
-#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_ANDROID)
|
|
||||||
+#if (BUILDFLAG(IS_POSIX) && defined(__GLIBC__)) && !BUILDFLAG(IS_ANDROID)
|
|
||||||
#if !BUILDFLAG(IS_IOS)
|
|
||||||
static char* newArray() {
|
|
||||||
// Clang warns about the mismatched new[]/delete if they occur in the same
|
|
||||||
|
|
|
@ -100,8 +100,8 @@ musl does not implement mallinfo()/mallinfo2()
|
||||||
|
|
||||||
/* Define to 1 if you have the <malloc.h> header file. */
|
/* Define to 1 if you have the <malloc.h> header file. */
|
||||||
#define HAVE_MALLOC_H 1
|
#define HAVE_MALLOC_H 1
|
||||||
--- a/base/allocator/partition_allocator/shim/allocator_shim_default_dispatch_to_partition_alloc.cc
|
--- a/base/allocator/partition_allocator/src/partition_alloc/shim/allocator_shim_default_dispatch_to_partition_alloc.cc
|
||||||
+++ b/base/allocator/partition_allocator/shim/allocator_shim_default_dispatch_to_partition_alloc.cc
|
+++ b/base/allocator/partition_allocator/src/partition_alloc/shim/allocator_shim_default_dispatch_to_partition_alloc.cc
|
||||||
@@ -717,7 +717,7 @@
|
@@ -717,7 +717,7 @@
|
||||||
|
|
||||||
#endif // !BUILDFLAG(IS_APPLE) && !BUILDFLAG(IS_ANDROID)
|
#endif // !BUILDFLAG(IS_APPLE) && !BUILDFLAG(IS_ANDROID)
|
||||||
|
@ -111,8 +111,8 @@ musl does not implement mallinfo()/mallinfo2()
|
||||||
SHIM_ALWAYS_EXPORT struct mallinfo mallinfo(void) __THROW {
|
SHIM_ALWAYS_EXPORT struct mallinfo mallinfo(void) __THROW {
|
||||||
base::SimplePartitionStatsDumper allocator_dumper;
|
base::SimplePartitionStatsDumper allocator_dumper;
|
||||||
Allocator()->DumpStats("malloc", true, &allocator_dumper);
|
Allocator()->DumpStats("malloc", true, &allocator_dumper);
|
||||||
--- a/base/allocator/partition_allocator/shim/allocator_shim_default_dispatch_to_partition_alloc_unittest.cc
|
--- a/base/allocator/partition_allocator/src/partition_alloc/shim/allocator_shim_default_dispatch_to_partition_alloc_unittest.cc
|
||||||
+++ b/base/allocator/partition_allocator/shim/allocator_shim_default_dispatch_to_partition_alloc_unittest.cc
|
+++ b/base/allocator/partition_allocator/src/partition_alloc/shim/allocator_shim_default_dispatch_to_partition_alloc_unittest.cc
|
||||||
@@ -24,7 +24,7 @@
|
@@ -24,7 +24,7 @@
|
||||||
#if BUILDFLAG(USE_PARTITION_ALLOC_AS_MALLOC)
|
#if BUILDFLAG(USE_PARTITION_ALLOC_AS_MALLOC)
|
||||||
|
|
||||||
|
|
|
@ -1,13 +0,0 @@
|
||||||
M115 needs ifuncs for this
|
|
||||||
--
|
|
||||||
--- a/base/allocator/partition_allocator/partition_alloc_config.h
|
|
||||||
+++ b/base/allocator/partition_allocator/partition_alloc_config.h
|
|
||||||
@@ -155,7 +155,7 @@
|
|
||||||
#define PA_CONFIG_HAS_MEMORY_TAGGING() \
|
|
||||||
(defined(ARCH_CPU_ARM64) && defined(__clang__) && \
|
|
||||||
!defined(ADDRESS_SANITIZER) && \
|
|
||||||
- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID)))
|
|
||||||
+ ((BUILDFLAG(IS_LINUX) && defined(__GLIBC__)) || BUILDFLAG(IS_ANDROID)))
|
|
||||||
|
|
||||||
#if PA_CONFIG(HAS_MEMORY_TAGGING)
|
|
||||||
static_assert(sizeof(void*) == 8);
|
|
14
backports/electron/partalloc-no-tagging-arm64.patch
Normal file
14
backports/electron/partalloc-no-tagging-arm64.patch
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
Hard-disable memory tagging on ARM64 - it does exist there but musl is
|
||||||
|
missing some required interface headers for it, and it's not clear how
|
||||||
|
to make the partalloc support code for it work.
|
||||||
|
--- ./base/allocator/partition_allocator/partition_alloc.gni.orig
|
||||||
|
+++ ./base/allocator/partition_allocator/partition_alloc.gni
|
||||||
|
@@ -30,7 +30,7 @@
|
||||||
|
}
|
||||||
|
|
||||||
|
has_memory_tagging =
|
||||||
|
- current_cpu == "arm64" && is_clang && !is_asan && (is_linux || is_android)
|
||||||
|
+ false
|
||||||
|
|
||||||
|
declare_args() {
|
||||||
|
# Causes all the allocations to be routed via allocator_shim.cc. Usually,
|
20
backports/electron/perfetto-libstdc++.patch
Normal file
20
backports/electron/perfetto-libstdc++.patch
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
--- a/third_party/perfetto/src/trace_processor/perfetto_sql/engine/created_function.cc
|
||||||
|
+++ b/third_party/perfetto/src/trace_processor/perfetto_sql/engine/created_function.cc
|
||||||
|
@@ -107,7 +107,7 @@
|
||||||
|
// the destructors run correctly for non-trivial members of the
|
||||||
|
// union.
|
||||||
|
using Data =
|
||||||
|
- std::variant<int64_t, double, OwnedString, OwnedBytes, nullptr_t>;
|
||||||
|
+ std::variant<int64_t, double, OwnedString, OwnedBytes, std::nullptr_t>;
|
||||||
|
|
||||||
|
StoredSqlValue(SqlValue value) {
|
||||||
|
switch (value.type) {
|
||||||
|
@@ -132,7 +132,7 @@
|
||||||
|
}
|
||||||
|
|
||||||
|
SqlValue AsSqlValue() {
|
||||||
|
- if (std::holds_alternative<nullptr_t>(data)) {
|
||||||
|
+ if (std::holds_alternative<std::nullptr_t>(data)) {
|
||||||
|
return SqlValue();
|
||||||
|
} else if (std::holds_alternative<int64_t>(data)) {
|
||||||
|
return SqlValue::Long(std::get<int64_t>(data));
|
33
backports/electron/pvalloc.patch
Normal file
33
backports/electron/pvalloc.patch
Normal file
|
@ -0,0 +1,33 @@
|
||||||
|
the pvalloc/valloc symbols are obsolete and not implemented in musl
|
||||||
|
--
|
||||||
|
--- a/base/allocator/partition_allocator/src/partition_alloc/shim/allocator_shim_unittest.cc
|
||||||
|
+++ b/base/allocator/partition_allocator/src/partition_alloc/shim/allocator_shim_unittest.cc
|
||||||
|
@@ -375,7 +375,7 @@
|
||||||
|
ASSERT_GE(aligned_allocs_intercepted_by_alignment[128], 1u);
|
||||||
|
ASSERT_GE(aligned_allocs_intercepted_by_size[53], 1u);
|
||||||
|
|
||||||
|
-#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_ANDROID)
|
||||||
|
+#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_ANDROID) && defined(__GLIBC__)
|
||||||
|
void* pvalloc_ptr = pvalloc(67);
|
||||||
|
ASSERT_NE(nullptr, pvalloc_ptr);
|
||||||
|
ASSERT_EQ(0u, reinterpret_cast<uintptr_t>(pvalloc_ptr) % kPageSize);
|
||||||
|
@@ -414,7 +414,7 @@
|
||||||
|
free(memalign_ptr);
|
||||||
|
ASSERT_GE(frees_intercepted_by_addr[Hash(memalign_ptr)], 1u);
|
||||||
|
|
||||||
|
-#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_ANDROID)
|
||||||
|
+#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_ANDROID) && defined(__GLIBC__)
|
||||||
|
free(pvalloc_ptr);
|
||||||
|
ASSERT_GE(frees_intercepted_by_addr[Hash(pvalloc_ptr)], 1u);
|
||||||
|
#endif // BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_ANDROID)
|
||||||
|
--- a/base/process/memory_unittest.cc
|
||||||
|
+++ b/base/process/memory_unittest.cc
|
||||||
|
@@ -359,7 +359,7 @@
|
||||||
|
#endif // BUILDFLAG(IS_WIN)
|
||||||
|
#endif // !BUILDFLAG(IS_MAC)
|
||||||
|
|
||||||
|
-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)
|
||||||
|
+#if (BUILDFLAG(IS_LINUX) && defined(__GLIBC__)) || BUILDFLAG(IS_CHROMEOS)
|
||||||
|
|
||||||
|
TEST_F(OutOfMemoryDeathTest, Valloc) {
|
||||||
|
ASSERT_OOM_DEATH({
|
12
backports/electron/quiche-array.patch
Normal file
12
backports/electron/quiche-array.patch
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
needed for push_back on array
|
||||||
|
--
|
||||||
|
--- a/net/third_party/quiche/src/quiche/common/quiche_endian.h
|
||||||
|
+++ b/net/third_party/quiche/src/quiche/common/quiche_endian.h
|
||||||
|
@@ -6,6 +6,7 @@
|
||||||
|
#define QUICHE_COMMON_QUICHE_ENDIAN_H_
|
||||||
|
|
||||||
|
#include <algorithm>
|
||||||
|
+#include <array>
|
||||||
|
#include <cstdint>
|
||||||
|
#include <type_traits>
|
||||||
|
|
94
backports/electron/random-fixes.patch
Normal file
94
backports/electron/random-fixes.patch
Normal file
|
@ -0,0 +1,94 @@
|
||||||
|
Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/chromium/-/blob/c073b0c20935d7eb452732e0f3b2860a96c3db21/random-build-fixes.patch
|
||||||
|
--
|
||||||
|
diff --git a/chrome/browser/download/bubble/download_bubble_update_service.cc b/chrome/browser/download/bubble/download_bubble_update_service.cc
|
||||||
|
index 41b647f7b44..8940c6bb7fc 100644
|
||||||
|
--- a/chrome/browser/download/bubble/download_bubble_update_service.cc
|
||||||
|
+++ b/chrome/browser/download/bubble/download_bubble_update_service.cc
|
||||||
|
@@ -91,7 +91,7 @@ ItemSortKey GetSortKey(const Item& item) {
|
||||||
|
// Helper to get an iterator to the last element in the cache. The cache
|
||||||
|
// must not be empty.
|
||||||
|
template <typename Item>
|
||||||
|
-SortedItems<Item>::const_iterator GetLastIter(const SortedItems<Item>& cache) {
|
||||||
|
+typename SortedItems<Item>::const_iterator GetLastIter(const SortedItems<Item>& cache) {
|
||||||
|
CHECK(!cache.empty());
|
||||||
|
auto it = cache.end();
|
||||||
|
return std::prev(it);
|
||||||
|
@@ -967,9 +967,9 @@ bool DownloadBubbleUpdateService::CacheManager::RemoveItemFromCacheImpl(
|
||||||
|
}
|
||||||
|
|
||||||
|
template <typename Id, typename Item>
|
||||||
|
-SortedItems<Item>::iterator
|
||||||
|
+typename SortedItems<Item>::iterator
|
||||||
|
DownloadBubbleUpdateService::CacheManager::RemoveItemFromCacheByIter(
|
||||||
|
- SortedItems<Item>::iterator iter,
|
||||||
|
+ typename SortedItems<Item>::iterator iter,
|
||||||
|
SortedItems<Item>& cache,
|
||||||
|
IterMap<Id, Item>& iter_map) {
|
||||||
|
CHECK(iter != cache.end());
|
||||||
|
diff --git a/chrome/test/chromedriver/capabilities.cc b/chrome/test/chromedriver/capabilities.cc
|
||||||
|
index c0708681ebd..98b8494d170 100644
|
||||||
|
--- a/chrome/test/chromedriver/capabilities.cc
|
||||||
|
+++ b/chrome/test/chromedriver/capabilities.cc
|
||||||
|
@@ -355,7 +355,7 @@ Status ParseMobileEmulation(const base::Value& option,
|
||||||
|
"'version' field of type string");
|
||||||
|
}
|
||||||
|
|
||||||
|
- brands.emplace_back(*brand, *version);
|
||||||
|
+ brands.emplace_back(BrandVersion{*brand, *version});
|
||||||
|
}
|
||||||
|
|
||||||
|
client_hints.brands = std::move(brands);
|
||||||
|
@@ -392,7 +392,7 @@ Status ParseMobileEmulation(const base::Value& option,
|
||||||
|
"a 'version' field of type string");
|
||||||
|
}
|
||||||
|
|
||||||
|
- full_version_list.emplace_back(*brand, *version);
|
||||||
|
+ full_version_list.emplace_back(BrandVersion{*brand, *version});
|
||||||
|
}
|
||||||
|
|
||||||
|
client_hints.full_version_list = std::move(full_version_list);
|
||||||
|
diff --git a/components/optimization_guide/core/tflite_model_executor.h b/components/optimization_guide/core/tflite_model_executor.h
|
||||||
|
index c4f750f4684..b5635f4108b 100644
|
||||||
|
--- a/components/optimization_guide/core/tflite_model_executor.h
|
||||||
|
+++ b/components/optimization_guide/core/tflite_model_executor.h
|
||||||
|
@@ -189,7 +189,7 @@ class TFLiteModelExecutor : public ModelExecutor<OutputType, InputType> {
|
||||||
|
void SendForBatchExecution(
|
||||||
|
BatchExecutionCallback callback_on_complete,
|
||||||
|
base::TimeTicks start_time,
|
||||||
|
- ModelExecutor<OutputType, InputType>::ConstRefInputVector inputs)
|
||||||
|
+ typename ModelExecutor<OutputType, InputType>::ConstRefInputVector inputs)
|
||||||
|
override {
|
||||||
|
DCHECK(execution_task_runner_->RunsTasksInCurrentSequence());
|
||||||
|
DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
|
||||||
|
diff --git a/third_party/blink/renderer/core/html/parser/html_document_parser_fastpath.cc b/third_party/blink/renderer/core/html/parser/html_document_parser_fastpath.cc
|
||||||
|
index 2dc0b304092..a82f255090b 100644
|
||||||
|
--- a/third_party/blink/renderer/core/html/parser/html_document_parser_fastpath.cc
|
||||||
|
+++ b/third_party/blink/renderer/core/html/parser/html_document_parser_fastpath.cc
|
||||||
|
@@ -169,7 +169,7 @@ class HTMLFastPathParser {
|
||||||
|
using Span = base::span<const Char>;
|
||||||
|
using USpan = base::span<const UChar>;
|
||||||
|
// 32 matches that used by HTMLToken::Attribute.
|
||||||
|
- typedef std::conditional<std::is_same_v<Char, UChar>,
|
||||||
|
+ typedef typename std::conditional<std::is_same_v<Char, UChar>,
|
||||||
|
UCharLiteralBuffer<32>,
|
||||||
|
LCharLiteralBuffer<32>>::type LiteralBufferType;
|
||||||
|
typedef UCharLiteralBuffer<32> UCharLiteralBufferType;
|
||||||
|
diff --git a/third_party/blink/renderer/modules/canvas/canvas2d/canvas_style.cc b/third_party/blink/renderer/modules/canvas/canvas2d/canvas_style.cc
|
||||||
|
index f0b49139147..a308fb67982 100644
|
||||||
|
--- a/third_party/blink/renderer/modules/canvas/canvas2d/canvas_style.cc
|
||||||
|
+++ b/third_party/blink/renderer/modules/canvas/canvas2d/canvas_style.cc
|
||||||
|
@@ -91,12 +91,12 @@ void CanvasStyle::ApplyToFlags(cc::PaintFlags& flags,
|
||||||
|
case kGradient:
|
||||||
|
GetCanvasGradient()->GetGradient()->ApplyToFlags(flags, SkMatrix::I(),
|
||||||
|
ImageDrawOptions());
|
||||||
|
- flags.setColor(SkColor4f(0.0f, 0.0f, 0.0f, global_alpha));
|
||||||
|
+ flags.setColor(SkColor4f{0.0f, 0.0f, 0.0f, global_alpha});
|
||||||
|
break;
|
||||||
|
case kImagePattern:
|
||||||
|
GetCanvasPattern()->GetPattern()->ApplyToFlags(
|
||||||
|
flags, AffineTransformToSkMatrix(GetCanvasPattern()->GetTransform()));
|
||||||
|
- flags.setColor(SkColor4f(0.0f, 0.0f, 0.0f, global_alpha));
|
||||||
|
+ flags.setColor(SkColor4f{0.0f, 0.0f, 0.0f, global_alpha});
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
NOTREACHED();
|
|
@ -1,10 +0,0 @@
|
||||||
--- a/third_party/node/update_npm_deps
|
|
||||||
+++ b/third_party/node/update_npm_deps
|
|
||||||
@@ -20,7 +20,6 @@
|
|
||||||
|
|
||||||
patch -d node_modules/@types/d3/ -p1 < chromium_d3_types_index.patch
|
|
||||||
patch -d node_modules/html-minifier/ -p1 < html_minifier.patch
|
|
||||||
-patch -p1 < typescript.patch
|
|
||||||
|
|
||||||
rsync -c --delete -r -q --include-from="npm_include.txt" --exclude-from="npm_exclude.txt" \
|
|
||||||
--prune-empty-dirs "node_modules/" "node_modules_filtered/"
|
|
46
backports/electron/system-zstd.patch
Normal file
46
backports/electron/system-zstd.patch
Normal file
|
@ -0,0 +1,46 @@
|
||||||
|
From ae3ae3711784865bdc38bf119a6182a7b8dae91c Mon Sep 17 00:00:00 2001
|
||||||
|
From: Matt Jolly <Matt.Jolly@footclan.ninja>
|
||||||
|
Date: Sun, 17 Sep 2023 16:51:42 +1000
|
||||||
|
Subject: [PATCH] Add system-zstd
|
||||||
|
|
||||||
|
--- a/build/linux/unbundle/replace_gn_files.py
|
||||||
|
+++ b/build/linux/unbundle/replace_gn_files.py
|
||||||
|
@@ -74,6 +74,7 @@ REPLACEMENTS = {
|
||||||
|
#
|
||||||
|
'woff2': 'third_party/woff2/BUILD.gn',
|
||||||
|
'zlib': 'third_party/zlib/BUILD.gn',
|
||||||
|
+ 'zstd': 'third_party/zstd/BUILD.gn',
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
--- /dev/null
|
||||||
|
+++ b/build/linux/unbundle/zstd.gn
|
||||||
|
@@ -0,0 +1,25 @@
|
||||||
|
+import("//build/config/linux/pkg_config.gni")
|
||||||
|
+import("//build/shim_headers.gni")
|
||||||
|
+
|
||||||
|
+pkg_config("system_zstd") {
|
||||||
|
+ packages = [ "libzstd" ]
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+shim_headers("zstd_shim") {
|
||||||
|
+ root_path = "src/lib"
|
||||||
|
+ headers = [
|
||||||
|
+ "zdict.h",
|
||||||
|
+ "zstd.h",
|
||||||
|
+ "zstd_errors.h",
|
||||||
|
+ ]
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+source_set("zstd") {
|
||||||
|
+ deps = [ ":zstd_shim" ]
|
||||||
|
+ public_configs = [ ":system_zstd" ]
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+source_set("decompress") {
|
||||||
|
+ deps = [ ":zstd_shim" ]
|
||||||
|
+ public_configs = [ ":system_zstd" ]
|
||||||
|
+}
|
||||||
|
--
|
||||||
|
2.42.0
|
||||||
|
|
68
backports/electron/unbundle-node.patch
Normal file
68
backports/electron/unbundle-node.patch
Normal file
|
@ -0,0 +1,68 @@
|
||||||
|
--- ./third_party/electron_node/BUILD.gn.orig
|
||||||
|
+++ ./third_party/electron_node/BUILD.gn
|
||||||
|
@@ -40,6 +40,8 @@
|
||||||
|
node_release_urlbase = ""
|
||||||
|
|
||||||
|
# Allows downstream packagers (eg. Linux distributions) to build Electron against system shared libraries.
|
||||||
|
+ use_system_ada = false
|
||||||
|
+ use_system_base64 = false
|
||||||
|
use_system_cares = false
|
||||||
|
use_system_nghttp2 = false
|
||||||
|
use_system_llhttp = false
|
||||||
|
@@ -48,6 +50,16 @@
|
||||||
|
|
||||||
|
if (is_linux) {
|
||||||
|
import("//build/config/linux/pkg_config.gni")
|
||||||
|
+ if (use_system_ada) {
|
||||||
|
+ config("ada") {
|
||||||
|
+ libs = [ "ada" ]
|
||||||
|
+ }
|
||||||
|
+ }
|
||||||
|
+ if (use_system_base64) {
|
||||||
|
+ pkg_config("base64") {
|
||||||
|
+ packages = [ "base64" ]
|
||||||
|
+ }
|
||||||
|
+ }
|
||||||
|
if (use_system_cares) {
|
||||||
|
pkg_config("cares") {
|
||||||
|
packages = [ "libcares" ]
|
||||||
|
@@ -258,8 +270,6 @@
|
||||||
|
deps = [
|
||||||
|
":node_js2c_exec",
|
||||||
|
"deps/googletest:gtest",
|
||||||
|
- "deps/ada",
|
||||||
|
- "deps/base64",
|
||||||
|
"deps/simdutf",
|
||||||
|
"deps/uvwasi",
|
||||||
|
"//third_party/zlib",
|
||||||
|
@@ -267,6 +277,16 @@
|
||||||
|
"//third_party/brotli:enc",
|
||||||
|
"//v8:v8_libplatform",
|
||||||
|
]
|
||||||
|
+ if (use_system_ada) {
|
||||||
|
+ configs += [ ":ada" ]
|
||||||
|
+ } else {
|
||||||
|
+ deps += [ "deps/ada" ]
|
||||||
|
+ }
|
||||||
|
+ if (use_system_base64) {
|
||||||
|
+ configs += [ ":base64" ]
|
||||||
|
+ } else {
|
||||||
|
+ deps += [ "deps/base64" ]
|
||||||
|
+ }
|
||||||
|
if (use_system_cares) {
|
||||||
|
configs += [ ":cares" ]
|
||||||
|
} else {
|
||||||
|
--- ./electron/script/generate-config-gypi.py.orig
|
||||||
|
+++ ./electron/script/generate-config-gypi.py
|
||||||
|
@@ -62,6 +62,11 @@
|
||||||
|
# Used by certain versions of node-gyp.
|
||||||
|
v['build_v8_with_gn'] = 'false'
|
||||||
|
|
||||||
|
+ with open(os.path.join(NODE_DIR, 'use_system.txt')) as f:
|
||||||
|
+ for dep in f.read().strip().split(' '):
|
||||||
|
+ if v.get(f'node_shared_{dep}') is not None:
|
||||||
|
+ v[f'node_shared_{dep}'] = 'true'
|
||||||
|
+
|
||||||
|
with open(target_file, 'w+') as f:
|
||||||
|
f.write(pprint.pformat(config, indent=2))
|
||||||
|
|
|
@ -1,113 +0,0 @@
|
||||||
--- a/chrome/browser/process_singleton_posix.cc
|
|
||||||
+++ b/chrome/browser/process_singleton_posix.cc
|
|
||||||
@@ -607,7 +607,7 @@
|
|
||||||
// |reader| is for sending back ACK message.
|
|
||||||
void HandleMessage(const std::string& current_dir,
|
|
||||||
const std::vector<std::string>& argv,
|
|
||||||
- const std::vector<const uint8_t> additional_data,
|
|
||||||
+ const std::vector<uint8_t> additional_data,
|
|
||||||
SocketReader* reader);
|
|
||||||
|
|
||||||
private:
|
|
||||||
@@ -664,7 +664,7 @@
|
|
||||||
void ProcessSingleton::LinuxWatcher::HandleMessage(
|
|
||||||
const std::string& current_dir,
|
|
||||||
const std::vector<std::string>& argv,
|
|
||||||
- const std::vector<const uint8_t> additional_data,
|
|
||||||
+ const std::vector<uint8_t> additional_data,
|
|
||||||
SocketReader* reader) {
|
|
||||||
DCHECK(ui_task_runner_->BelongsToCurrentThread());
|
|
||||||
DCHECK(reader);
|
|
||||||
@@ -754,7 +754,7 @@
|
|
||||||
base::StringToSizeT(tokens[0], &num_args);
|
|
||||||
std::vector<std::string> command_line(tokens.begin() + 1, tokens.begin() + 1 + num_args);
|
|
||||||
|
|
||||||
- std::vector<const uint8_t> additional_data;
|
|
||||||
+ std::vector<uint8_t> additional_data;
|
|
||||||
if (tokens.size() >= 3 + num_args) {
|
|
||||||
size_t additional_data_size;
|
|
||||||
base::StringToSizeT(tokens[1 + num_args], &additional_data_size);
|
|
||||||
@@ -763,7 +763,7 @@
|
|
||||||
std::string(1, kTokenDelimiter));
|
|
||||||
const uint8_t* additional_data_bits =
|
|
||||||
reinterpret_cast<const uint8_t*>(remaining_args.c_str());
|
|
||||||
- additional_data = std::vector<const uint8_t>(
|
|
||||||
+ additional_data = std::vector<uint8_t>(
|
|
||||||
additional_data_bits, additional_data_bits + additional_data_size);
|
|
||||||
}
|
|
||||||
|
|
||||||
--- a/chrome/browser/process_singleton.h
|
|
||||||
+++ b/chrome/browser/process_singleton.h
|
|
||||||
@@ -102,7 +102,7 @@
|
|
||||||
using NotificationCallback =
|
|
||||||
base::RepeatingCallback<bool(const base::CommandLine& command_line,
|
|
||||||
const base::FilePath& current_directory,
|
|
||||||
- const std::vector<const uint8_t> additional_data)>;
|
|
||||||
+ const std::vector<uint8_t> additional_data)>;
|
|
||||||
|
|
||||||
#if BUILDFLAG(IS_WIN)
|
|
||||||
ProcessSingleton(const std::string& program_name,
|
|
||||||
--- a/chrome/browser/process_singleton_win.cc
|
|
||||||
+++ b/chrome/browser/process_singleton_win.cc
|
|
||||||
@@ -81,7 +81,7 @@
|
|
||||||
bool ParseCommandLine(const COPYDATASTRUCT* cds,
|
|
||||||
base::CommandLine* parsed_command_line,
|
|
||||||
base::FilePath* current_directory,
|
|
||||||
- std::vector<const uint8_t>* parsed_additional_data) {
|
|
||||||
+ std::vector<uint8_t>* parsed_additional_data) {
|
|
||||||
// We should have enough room for the shortest command (min_message_size)
|
|
||||||
// and also be a multiple of wchar_t bytes. The shortest command
|
|
||||||
// possible is L"START\0\0" (empty command line, current directory,
|
|
||||||
@@ -163,7 +163,7 @@
|
|
||||||
msg.substr(fourth_null + 1, fifth_null - fourth_null);
|
|
||||||
const uint8_t* additional_data_bytes =
|
|
||||||
reinterpret_cast<const uint8_t*>(additional_data.c_str());
|
|
||||||
- *parsed_additional_data = std::vector<const uint8_t>(additional_data_bytes,
|
|
||||||
+ *parsed_additional_data = std::vector<uint8_t>(additional_data_bytes,
|
|
||||||
additional_data_bytes + additional_data_length);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
@@ -187,7 +187,7 @@
|
|
||||||
|
|
||||||
base::CommandLine parsed_command_line(base::CommandLine::NO_PROGRAM);
|
|
||||||
base::FilePath current_directory;
|
|
||||||
- std::vector<const uint8_t> additional_data;
|
|
||||||
+ std::vector<uint8_t> additional_data;
|
|
||||||
if (!ParseCommandLine(cds, &parsed_command_line, ¤t_directory, &additional_data)) {
|
|
||||||
*result = TRUE;
|
|
||||||
return true;
|
|
||||||
--- a/electron/shell/browser/api/electron_api_app.cc
|
|
||||||
+++ b/electron/shell/browser/api/electron_api_app.cc
|
|
||||||
@@ -519,10 +519,10 @@
|
|
||||||
const base::RepeatingCallback<
|
|
||||||
void(const base::CommandLine& command_line,
|
|
||||||
const base::FilePath& current_directory,
|
|
||||||
- const std::vector<const uint8_t> additional_data)>& callback,
|
|
||||||
+ const std::vector<uint8_t> additional_data)>& callback,
|
|
||||||
const base::CommandLine& cmd,
|
|
||||||
const base::FilePath& cwd,
|
|
||||||
- const std::vector<const uint8_t> additional_data) {
|
|
||||||
+ const std::vector<uint8_t> additional_data) {
|
|
||||||
// Make sure the callback is called after app gets ready.
|
|
||||||
if (Browser::Get()->is_ready()) {
|
|
||||||
callback.Run(cmd, cwd, std::move(additional_data));
|
|
||||||
@@ -1082,7 +1082,7 @@
|
|
||||||
|
|
||||||
void App::OnSecondInstance(const base::CommandLine& cmd,
|
|
||||||
const base::FilePath& cwd,
|
|
||||||
- const std::vector<const uint8_t> additional_data) {
|
|
||||||
+ const std::vector<uint8_t> additional_data) {
|
|
||||||
v8::Isolate* isolate = JavascriptEnvironment::GetIsolate();
|
|
||||||
v8::Locker locker(isolate);
|
|
||||||
v8::HandleScope handle_scope(isolate);
|
|
||||||
--- a/electron/shell/browser/api/electron_api_app.h
|
|
||||||
+++ b/electron/shell/browser/api/electron_api_app.h
|
|
||||||
@@ -195,7 +195,7 @@
|
|
||||||
std::string GetLocaleCountryCode();
|
|
||||||
void OnSecondInstance(const base::CommandLine& cmd,
|
|
||||||
const base::FilePath& cwd,
|
|
||||||
- const std::vector<const uint8_t> additional_data);
|
|
||||||
+ const std::vector<uint8_t> additional_data);
|
|
||||||
bool HasSingleInstanceLock() const;
|
|
||||||
bool RequestSingleInstanceLock(gin::Arguments* args);
|
|
||||||
void ReleaseSingleInstanceLock();
|
|
11
backports/electron/yes-musl.patch
Normal file
11
backports/electron/yes-musl.patch
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
--- ./buildtools/third_party/libc++/__config_site.orig
|
||||||
|
+++ ./buildtools/third_party/libc++/__config_site
|
||||||
|
@@ -18,7 +18,7 @@
|
||||||
|
/* #undef _LIBCPP_ABI_FORCE_MICROSOFT */
|
||||||
|
/* #undef _LIBCPP_HAS_NO_THREADS */
|
||||||
|
/* #undef _LIBCPP_HAS_NO_MONOTONIC_CLOCK */
|
||||||
|
-/* #undef _LIBCPP_HAS_MUSL_LIBC */
|
||||||
|
+#define _LIBCPP_HAS_MUSL_LIBC 1
|
||||||
|
/* #undef _LIBCPP_HAS_THREAD_API_PTHREAD */
|
||||||
|
/* #undef _LIBCPP_HAS_THREAD_API_EXTERNAL */
|
||||||
|
/* #undef _LIBCPP_HAS_THREAD_API_WIN32 */
|
|
@ -1,12 +1,13 @@
|
||||||
# Contributor: Aiden Grossman <agrossman154@yahoo.com>
|
# Contributor: Aiden Grossman <agrossman154@yahoo.com>
|
||||||
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
||||||
pkgname=freecad
|
pkgname=freecad
|
||||||
pkgver=0.21.0
|
pkgver=0.20.2
|
||||||
pkgrel=0
|
pkgrel=5
|
||||||
pkgdesc="Free and open source 3D parametric modeler"
|
pkgdesc="Free and open source 3D parametric modeler"
|
||||||
url="https://freecadweb.org/"
|
url="https://freecadweb.org/"
|
||||||
license="LGPL-2.0-or-later"
|
license="LGPL-2.0-or-later"
|
||||||
arch="x86_64" # dependency OpenCascade is only x86_64
|
arch="" # removed dependency py3-pyside2
|
||||||
|
#arch="x86_64" # dependency OpenCascade is only x86_64
|
||||||
depends="
|
depends="
|
||||||
graphviz
|
graphviz
|
||||||
hdf5
|
hdf5
|
||||||
|
@ -44,11 +45,16 @@ makedepends="
|
||||||
vtk-dev
|
vtk-dev
|
||||||
xerces-c-dev
|
xerces-c-dev
|
||||||
"
|
"
|
||||||
options="!check" # Failing test units upstream as well
|
|
||||||
checkdepends="xvfb-run mesa mesa-dri-gallium font-opensans"
|
checkdepends="xvfb-run mesa mesa-dri-gallium font-opensans"
|
||||||
source="https://github.com/FreeCAD/FreeCAD/archive/$pkgver/freecad-$pkgver.tar.gz
|
source="https://github.com/FreeCAD/FreeCAD/archive/$pkgver/freecad-$pkgver.tar.gz
|
||||||
$pkgname-cstdint.patch::https://github.com/FreeCAD/FreeCAD/commit/f8f02f089537497a1bf46bc1057f01659b6636c1.patch
|
$pkgname-python3.11-1.patch::https://github.com/FreeCAD/FreeCAD/commit/fe02d63c8c9b1280978be841d04e68a0a55cceb9.patch
|
||||||
|
numpy-1.20.patch
|
||||||
no-execinfo.patch
|
no-execinfo.patch
|
||||||
|
no-workaround-spnav.patch
|
||||||
|
resourceDirectory.patch
|
||||||
|
tests.patch
|
||||||
|
opencascade-7.8.0.patch
|
||||||
|
missing-include-cstdint.patch
|
||||||
"
|
"
|
||||||
builddir="$srcdir/FreeCAD-$pkgver"
|
builddir="$srcdir/FreeCAD-$pkgver"
|
||||||
|
|
||||||
|
@ -90,7 +96,13 @@ package() {
|
||||||
}
|
}
|
||||||
|
|
||||||
sha512sums="
|
sha512sums="
|
||||||
f5b4428217d9abd18aed1dcd8a5c77132b90173d07627ff9164919a87f04d242f9d616e9655751ec06ff57fc3e242090cc4d7e1d7045fdae9bc2e281e7855281 freecad-0.21.0.tar.gz
|
c3acd77dd2bb9a2a23ac354da3b6102effb89c95d675e91421d65486414dfe8cc0188a7212245e0deb63f17b9c5df76133017be09e4cd14b833be8cbec52a08d freecad-0.20.2.tar.gz
|
||||||
27dffdbb124096e7fcbec3589cdcfc587ea09bf039c1c1108edb68a9a4fd1278f66a39642636f98b8759a44da92485fd748f8b3d615b0625bc37fc717130e237 freecad-cstdint.patch
|
75a237f7ed7a89a98c0e5bdb3d3f0788749602daf718089aa0814e05f93ced1e15ad5867c7c87f170b48c5984f9ace1bbc95c4f386ce72bfb8d616323b47f1e5 freecad-python3.11-1.patch
|
||||||
|
80b08b031810fce7b6d698c662f64fa4f8a904f283f46b478b1d718529164c0ee61ce190f633abf04e03212720480f3f0603b0c1e160af79d7b6bb82da3bd0e4 numpy-1.20.patch
|
||||||
73aaba7015dce7048eb7d2456131b5b5ba4673cc980503331987be54d99daed5f61db015ca33d7d2ef0f02bd3192da8ce122c103c3b93f9959927deb4f0b933e no-execinfo.patch
|
73aaba7015dce7048eb7d2456131b5b5ba4673cc980503331987be54d99daed5f61db015ca33d7d2ef0f02bd3192da8ce122c103c3b93f9959927deb4f0b933e no-execinfo.patch
|
||||||
|
15696bdaaf77482f1b5d3806535a8004c8cec7d598d62092d9f0394b4ca9e2ad6cedd77c4b86a83a06324d16678c1c6bbf3a390b807729717a2f513e858afd50 no-workaround-spnav.patch
|
||||||
|
8ba13b17bad66316757d180c1b9e9e72a24382627eac7c43a2264b3b5101e6e8f701775f2b805ed733f500fbcd8b0e8e422ec58a9ab3d948d613b666157d4c52 resourceDirectory.patch
|
||||||
|
5db19e0aa2ca1fd21f4c56afc9db54390a799262aaa0a741704c2c304b0068fd6ca1dcc086465e12e9c0cfe06aac750aaf9b8f5f4db324539af4dd3394803ff9 tests.patch
|
||||||
|
f933680dea8744e147f38abce389cb7fd0ec3fb3566454fdd5e6ea07b2faaac5fe61aabe1df3bda9f0d7b4fca16055aa2ad700e9cce10d2604ae37b761b68ade opencascade-7.8.0.patch
|
||||||
|
fec515cc63830f0e715527c7890173705b24e7d99d225821ec4300104cf3affdee49243bbd4d0a331a902cf04db756a1b8f18f0a17cc71f5757f8b5c73c78ede missing-include-cstdint.patch
|
||||||
"
|
"
|
||||||
|
|
11
backports/freecad/missing-include-cstdint.patch
Normal file
11
backports/freecad/missing-include-cstdint.patch
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
diff --color -rupN a/src/3rdParty/libE57Format/include/E57Format.h b/src/3rdParty/libE57Format/include/E57Format.h
|
||||||
|
--- a/src/3rdParty/libE57Format/include/E57Format.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/3rdParty/libE57Format/include/E57Format.h 2024-02-27 14:06:29.308892531 +0100
|
||||||
|
@@ -32,6 +32,7 @@
|
||||||
|
//! @file E57Format.h header file for the E57 API
|
||||||
|
|
||||||
|
#include <cfloat>
|
||||||
|
+#include <cstdint>
|
||||||
|
#include <memory>
|
||||||
|
#include <vector>
|
||||||
|
|
69
backports/freecad/no-workaround-spnav.patch
Normal file
69
backports/freecad/no-workaround-spnav.patch
Normal file
|
@ -0,0 +1,69 @@
|
||||||
|
Patch-Source: https://github.com/FreeCAD/FreeCAD/commit/7b377a216b9185960e4cee980a6504dc1a755f50
|
||||||
|
fixes stderr reassignment
|
||||||
|
--
|
||||||
|
From 7b377a216b9185960e4cee980a6504dc1a755f50 Mon Sep 17 00:00:00 2001
|
||||||
|
From: wmayer <wmayer@users.sourceforge.net>
|
||||||
|
Date: Wed, 29 Jun 2022 15:19:18 +0200
|
||||||
|
Subject: [PATCH] Gui: remove workaround for spnav 0.23 due to build failure
|
||||||
|
with musl libc
|
||||||
|
|
||||||
|
---
|
||||||
|
src/Gui/3Dconnexion/GuiNativeEventLinux.cpp | 27 ---------------------
|
||||||
|
1 file changed, 27 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/Gui/3Dconnexion/GuiNativeEventLinux.cpp b/src/Gui/3Dconnexion/GuiNativeEventLinux.cpp
|
||||||
|
index 7f0ddd75d262..455ece0b36bd 100644
|
||||||
|
--- a/src/Gui/3Dconnexion/GuiNativeEventLinux.cpp
|
||||||
|
+++ b/src/Gui/3Dconnexion/GuiNativeEventLinux.cpp
|
||||||
|
@@ -21,42 +21,17 @@
|
||||||
|
***************************************************************************/
|
||||||
|
|
||||||
|
#include <FCConfig.h>
|
||||||
|
-#include <cstdio>
|
||||||
|
|
||||||
|
#include "GuiNativeEventLinux.h"
|
||||||
|
|
||||||
|
#include "GuiApplicationNativeEventAware.h"
|
||||||
|
#include <Base/Console.h>
|
||||||
|
-#include <Base/FileInfo.h>
|
||||||
|
#include <QMainWindow>
|
||||||
|
|
||||||
|
#include <QSocketNotifier>
|
||||||
|
|
||||||
|
#include <spnav.h>
|
||||||
|
|
||||||
|
-namespace {
|
||||||
|
-class RedirectStdErr
|
||||||
|
-{
|
||||||
|
-public:
|
||||||
|
- RedirectStdErr()
|
||||||
|
- : fi(Base::FileInfo::getTempFileName())
|
||||||
|
- , file(stderr)
|
||||||
|
- {
|
||||||
|
- stderr = fopen(fi.filePath().c_str(), "w");
|
||||||
|
- }
|
||||||
|
- ~RedirectStdErr()
|
||||||
|
- {
|
||||||
|
- fclose(stderr);
|
||||||
|
- fi.deleteFile();
|
||||||
|
- stderr = file;
|
||||||
|
- }
|
||||||
|
-
|
||||||
|
-private:
|
||||||
|
- Base::FileInfo fi;
|
||||||
|
- FILE* file;
|
||||||
|
-};
|
||||||
|
-}
|
||||||
|
-
|
||||||
|
Gui::GuiNativeEvent::GuiNativeEvent(Gui::GUIApplicationNativeEventAware *app)
|
||||||
|
: GuiAbstractNativeEvent(app)
|
||||||
|
{
|
||||||
|
@@ -72,8 +47,6 @@ Gui::GuiNativeEvent::~GuiNativeEvent()
|
||||||
|
|
||||||
|
void Gui::GuiNativeEvent::initSpaceball(QMainWindow *window)
|
||||||
|
{
|
||||||
|
- // tmp. redirect stderr to a file to suppress an error message from spnav_open()
|
||||||
|
- RedirectStdErr err;
|
||||||
|
Q_UNUSED(window)
|
||||||
|
if (spnav_open() == -1) {
|
||||||
|
Base::Console().Log("Couldn't connect to spacenav daemon. Please ignore if you don't have a spacemouse.\n");
|
25
backports/freecad/numpy-1.20.patch
Normal file
25
backports/freecad/numpy-1.20.patch
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
Patch-Source: https://github.com/FreeCAD/FreeCAD/commit/8b0df1dc936b544091f6a2d68df1c1a14ae3de5b
|
||||||
|
--
|
||||||
|
From 8b0df1dc936b544091f6a2d68df1c1a14ae3de5b Mon Sep 17 00:00:00 2001
|
||||||
|
From: lorenz <looooo@users.noreply.github.com>
|
||||||
|
Date: Tue, 27 Dec 2022 04:59:35 +0100
|
||||||
|
Subject: [PATCH] FEM: femmesh: fix AttributeError: module 'numpy' has no
|
||||||
|
attribute 'int'
|
||||||
|
|
||||||
|
---
|
||||||
|
src/Mod/Fem/femmesh/meshtools.py | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/src/Mod/Fem/femmesh/meshtools.py b/src/Mod/Fem/femmesh/meshtools.py
|
||||||
|
index dd8671b..d2e2b0a 100644
|
||||||
|
--- a/src/Mod/Fem/femmesh/meshtools.py
|
||||||
|
+++ b/src/Mod/Fem/femmesh/meshtools.py
|
||||||
|
@@ -485,7 +485,7 @@ def get_femelement_sets(
|
||||||
|
# fem_objects = FreeCAD FEM document objects
|
||||||
|
# get femelements for reference shapes of each obj.References
|
||||||
|
count_femelements = 0
|
||||||
|
- referenced_femelements = np.zeros((max(femelement_table.keys())+1,),dtype=np.int)
|
||||||
|
+ referenced_femelements = np.zeros((max(femelement_table.keys())+1,),dtype=int)
|
||||||
|
has_remaining_femelements = None
|
||||||
|
for fem_object_i, fem_object in enumerate(fem_objects):
|
||||||
|
obj = fem_object["Object"]
|
877
backports/freecad/opencascade-7.8.0.patch
Normal file
877
backports/freecad/opencascade-7.8.0.patch
Normal file
|
@ -0,0 +1,877 @@
|
||||||
|
Fix compilation with opencascase 7.8.0
|
||||||
|
|
||||||
|
Base on https://github.com/FreeCAD/FreeCAD/pull/11909
|
||||||
|
|
||||||
|
diff --color -rupN a/cMake/FindOCC.cmake b/cMake/FindOCC.cmake
|
||||||
|
--- a/cMake/FindOCC.cmake 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/cMake/FindOCC.cmake 2024-02-27 15:00:48.248873883 +0100
|
||||||
|
@@ -127,8 +127,6 @@ if(OCC_FOUND)
|
||||||
|
TKG2d
|
||||||
|
TKG3d
|
||||||
|
TKMath
|
||||||
|
- TKIGES
|
||||||
|
- TKSTL
|
||||||
|
TKShHealing
|
||||||
|
TKXSBase
|
||||||
|
TKBool
|
||||||
|
@@ -139,10 +137,6 @@ if(OCC_FOUND)
|
||||||
|
TKGeomBase
|
||||||
|
TKOffset
|
||||||
|
TKPrim
|
||||||
|
- TKSTEPBase
|
||||||
|
- TKSTEPAttr
|
||||||
|
- TKSTEP209
|
||||||
|
- TKSTEP
|
||||||
|
TKHLR
|
||||||
|
TKFeat
|
||||||
|
)
|
||||||
|
@@ -154,17 +148,19 @@ if(OCC_FOUND)
|
||||||
|
TKLCAF
|
||||||
|
TKVCAF
|
||||||
|
TKCDF
|
||||||
|
- TKXDESTEP
|
||||||
|
- TKXDEIGES
|
||||||
|
TKMeshVS
|
||||||
|
TKService
|
||||||
|
TKV3d
|
||||||
|
)
|
||||||
|
- if(OCC_VERSION_STRING VERSION_LESS 6.7.3)
|
||||||
|
- list(APPEND OCC_OCAF_LIBRARIES TKAdvTools)
|
||||||
|
- elseif(NOT OCC_VERSION_STRING VERSION_LESS 7.5.0)
|
||||||
|
+ if(NOT OCC_VERSION_STRING VERSION_LESS 7.5.0)
|
||||||
|
list(APPEND OCC_OCAF_LIBRARIES TKRWMesh)
|
||||||
|
- endif(OCC_VERSION_STRING VERSION_LESS 6.7.3)
|
||||||
|
+ endif(NOT OCC_VERSION_STRING VERSION_LESS 7.5.0)
|
||||||
|
+ if(OCC_VERSION_STRING VERSION_LESS 7.8.0)
|
||||||
|
+ list(APPEND OCC_LIBRARIES TKIGES TKSTL TKSTEPBase TKSTEPAttr TKSTEP209 TKSTEP)
|
||||||
|
+ list(APPEND OCC_OCAF_LIBRARIES TKXDESTEP TKXDEIGES)
|
||||||
|
+ else(OCC_VERSION_STRING VERSION_LESS 7.8.0)
|
||||||
|
+ list(APPEND OCC_LIBRARIES TKDESTEP TKDEIGES TKDEGLTF TKDESTL)
|
||||||
|
+ endif(OCC_VERSION_STRING VERSION_LESS 7.8.0)
|
||||||
|
message(STATUS "-- Found OCE/OpenCASCADE version: ${OCC_VERSION_STRING}")
|
||||||
|
message(STATUS "-- OCE/OpenCASCADE include directory: ${OCC_INCLUDE_DIR}")
|
||||||
|
message(STATUS "-- OCE/OpenCASCADE shared libraries directory: ${OCC_LIBRARY_DIR}")
|
||||||
|
diff --color -rupN a/src/3rdParty/salomesmesh/inc/SMESHDS_DataMapOfShape.hxx b/src/3rdParty/salomesmesh/inc/SMESHDS_DataMapOfShape.hxx
|
||||||
|
--- a/src/3rdParty/salomesmesh/inc/SMESHDS_DataMapOfShape.hxx 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/3rdParty/salomesmesh/inc/SMESHDS_DataMapOfShape.hxx 2024-02-27 15:00:48.248873883 +0100
|
||||||
|
@@ -29,22 +29,35 @@
|
||||||
|
|
||||||
|
#include <TopoDS_Shape.hxx>
|
||||||
|
|
||||||
|
+#include <Standard_Version.hxx>
|
||||||
|
+
|
||||||
|
/*
|
||||||
|
* This method needed for instance NCollection_DataMap with TopoDS_Shape as key
|
||||||
|
*/
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
struct SMESHDS_Hasher
|
||||||
|
{
|
||||||
|
- static inline Standard_Boolean IsEqual(const TopoDS_Shape& S1,
|
||||||
|
- const TopoDS_Shape& S2)
|
||||||
|
- {
|
||||||
|
- return S1.IsSame(S2);
|
||||||
|
+ size_t operator()(const TopoDS_Shape& S) const noexcept {
|
||||||
|
+ return std::hash<TopoDS_Shape>{}(S);
|
||||||
|
}
|
||||||
|
- static inline Standard_Integer HashCode(const TopoDS_Shape& S,
|
||||||
|
- const Standard_Integer Upper)
|
||||||
|
- {
|
||||||
|
- return ::HashCode( S, Upper);
|
||||||
|
+ size_t operator()(const TopoDS_Shape& S1, const TopoDS_Shape& S2) const noexcept {
|
||||||
|
+ return S1.IsSame(S2);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
-
|
||||||
|
+#else
|
||||||
|
+struct SMESHDS_Hasher
|
||||||
|
+{
|
||||||
|
+static inline Standard_Boolean IsEqual(const TopoDS_Shape& S1,
|
||||||
|
+ const TopoDS_Shape& S2)
|
||||||
|
+{
|
||||||
|
+ return S1.IsSame(S2);
|
||||||
|
+}
|
||||||
|
+static inline Standard_Integer HashCode(const TopoDS_Shape& S,
|
||||||
|
+ const Standard_Integer Upper)
|
||||||
|
+{
|
||||||
|
+ return ::HashCode( S, Upper);
|
||||||
|
+}
|
||||||
|
+};
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
diff --color -rupN a/src/3rdParty/salomesmesh/inc/SMESH_MeshVSLink.hxx b/src/3rdParty/salomesmesh/inc/SMESH_MeshVSLink.hxx
|
||||||
|
--- a/src/3rdParty/salomesmesh/inc/SMESH_MeshVSLink.hxx 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/3rdParty/salomesmesh/inc/SMESH_MeshVSLink.hxx 2024-02-27 15:00:48.248873883 +0100
|
||||||
|
@@ -57,9 +57,6 @@
|
||||||
|
#ifndef _MeshVS_EntityType_HeaderFile
|
||||||
|
#include <MeshVS_EntityType.hxx>
|
||||||
|
#endif
|
||||||
|
-#ifndef _Standard_Address_HeaderFile
|
||||||
|
-#include <Standard_Address.hxx>
|
||||||
|
-#endif
|
||||||
|
#ifndef _TColStd_HArray1OfInteger_HeaderFile
|
||||||
|
#include <TColStd_HArray1OfInteger.hxx>
|
||||||
|
#endif
|
||||||
|
diff --color -rupN a/src/3rdParty/salomesmesh/inc/SMESH_SMESH.hxx b/src/3rdParty/salomesmesh/inc/SMESH_SMESH.hxx
|
||||||
|
--- a/src/3rdParty/salomesmesh/inc/SMESH_SMESH.hxx 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/3rdParty/salomesmesh/inc/SMESH_SMESH.hxx 2024-02-27 15:00:48.248873883 +0100
|
||||||
|
@@ -37,4 +37,5 @@
|
||||||
|
#define SMESH_EXPORT
|
||||||
|
#endif
|
||||||
|
|
||||||
|
+#include <Standard_Version.hxx>
|
||||||
|
#endif
|
||||||
|
diff --color -rupN a/src/3rdParty/salomesmesh/inc/SMESH_SequenceOfNode.hxx b/src/3rdParty/salomesmesh/inc/SMESH_SequenceOfNode.hxx
|
||||||
|
--- a/src/3rdParty/salomesmesh/inc/SMESH_SequenceOfNode.hxx 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/3rdParty/salomesmesh/inc/SMESH_SequenceOfNode.hxx 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -28,10 +28,11 @@
|
||||||
|
|
||||||
|
#include "SMESH_SMESH.hxx"
|
||||||
|
|
||||||
|
-#include <NCollection_DefineSequence.hxx>
|
||||||
|
#if OCC_VERSION_HEX >= 0x060703
|
||||||
|
#include <NCollection_IncAllocator.hxx>
|
||||||
|
#include <NCollection_Sequence.hxx>
|
||||||
|
+#else
|
||||||
|
+#include <NCollection_DefineSequence.hxx>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
typedef const SMDS_MeshNode* SMDS_MeshNodePtr;
|
||||||
|
diff --color -rupN a/src/3rdParty/salomesmesh/inc/SMESH_TypeDefs.hxx b/src/3rdParty/salomesmesh/inc/SMESH_TypeDefs.hxx
|
||||||
|
--- a/src/3rdParty/salomesmesh/inc/SMESH_TypeDefs.hxx 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/3rdParty/salomesmesh/inc/SMESH_TypeDefs.hxx 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -185,11 +185,18 @@ typedef std::vector< UVPtStruct > UVPtSt
|
||||||
|
|
||||||
|
// --------------------------------------------------------------------------------
|
||||||
|
// class SMESH_SequenceOfElemPtr
|
||||||
|
+#include <Standard_Version.hxx>
|
||||||
|
+#if OCC_VERSION_HEX >= 0x060703
|
||||||
|
+#include <NCollection_Sequence.hxx>
|
||||||
|
+#else
|
||||||
|
#include <NCollection_DefineSequence.hxx>
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
class SMDS_MeshElement;
|
||||||
|
|
||||||
|
typedef const SMDS_MeshElement* SMDS_MeshElementPtr;
|
||||||
|
+#define DEFINE_SEQUENCE(_ClassName_, _BaseCollection_, TheItemType) \
|
||||||
|
+typedef NCollection_Sequence<TheItemType > _ClassName_;
|
||||||
|
|
||||||
|
DEFINE_SEQUENCE (SMESH_SequenceOfElemPtr, SMESH_BaseCollectionElemPtr, SMDS_MeshElementPtr)
|
||||||
|
|
||||||
|
diff --color -rupN a/src/3rdParty/salomesmesh/src/DriverSTL/DriverSTL_R_SMDS_Mesh.cpp b/src/3rdParty/salomesmesh/src/DriverSTL/DriverSTL_R_SMDS_Mesh.cpp
|
||||||
|
--- a/src/3rdParty/salomesmesh/src/DriverSTL/DriverSTL_R_SMDS_Mesh.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/3rdParty/salomesmesh/src/DriverSTL/DriverSTL_R_SMDS_Mesh.cpp 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -33,10 +33,33 @@
|
||||||
|
#include "SMDS_MeshNode.hxx"
|
||||||
|
#include "SMESH_File.hxx"
|
||||||
|
|
||||||
|
+#include <Standard_Version.hxx>
|
||||||
|
+
|
||||||
|
namespace
|
||||||
|
{
|
||||||
|
struct Hasher
|
||||||
|
{
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ size_t operator()(const gp_Pnt& point) const noexcept
|
||||||
|
+ {
|
||||||
|
+ union
|
||||||
|
+ {
|
||||||
|
+ Standard_Real R[3];
|
||||||
|
+ Standard_Integer I[6];
|
||||||
|
+ } U;
|
||||||
|
+
|
||||||
|
+ point.Coord( U.R[0], U.R[1], U.R[2] );
|
||||||
|
+ return std::hash<Standard_Integer>{}(U.I[0]/23+U.I[1]/19+U.I[2]/17+U.I[3]/13+U.I[4]/11+U.I[5]/7);
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ size_t operator()(const gp_Pnt& point1, const gp_Pnt& point2) const noexcept
|
||||||
|
+ {
|
||||||
|
+ static Standard_Real tab1[3], tab2[3];
|
||||||
|
+ point1.Coord(tab1[0],tab1[1],tab1[2]);
|
||||||
|
+ point2.Coord(tab2[0],tab2[1],tab2[2]);
|
||||||
|
+ return (memcmp(tab1,tab2,sizeof(tab1)) == 0);
|
||||||
|
+ }
|
||||||
|
+#else
|
||||||
|
//=======================================================================
|
||||||
|
//function : HashCode
|
||||||
|
//purpose :
|
||||||
|
@@ -51,9 +74,9 @@ namespace
|
||||||
|
} U;
|
||||||
|
|
||||||
|
point.Coord( U.R[0], U.R[1], U.R[2] );
|
||||||
|
-
|
||||||
|
- return ::HashCode(U.I[0]/23+U.I[1]/19+U.I[2]/17+U.I[3]/13+U.I[4]/11+U.I[5]/7,Upper);
|
||||||
|
+ return std::hash<Standard_Integer>{}(U.I[0]/23+U.I[1]/19+U.I[2]/17+U.I[3]/13+U.I[4]/11+U.I[5]/7);
|
||||||
|
}
|
||||||
|
+
|
||||||
|
//=======================================================================
|
||||||
|
//function : IsEqual
|
||||||
|
//purpose :
|
||||||
|
@@ -66,7 +89,9 @@ namespace
|
||||||
|
point2.Coord(tab2[0],tab2[1],tab2[2]);
|
||||||
|
return (memcmp(tab1,tab2,sizeof(tab1)) == 0);
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
};
|
||||||
|
+
|
||||||
|
typedef NCollection_DataMap<gp_Pnt,SMDS_MeshNode*,Hasher> TDataMapOfPntNodePtr;
|
||||||
|
|
||||||
|
const int HEADER_SIZE = 84;
|
||||||
|
diff --color -rupN a/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_Quadrangle_2D.cpp b/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_Quadrangle_2D.cpp
|
||||||
|
--- a/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_Quadrangle_2D.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_Quadrangle_2D.cpp 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -48,7 +48,6 @@
|
||||||
|
#include <Bnd_Box.hxx>
|
||||||
|
#include <GeomAPI_ProjectPointOnSurf.hxx>
|
||||||
|
#include <Geom_Surface.hxx>
|
||||||
|
-#include <NCollection_DefineArray2.hxx>
|
||||||
|
#include <Precision.hxx>
|
||||||
|
#include <Standard_Real.hxx>
|
||||||
|
#include <TColStd_SequenceOfInteger.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/Drawing/App/PreCompiled.h b/src/Mod/Drawing/App/PreCompiled.h
|
||||||
|
--- a/src/Mod/Drawing/App/PreCompiled.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Drawing/App/PreCompiled.h 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -70,7 +70,6 @@
|
||||||
|
#include <Standard_LicenseError.hxx>
|
||||||
|
#include <Standard_LicenseNotFound.hxx>
|
||||||
|
#include <Standard_Macro.hxx>
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
#include <Standard_MultiplyDefined.hxx>
|
||||||
|
#include <Standard_NegativeValue.hxx>
|
||||||
|
#include <Standard_NoMoreObject.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/Drawing/Gui/TaskDialog.cpp b/src/Mod/Drawing/Gui/TaskDialog.cpp
|
||||||
|
--- a/src/Mod/Drawing/Gui/TaskDialog.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Drawing/Gui/TaskDialog.cpp 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -29,7 +29,6 @@
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
#include "TaskDialog.h"
|
||||||
|
#include <Gui/Application.h>
|
||||||
|
#include <Gui/Command.h>
|
||||||
|
diff --color -rupN a/src/Mod/Fem/Gui/PreCompiled.h b/src/Mod/Fem/Gui/PreCompiled.h
|
||||||
|
--- a/src/Mod/Fem/Gui/PreCompiled.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Fem/Gui/PreCompiled.h 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -63,7 +63,6 @@
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// OCC
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
#include <Precision.hxx>
|
||||||
|
#include <TopoDS.hxx>
|
||||||
|
#include <BRepAdaptor_Surface.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/Fem/Gui/TaskCreateNodeSet.cpp b/src/Mod/Fem/Gui/TaskCreateNodeSet.cpp
|
||||||
|
--- a/src/Mod/Fem/Gui/TaskCreateNodeSet.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Fem/Gui/TaskCreateNodeSet.cpp 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -28,7 +28,6 @@
|
||||||
|
|
||||||
|
# include <SMESH_Mesh.hxx>
|
||||||
|
# include <SMESHDS_Mesh.hxx>
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <Base/Console.h>
|
||||||
|
diff --color -rupN a/src/Mod/Import/App/ImportOCAF.cpp b/src/Mod/Import/App/ImportOCAF.cpp
|
||||||
|
--- a/src/Mod/Import/App/ImportOCAF.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Import/App/ImportOCAF.cpp 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -165,7 +165,11 @@ void ImportOCAF::loadShapes(const TDF_La
|
||||||
|
std::vector<App::DocumentObject *> localValue;
|
||||||
|
|
||||||
|
if (aShapeTool->GetShape(label,aShape)) {
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ hash = std::hash<TopoDS_Shape>{}(aShape);
|
||||||
|
+#else
|
||||||
|
hash = aShape.HashCode(HashUpper);
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
Handle(TDataStd_Name) name;
|
||||||
|
@@ -235,7 +239,11 @@ void ImportOCAF::loadShapes(const TDF_La
|
||||||
|
if (isRef || myRefShapes.find(hash) == myRefShapes.end()) {
|
||||||
|
TopoDS_Shape aShape;
|
||||||
|
if (isRef && aShapeTool->GetShape(label, aShape))
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ myRefShapes.insert(std::hash<TopoDS_Shape>{}(aShape));
|
||||||
|
+#else
|
||||||
|
myRefShapes.insert(aShape.HashCode(HashUpper));
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
if (aShapeTool->IsSimpleShape(label) && (isRef || aShapeTool->IsFree(label))) {
|
||||||
|
if (!asm_name.empty())
|
||||||
|
@@ -565,7 +573,11 @@ void ImportXCAF::createShape(const TopoD
|
||||||
|
part->Label.setValue(default_name);
|
||||||
|
part->Shape.setValue(shape);
|
||||||
|
std::map<Standard_Integer, Quantity_ColorRGBA>::const_iterator jt;
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ jt = myColorMap.find(std::hash<TopoDS_Shape>{}(shape));
|
||||||
|
+#else
|
||||||
|
jt = myColorMap.find(shape.HashCode(INT_MAX));
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
App::Color partColor(0.8f,0.8f,0.8f);
|
||||||
|
#if 0//TODO
|
||||||
|
@@ -586,7 +598,11 @@ void ImportXCAF::createShape(const TopoD
|
||||||
|
// set label name if defined
|
||||||
|
if (setname && !myNameMap.empty()) {
|
||||||
|
std::map<Standard_Integer, std::string>::const_iterator jt;
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ jt = myNameMap.find(std::hash<TopoDS_Shape>{}(shape));
|
||||||
|
+#else
|
||||||
|
jt = myNameMap.find(shape.HashCode(INT_MAX));
|
||||||
|
+#endif
|
||||||
|
if (jt != myNameMap.end()) {
|
||||||
|
part->Label.setValue(jt->second);
|
||||||
|
}
|
||||||
|
@@ -606,7 +622,11 @@ void ImportXCAF::createShape(const TopoD
|
||||||
|
faceColors.resize(faces.Extent(), partColor);
|
||||||
|
xp.Init(shape,TopAbs_FACE);
|
||||||
|
while (xp.More()) {
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ jt = myColorMap.find(std::hash<TopoDS_Shape>{}(xp.Current()));
|
||||||
|
+#else
|
||||||
|
jt = myColorMap.find(xp.Current().HashCode(INT_MAX));
|
||||||
|
+#endif
|
||||||
|
if (jt != myColorMap.end()) {
|
||||||
|
int index = faces.FindIndex(xp.Current());
|
||||||
|
faceColors[index-1] = convertColor(jt->second);
|
||||||
|
@@ -641,23 +661,51 @@ void ImportXCAF::loadShapes(const TDF_La
|
||||||
|
// add the shapes
|
||||||
|
TopExp_Explorer xp;
|
||||||
|
for (xp.Init(aShape, TopAbs_SOLID); xp.More(); xp.Next(), ctSolids++)
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ this->mySolids[std::hash<TopoDS_Shape>{}(xp.Current())] = (xp.Current());
|
||||||
|
+#else
|
||||||
|
this->mySolids[xp.Current().HashCode(INT_MAX)] = (xp.Current());
|
||||||
|
+#endif
|
||||||
|
for (xp.Init(aShape, TopAbs_SHELL, TopAbs_SOLID); xp.More(); xp.Next(), ctShells++)
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ this->myShells[std::hash<TopoDS_Shape>{}(xp.Current())] = (xp.Current());
|
||||||
|
+#else
|
||||||
|
this->myShells[xp.Current().HashCode(INT_MAX)] = (xp.Current());
|
||||||
|
+#endif
|
||||||
|
// if no solids and no shells were found then go for compounds
|
||||||
|
if (ctSolids == 0 && ctShells == 0) {
|
||||||
|
for (xp.Init(aShape, TopAbs_COMPOUND); xp.More(); xp.Next(), ctComps++)
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ this->myCompds[std::hash<TopoDS_Shape>{}(xp.Current())] = (xp.Current());
|
||||||
|
+#else
|
||||||
|
this->myCompds[xp.Current().HashCode(INT_MAX)] = (xp.Current());
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
if (ctComps == 0) {
|
||||||
|
for (xp.Init(aShape, TopAbs_FACE, TopAbs_SHELL); xp.More(); xp.Next())
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ this->myShapes[std::hash<TopoDS_Shape>{}(xp.Current())] = (xp.Current());
|
||||||
|
+#else
|
||||||
|
this->myShapes[xp.Current().HashCode(INT_MAX)] = (xp.Current());
|
||||||
|
+#endif
|
||||||
|
for (xp.Init(aShape, TopAbs_WIRE, TopAbs_FACE); xp.More(); xp.Next())
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ this->myShapes[std::hash<TopoDS_Shape>{}(xp.Current())] = (xp.Current());
|
||||||
|
+#else
|
||||||
|
this->myShapes[xp.Current().HashCode(INT_MAX)] = (xp.Current());
|
||||||
|
+#endif
|
||||||
|
for (xp.Init(aShape, TopAbs_EDGE, TopAbs_WIRE); xp.More(); xp.Next())
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ this->myShapes[std::hash<TopoDS_Shape>{}(xp.Current())] = (xp.Current());
|
||||||
|
+#else
|
||||||
|
this->myShapes[xp.Current().HashCode(INT_MAX)] = (xp.Current());
|
||||||
|
+#endif
|
||||||
|
for (xp.Init(aShape, TopAbs_VERTEX, TopAbs_EDGE); xp.More(); xp.Next())
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ this->myShapes[std::hash<TopoDS_Shape>{}(xp.Current())] = (xp.Current());
|
||||||
|
+#else
|
||||||
|
this->myShapes[xp.Current().HashCode(INT_MAX)] = (xp.Current());
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -667,7 +715,11 @@ void ImportXCAF::loadShapes(const TDF_La
|
||||||
|
hColors->GetColor(label, XCAFDoc_ColorSurf, col) ||
|
||||||
|
hColors->GetColor(label, XCAFDoc_ColorCurv, col)) {
|
||||||
|
// add defined color
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ myColorMap[std::hash<TopoDS_Shape>{}(aShape)] = col;
|
||||||
|
+#else
|
||||||
|
myColorMap[aShape.HashCode(INT_MAX)] = col;
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
// http://www.opencascade.org/org/forum/thread_17107/
|
||||||
|
@@ -677,7 +729,11 @@ void ImportXCAF::loadShapes(const TDF_La
|
||||||
|
hColors->GetColor(it.Value(), XCAFDoc_ColorSurf, col) ||
|
||||||
|
hColors->GetColor(it.Value(), XCAFDoc_ColorCurv, col)) {
|
||||||
|
// add defined color
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ myColorMap[std::hash<TopoDS_Shape>{}(it.Value())] = col;
|
||||||
|
+#else
|
||||||
|
myColorMap[it.Value().HashCode(INT_MAX)] = col;
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@@ -690,7 +746,11 @@ void ImportXCAF::loadShapes(const TDF_La
|
||||||
|
extstr.ToUTF8CString(str);
|
||||||
|
std::string labelName(str);
|
||||||
|
if (!labelName.empty())
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ myNameMap[std::hash<TopoDS_Shape>{}(aShape)] = labelName;
|
||||||
|
+#else
|
||||||
|
myNameMap[aShape.HashCode(INT_MAX)] = labelName;
|
||||||
|
+#endif
|
||||||
|
delete [] str;
|
||||||
|
}
|
||||||
|
|
||||||
|
diff --color -rupN a/src/Mod/Import/App/ImportOCAF.h b/src/Mod/Import/App/ImportOCAF.h
|
||||||
|
--- a/src/Mod/Import/App/ImportOCAF.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Import/App/ImportOCAF.h 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -29,7 +29,6 @@
|
||||||
|
#include <XCAFDoc_ShapeTool.hxx>
|
||||||
|
#include <Quantity_ColorRGBA.hxx>
|
||||||
|
#include <TopoDS_Shape.hxx>
|
||||||
|
-#include <TDF_LabelMapHasher.hxx>
|
||||||
|
#include <climits>
|
||||||
|
#include <string>
|
||||||
|
#include <set>
|
||||||
|
diff --color -rupN a/src/Mod/Import/App/ImportOCAF2.h b/src/Mod/Import/App/ImportOCAF2.h
|
||||||
|
--- a/src/Mod/Import/App/ImportOCAF2.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Import/App/ImportOCAF2.h 2024-02-27 15:06:12.358890276 +0100
|
||||||
|
@@ -27,7 +27,6 @@
|
||||||
|
#include <XCAFDoc_ColorTool.hxx>
|
||||||
|
#include <XCAFDoc_ShapeTool.hxx>
|
||||||
|
#include <TopoDS_Shape.hxx>
|
||||||
|
-#include <TDF_LabelMapHasher.hxx>
|
||||||
|
#include <climits>
|
||||||
|
#include <string>
|
||||||
|
#include <set>
|
||||||
|
@@ -57,13 +56,21 @@ namespace Import {
|
||||||
|
|
||||||
|
struct ShapeHasher {
|
||||||
|
std::size_t operator()(const TopoDS_Shape &s) const {
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ return std::hash<TopoDS_Shape>{}(s);
|
||||||
|
+#else
|
||||||
|
return s.HashCode(INT_MAX);
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
struct LabelHasher {
|
||||||
|
std::size_t operator()(const TDF_Label &l) const {
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ return std::hash<TDF_Label> {}(l);
|
||||||
|
+#else
|
||||||
|
return TDF_LabelMapHasher::HashCode(l,INT_MAX);
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
diff --color -rupN a/src/Mod/MeshPart/App/CurveProjector.h b/src/Mod/MeshPart/App/CurveProjector.h
|
||||||
|
--- a/src/Mod/MeshPart/App/CurveProjector.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/MeshPart/App/CurveProjector.h 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -20,6 +20,7 @@
|
||||||
|
* *
|
||||||
|
***************************************************************************/
|
||||||
|
|
||||||
|
+#include <Standard_Version.hxx>
|
||||||
|
|
||||||
|
#ifndef _CurveProjector_h_
|
||||||
|
#define _CurveProjector_h_
|
||||||
|
@@ -64,8 +65,13 @@ public:
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
struct TopoDSLess {
|
||||||
|
- bool operator()(const T& x, const T& y) const {
|
||||||
|
- return x.HashCode(INT_MAX-1) < y.HashCode(INT_MAX-1);
|
||||||
|
+ bool operator()(const T& x, const T& y) const {
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ std::hash<T> hasher;
|
||||||
|
+ return hasher(x) < hasher(y);
|
||||||
|
+#else
|
||||||
|
+ return x.HashCode(INT_MAX-1) < y.HashCode(INT_MAX-1);
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
diff --color -rupN a/src/Mod/MeshPart/App/PreCompiled.h b/src/Mod/MeshPart/App/PreCompiled.h
|
||||||
|
--- a/src/Mod/MeshPart/App/PreCompiled.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/MeshPart/App/PreCompiled.h 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -76,7 +76,6 @@
|
||||||
|
#include <Standard_LicenseError.hxx>
|
||||||
|
#include <Standard_LicenseNotFound.hxx>
|
||||||
|
#include <Standard_Macro.hxx>
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
#include <Standard_MultiplyDefined.hxx>
|
||||||
|
#include <Standard_NegativeValue.hxx>
|
||||||
|
#include <Standard_NoMoreObject.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/MeshPart/Gui/CrossSections.cpp b/src/Mod/MeshPart/Gui/CrossSections.cpp
|
||||||
|
--- a/src/Mod/MeshPart/Gui/CrossSections.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/MeshPart/Gui/CrossSections.cpp 2024-02-27 15:00:48.252207183 +0100
|
||||||
|
@@ -24,7 +24,6 @@
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
#ifndef _PreComp_
|
||||||
|
# include <sstream>
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
# include <BRep_Builder.hxx>
|
||||||
|
# include <BRepBuilderAPI_MakePolygon.hxx>
|
||||||
|
# include <TopoDS.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/Part/App/ImportStep.cpp b/src/Mod/Part/App/ImportStep.cpp
|
||||||
|
--- a/src/Mod/Part/App/ImportStep.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/App/ImportStep.cpp 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -167,7 +167,12 @@ int Part::ImportStepParts(App::Document
|
||||||
|
// This is a trick to access the GUI via Python and set the color property
|
||||||
|
// of the associated view provider. If no GUI is up an exception is thrown
|
||||||
|
// and cleared immediately
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ std::hash<TopoDS_Solid> hasher;
|
||||||
|
+ std::map<int, Quantity_Color>::iterator it = hash_col.find(hasher(aSolid));
|
||||||
|
+#else
|
||||||
|
std::map<int, Quantity_Color>::iterator it = hash_col.find(aSolid.HashCode(INT_MAX));
|
||||||
|
+#endif
|
||||||
|
if (it != hash_col.end()) {
|
||||||
|
try {
|
||||||
|
Py::Object obj(pcFeature->getPyObject(), true);
|
||||||
|
diff --color -rupN a/src/Mod/Part/App/OCCError.h b/src/Mod/Part/App/OCCError.h
|
||||||
|
--- a/src/Mod/Part/App/OCCError.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/App/OCCError.h 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -50,7 +50,6 @@
|
||||||
|
# include <Standard_Overflow.hxx>
|
||||||
|
# include <Standard_ProgramError.hxx>
|
||||||
|
# include <Standard_RangeError.hxx>
|
||||||
|
-# include <Standard_TooManyUsers.hxx>
|
||||||
|
# include <Standard_TypeMismatch.hxx>
|
||||||
|
# include <Standard_Underflow.hxx>
|
||||||
|
|
||||||
|
diff --color -rupN a/src/Mod/Part/App/OpenCascadeAll.h b/src/Mod/Part/App/OpenCascadeAll.h
|
||||||
|
--- a/src/Mod/Part/App/OpenCascadeAll.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/App/OpenCascadeAll.h 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -49,7 +49,6 @@
|
||||||
|
#include <Standard_LicenseError.hxx>
|
||||||
|
#include <Standard_LicenseNotFound.hxx>
|
||||||
|
#include <Standard_Macro.hxx>
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
#include <Standard_MultiplyDefined.hxx>
|
||||||
|
#include <Standard_NegativeValue.hxx>
|
||||||
|
#include <Standard_NoMoreObject.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/Part/App/TopoShapePyImp.cpp b/src/Mod/Part/App/TopoShapePyImp.cpp
|
||||||
|
--- a/src/Mod/Part/App/TopoShapePyImp.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/App/TopoShapePyImp.cpp 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -1321,7 +1321,11 @@ PyObject* TopoShapePy::ancestorsOfType(
|
||||||
|
TopTools_ListIteratorOfListOfShape it(ancestors);
|
||||||
|
for (; it.More(); it.Next()) {
|
||||||
|
// make sure to avoid duplicates
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ const size_t code = std::hash<TopoDS_Shape>{}(static_cast<TopoDS_Shape>(it.Value()));
|
||||||
|
+#else
|
||||||
|
Standard_Integer code = it.Value().HashCode(INT_MAX);
|
||||||
|
+#endif
|
||||||
|
if (hashes.find(code) == hashes.end()) {
|
||||||
|
list.append(shape2pyshape(it.Value()));
|
||||||
|
hashes.insert(code);
|
||||||
|
@@ -1943,7 +1947,11 @@ PyObject* TopoShapePy::hashCode(PyObject
|
||||||
|
if (!PyArg_ParseTuple(args, "|i",&upper))
|
||||||
|
return nullptr;
|
||||||
|
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ int hc = std::hash<TopoDS_Shape>{}(getTopoShapePtr()->getShape());
|
||||||
|
+#else
|
||||||
|
int hc = getTopoShapePtr()->getShape().HashCode(upper);
|
||||||
|
+#endif
|
||||||
|
return Py_BuildValue("i", hc);
|
||||||
|
}
|
||||||
|
|
||||||
|
diff --color -rupN a/src/Mod/Part/Gui/AppPartGui.cpp b/src/Mod/Part/Gui/AppPartGui.cpp
|
||||||
|
--- a/src/Mod/Part/Gui/AppPartGui.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/Gui/AppPartGui.cpp 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -11,9 +11,6 @@
|
||||||
|
|
||||||
|
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
-#ifndef _PreComp_
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
-#endif
|
||||||
|
|
||||||
|
#include <Base/Console.h>
|
||||||
|
#include <Base/Interpreter.h>
|
||||||
|
diff --color -rupN a/src/Mod/Part/Gui/Command.cpp b/src/Mod/Part/Gui/Command.cpp
|
||||||
|
--- a/src/Mod/Part/Gui/Command.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/Gui/Command.cpp 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -26,7 +26,6 @@
|
||||||
|
# include <QFileInfo>
|
||||||
|
# include <QPointer>
|
||||||
|
# include <QString>
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
# include <Standard_Version.hxx>
|
||||||
|
# include <TopExp_Explorer.hxx>
|
||||||
|
# include <TopoDS_Shape.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/Part/Gui/CommandSimple.cpp b/src/Mod/Part/Gui/CommandSimple.cpp
|
||||||
|
--- a/src/Mod/Part/Gui/CommandSimple.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/Gui/CommandSimple.cpp 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -22,9 +22,6 @@
|
||||||
|
|
||||||
|
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
-#ifndef _PreComp_
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
-#endif
|
||||||
|
|
||||||
|
#include <App/Document.h>
|
||||||
|
#include <App/DocumentObject.h>
|
||||||
|
diff --color -rupN a/src/Mod/Part/Gui/CrossSections.cpp b/src/Mod/Part/Gui/CrossSections.cpp
|
||||||
|
--- a/src/Mod/Part/Gui/CrossSections.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/Gui/CrossSections.cpp 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -23,7 +23,6 @@
|
||||||
|
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
#ifndef _PreComp_
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
# include <BRep_Builder.hxx>
|
||||||
|
# include <BRepAlgoAPI_Section.hxx>
|
||||||
|
# include <BRepBuilderAPI_MakeWire.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/Part/Gui/ViewProvider2DObject.cpp b/src/Mod/Part/Gui/ViewProvider2DObject.cpp
|
||||||
|
--- a/src/Mod/Part/Gui/ViewProvider2DObject.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/Gui/ViewProvider2DObject.cpp 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -26,8 +26,6 @@
|
||||||
|
#ifndef _PreComp_
|
||||||
|
# include <cfloat>
|
||||||
|
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
-
|
||||||
|
# include <Inventor/nodes/SoAnnotation.h>
|
||||||
|
# include <Inventor/nodes/SoBaseColor.h>
|
||||||
|
# include <Inventor/nodes/SoDepthBuffer.h>
|
||||||
|
diff --color -rupN a/src/Mod/Part/Gui/ViewProviderExt.cpp b/src/Mod/Part/Gui/ViewProviderExt.cpp
|
||||||
|
--- a/src/Mod/Part/Gui/ViewProviderExt.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/Gui/ViewProviderExt.cpp 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -978,7 +978,11 @@ void ViewProviderPartExt::updateVisual()
|
||||||
|
|
||||||
|
TopExp_Explorer xp;
|
||||||
|
for (xp.Init(faceMap(i),TopAbs_EDGE);xp.More();xp.Next())
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ faceEdges.insert(std::hash<TopoDS_Shape>{}(xp.Current()));
|
||||||
|
+#else
|
||||||
|
faceEdges.insert(xp.Current().HashCode(INT_MAX));
|
||||||
|
+#endif
|
||||||
|
numFaces++;
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -1006,7 +1010,11 @@ void ViewProviderPartExt::updateVisual()
|
||||||
|
// So, we have to store the hashes of the edges associated to a face.
|
||||||
|
// If the hash of a given edge is not in this list we know it's really
|
||||||
|
// a free edge.
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ int hash = std::hash<TopoDS_Shape>{}(aEdge);
|
||||||
|
+#else
|
||||||
|
int hash = aEdge.HashCode(INT_MAX);
|
||||||
|
+#endif
|
||||||
|
if (faceEdges.find(hash) == faceEdges.end()) {
|
||||||
|
Handle(Poly_Polygon3D) aPoly = Part::Tools::polygonOfEdge(aEdge, aLoc);
|
||||||
|
if (!aPoly.IsNull()) {
|
||||||
|
@@ -1205,7 +1213,11 @@ void ViewProviderPartExt::updateVisual()
|
||||||
|
TopLoc_Location aLoc;
|
||||||
|
|
||||||
|
// handling of the free edge that are not associated to a face
|
||||||
|
+#if OCC_VERSION_HEX >= 0x070800
|
||||||
|
+ int hash = std::hash<TopoDS_Shape>{}(aEdge);
|
||||||
|
+#else
|
||||||
|
int hash = aEdge.HashCode(INT_MAX);
|
||||||
|
+#endif
|
||||||
|
if (faceEdges.find(hash) == faceEdges.end()) {
|
||||||
|
Handle(Poly_Polygon3D) aPoly = Part::Tools::polygonOfEdge(aEdge, aLoc);
|
||||||
|
if (!aPoly.IsNull()) {
|
||||||
|
diff --color -rupN a/src/Mod/Part/Gui/ViewProviderExt.h b/src/Mod/Part/Gui/ViewProviderExt.h
|
||||||
|
--- a/src/Mod/Part/Gui/ViewProviderExt.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/Gui/ViewProviderExt.h 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -24,7 +24,6 @@
|
||||||
|
#ifndef PARTGUI_VIEWPROVIDERPARTEXT_H
|
||||||
|
#define PARTGUI_VIEWPROVIDERPARTEXT_H
|
||||||
|
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
#include <Standard_Boolean.hxx>
|
||||||
|
#include <TopoDS_Shape.hxx>
|
||||||
|
#include <TopoDS_Face.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/Part/Gui/ViewProviderMirror.cpp b/src/Mod/Part/Gui/ViewProviderMirror.cpp
|
||||||
|
--- a/src/Mod/Part/Gui/ViewProviderMirror.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/Gui/ViewProviderMirror.cpp 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -27,7 +27,6 @@
|
||||||
|
# include <QAction>
|
||||||
|
# include <QMenu>
|
||||||
|
# include <QTimer>
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
# include <TopExp.hxx>
|
||||||
|
# include <TopTools_IndexedMapOfShape.hxx>
|
||||||
|
# include <TopTools_ListOfShape.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/Part/Gui/ViewProviderPython.cpp b/src/Mod/Part/Gui/ViewProviderPython.cpp
|
||||||
|
--- a/src/Mod/Part/Gui/ViewProviderPython.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/Gui/ViewProviderPython.cpp 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -23,7 +23,6 @@
|
||||||
|
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
#ifndef _PreComp_
|
||||||
|
# include <Inventor/nodes/SoSeparator.h>
|
||||||
|
#endif
|
||||||
|
diff --color -rupN a/src/Mod/Part/Gui/ViewProviderReference.h b/src/Mod/Part/Gui/ViewProviderReference.h
|
||||||
|
--- a/src/Mod/Part/Gui/ViewProviderReference.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Part/Gui/ViewProviderReference.h 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -24,7 +24,6 @@
|
||||||
|
#ifndef PARTGUI_ViewProviderPartReference_H
|
||||||
|
#define PARTGUI_ViewProviderPartReference_H
|
||||||
|
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
#include <Standard_Boolean.hxx>
|
||||||
|
#include <TopoDS_Shape.hxx>
|
||||||
|
#include <Gui/ViewProviderGeometryObject.h>
|
||||||
|
diff --color -rupN a/src/Mod/PartDesign/Gui/PreCompiled.h b/src/Mod/PartDesign/Gui/PreCompiled.h
|
||||||
|
--- a/src/Mod/PartDesign/Gui/PreCompiled.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/PartDesign/Gui/PreCompiled.h 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -44,7 +44,6 @@
|
||||||
|
#include <boost/bind/bind.hpp>
|
||||||
|
|
||||||
|
// OCC
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
#include <Standard_Version.hxx>
|
||||||
|
#include <Bnd_Box.hxx>
|
||||||
|
#include <BRepBndLib.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/Path/App/Voronoi.cpp b/src/Mod/Path/App/Voronoi.cpp
|
||||||
|
--- a/src/Mod/Path/App/Voronoi.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Path/App/Voronoi.cpp 2024-02-27 15:00:48.255540482 +0100
|
||||||
|
@@ -23,10 +23,6 @@
|
||||||
|
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
|
||||||
|
-#ifndef _PreComp_
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
-#endif
|
||||||
|
-
|
||||||
|
#include <Base/Vector3D.h>
|
||||||
|
|
||||||
|
#include "Voronoi.h"
|
||||||
|
diff --color -rupN a/src/Mod/Path/Gui/PreCompiled.h b/src/Mod/Path/Gui/PreCompiled.h
|
||||||
|
--- a/src/Mod/Path/Gui/PreCompiled.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Path/Gui/PreCompiled.h 2024-02-27 15:00:48.258873781 +0100
|
||||||
|
@@ -38,8 +38,6 @@
|
||||||
|
# define PathGuiExport
|
||||||
|
#endif
|
||||||
|
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
-
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
# pragma warning( disable : 4273 )
|
||||||
|
#endif
|
||||||
|
diff --color -rupN a/src/Mod/Robot/Gui/PreCompiled.h b/src/Mod/Robot/Gui/PreCompiled.h
|
||||||
|
--- a/src/Mod/Robot/Gui/PreCompiled.h 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Robot/Gui/PreCompiled.h 2024-02-27 15:00:48.258873781 +0100
|
||||||
|
@@ -39,8 +39,6 @@
|
||||||
|
# define RobotGuiExport
|
||||||
|
#endif
|
||||||
|
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
-
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
# pragma warning(disable : 4005)
|
||||||
|
# pragma warning(disable : 4273)
|
||||||
|
diff --color -rupN a/src/Mod/Sandbox/Gui/AppSandboxGui.cpp b/src/Mod/Sandbox/Gui/AppSandboxGui.cpp
|
||||||
|
--- a/src/Mod/Sandbox/Gui/AppSandboxGui.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Sandbox/Gui/AppSandboxGui.cpp 2024-02-27 15:00:48.258873781 +0100
|
||||||
|
@@ -24,7 +24,6 @@
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
#ifndef _PreComp_
|
||||||
|
# include <Python.h>
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
# include <Inventor/nodes/SoLineSet.h>
|
||||||
|
# include <Inventor/nodes/SoBaseColor.h>
|
||||||
|
# include <Inventor/nodes/SoSeparator.h>
|
||||||
|
diff --color -rupN a/src/Mod/Sketcher/App/SketchAnalysis.cpp b/src/Mod/Sketcher/App/SketchAnalysis.cpp
|
||||||
|
--- a/src/Mod/Sketcher/App/SketchAnalysis.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Sketcher/App/SketchAnalysis.cpp 2024-02-27 15:00:48.258873781 +0100
|
||||||
|
@@ -25,7 +25,6 @@
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
|
||||||
|
#ifndef _PreComp_
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
# include <BRep_Tool.hxx>
|
||||||
|
# include <gp_Pnt.hxx>
|
||||||
|
# include <Precision.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/Sketcher/Gui/DrawSketchHandler.cpp b/src/Mod/Sketcher/Gui/DrawSketchHandler.cpp
|
||||||
|
--- a/src/Mod/Sketcher/Gui/DrawSketchHandler.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Sketcher/Gui/DrawSketchHandler.cpp 2024-02-27 15:00:48.258873781 +0100
|
||||||
|
@@ -24,7 +24,6 @@
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
|
||||||
|
#ifndef _PreComp_
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
# include <Inventor/nodes/SoTranslation.h>
|
||||||
|
# include <Inventor/nodes/SoText2.h>
|
||||||
|
# include <Inventor/nodes/SoFont.h>
|
||||||
|
diff --color -rupN a/src/Mod/Sketcher/Gui/EditDatumDialog.cpp b/src/Mod/Sketcher/Gui/EditDatumDialog.cpp
|
||||||
|
--- a/src/Mod/Sketcher/Gui/EditDatumDialog.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Sketcher/Gui/EditDatumDialog.cpp 2024-02-27 15:00:48.258873781 +0100
|
||||||
|
@@ -23,7 +23,6 @@
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
|
||||||
|
#ifndef _PreComp_
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
/// Qt Include Files
|
||||||
|
# include <QApplication>
|
||||||
|
# include <QDialog>
|
||||||
|
diff --color -rupN a/src/Mod/Sketcher/Gui/TaskSketcherValidation.cpp b/src/Mod/Sketcher/Gui/TaskSketcherValidation.cpp
|
||||||
|
--- a/src/Mod/Sketcher/Gui/TaskSketcherValidation.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Sketcher/Gui/TaskSketcherValidation.cpp 2024-02-27 15:00:48.258873781 +0100
|
||||||
|
@@ -24,7 +24,6 @@
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
|
||||||
|
#ifndef _PreComp_
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
# include <QDoubleValidator>
|
||||||
|
# include <QLocale>
|
||||||
|
# include <QMessageBox>
|
||||||
|
diff --color -rupN a/src/Mod/Sketcher/Gui/ViewProviderPython.cpp b/src/Mod/Sketcher/Gui/ViewProviderPython.cpp
|
||||||
|
--- a/src/Mod/Sketcher/Gui/ViewProviderPython.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Sketcher/Gui/ViewProviderPython.cpp 2024-02-27 15:00:48.258873781 +0100
|
||||||
|
@@ -23,7 +23,6 @@
|
||||||
|
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
#ifndef _PreComp_
|
||||||
|
# include <Inventor/nodes/SoSeparator.h>
|
||||||
|
#endif
|
||||||
|
diff --color -rupN a/src/Mod/Sketcher/Gui/ViewProviderSketch.cpp b/src/Mod/Sketcher/Gui/ViewProviderSketch.cpp
|
||||||
|
--- a/src/Mod/Sketcher/Gui/ViewProviderSketch.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Sketcher/Gui/ViewProviderSketch.cpp 2024-02-27 15:00:48.258873781 +0100
|
||||||
|
@@ -24,7 +24,6 @@
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
|
||||||
|
#ifndef _PreComp_
|
||||||
|
-# include <Standard_math.hxx>
|
||||||
|
|
||||||
|
# include <Inventor/actions/SoGetBoundingBoxAction.h>
|
||||||
|
# include <Inventor/SbBox3f.h>
|
||||||
|
diff --color -rupN a/src/Mod/Surface/Gui/Command.cpp b/src/Mod/Surface/Gui/Command.cpp
|
||||||
|
--- a/src/Mod/Surface/Gui/Command.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/Surface/Gui/Command.cpp 2024-02-27 15:00:48.258873781 +0100
|
||||||
|
@@ -31,7 +31,6 @@
|
||||||
|
#include <QLineEdit>
|
||||||
|
#include <QMessageBox>
|
||||||
|
#include <QPointer>
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
#include <TopoDS_Shape.hxx>
|
||||||
|
#include <TopoDS_Edge.hxx>
|
||||||
|
#include <Geom_BezierCurve.hxx>
|
||||||
|
diff --color -rupN a/src/Mod/TechDraw/Gui/TaskProjection.cpp b/src/Mod/TechDraw/Gui/TaskProjection.cpp
|
||||||
|
--- a/src/Mod/TechDraw/Gui/TaskProjection.cpp 2022-12-07 03:35:37.000000000 +0100
|
||||||
|
+++ b/src/Mod/TechDraw/Gui/TaskProjection.cpp 2024-02-27 15:00:48.258873781 +0100
|
||||||
|
@@ -29,9 +29,6 @@
|
||||||
|
# include <QMessageBox>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
-
|
||||||
|
-#include <Standard_math.hxx>
|
||||||
|
-
|
||||||
|
#include <Gui/Application.h>
|
||||||
|
#include <Gui/BitmapFactory.h>
|
||||||
|
#include <Gui/Command.h>
|
11
backports/freecad/resourceDirectory.patch
Normal file
11
backports/freecad/resourceDirectory.patch
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
--- ./cMake/FreeCAD_Helpers/ConfigureCMakeVariables.cmake.orig
|
||||||
|
+++ ./cMake/FreeCAD_Helpers/ConfigureCMakeVariables.cmake
|
||||||
|
@@ -23,7 +23,7 @@
|
||||||
|
"Path to the directory containing PyCXX's cxxextensions.c source file")
|
||||||
|
|
||||||
|
# used as compiler defines
|
||||||
|
- set(RESOURCEDIR "${CMAKE_INSTALL_DATADIR}")
|
||||||
|
+ set(RESOURCEDIR "../../share/freecad")
|
||||||
|
set(LIBRARYDIR "${CMAKE_INSTALL_LIBDIR}")
|
||||||
|
set(DOCDIR "${CMAKE_INSTALL_DOCDIR}")
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
# Maintainer: Antoine Martin (ayakael) <dev@ayakael.net>
|
# Maintainer: Antoine Martin (ayakael) <dev@ayakael.net>
|
||||||
# Contributor: Antoine Martin (ayakael) <dev@ayakael.net>
|
# Contributor: Antoine Martin (ayakael) <dev@ayakael.net>
|
||||||
pkgname=freetube
|
pkgname=freetube
|
||||||
pkgver=0.20.0
|
pkgver=0.21.3
|
||||||
pkgrel=0
|
pkgrel=0
|
||||||
pkgdesc="An open source desktop YouTube player built with privacy in mind."
|
pkgdesc="An open source desktop YouTube player built with privacy in mind."
|
||||||
arch="x86_64 aarch64" # blocked by electron
|
arch="x86_64 aarch64" # blocked by electron
|
||||||
|
@ -50,7 +50,7 @@ package() {
|
||||||
}
|
}
|
||||||
|
|
||||||
sha512sums="
|
sha512sums="
|
||||||
b82cdaff82d7bd325f3127794160382c97be3b72c5ef4bb3f327a8ada6b609043bc30a1f6af59c38e23237aac7d8b6ea2685c22aa82469c8d08b96cb839a3099 freetube-0.20.0.tar.gz
|
22e5ab677cd442d50237b2d62534698d8ad73a37e1731003dc23c4ea3da992b3cae936f0bb3a0a86cd4b7fba731c9fa53276cb0a6cd5bab213ff2a6c9006cb05 freetube-0.21.3.tar.gz
|
||||||
2ce2effc794bb663789cefe968b5899122127983dbfa1b240aa33a2be383720b18204e6d01b4a550df72956f02b6636b79c93a58f470a970b09b770f5b8f2fc4 freetube.sh
|
2ce2effc794bb663789cefe968b5899122127983dbfa1b240aa33a2be383720b18204e6d01b4a550df72956f02b6636b79c93a58f470a970b09b770f5b8f2fc4 freetube.sh
|
||||||
d27cb896b65a7e8d52ffe86e5f74eed72b6cf976b28e1a13012d34c7eceba5ff6f20298017738dfa93c0336ffa52b8ee4da7e06b02747062898db7e678819526 tasje-dotdash.patch
|
d27cb896b65a7e8d52ffe86e5f74eed72b6cf976b28e1a13012d34c7eceba5ff6f20298017738dfa93c0336ffa52b8ee4da7e06b02747062898db7e678819526 tasje-dotdash.patch
|
||||||
"
|
"
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
||||||
pkgname=libmedc
|
pkgname=libmedc
|
||||||
pkgver=4.1.1
|
pkgver=4.1.1
|
||||||
pkgrel=1
|
pkgrel=3
|
||||||
pkgdesc="Open source library for numerical simulation"
|
pkgdesc="Open source library for numerical simulation"
|
||||||
url="https://www.salome-platform.org/"
|
url="https://www.salome-platform.org/"
|
||||||
arch="all"
|
arch="all"
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Maintainer: Anjandev Momi <anjan@momi.ca>
|
# Maintainer: Anjandev Momi <anjan@momi.ca>
|
||||||
pkgname=libnest2d
|
pkgname=libnest2d
|
||||||
pkgver=0.4
|
pkgver=0.4
|
||||||
pkgrel=5
|
pkgrel=6
|
||||||
pkgdesc="2D irregular bin packaging and nesting library written in modern C++"
|
pkgdesc="2D irregular bin packaging and nesting library written in modern C++"
|
||||||
url="https://github.com/tamasmeszaros/libnest2d"
|
url="https://github.com/tamasmeszaros/libnest2d"
|
||||||
arch="noarch"
|
arch="noarch"
|
||||||
|
|
93
backports/looking-glass/APKBUILD
Normal file
93
backports/looking-glass/APKBUILD
Normal file
|
@ -0,0 +1,93 @@
|
||||||
|
# Contributor: Rogério da Silva Yokomizo <me@ro.ger.io>
|
||||||
|
# Contributor: Antoine Martin (ayakael) <dev@ayakael.net>
|
||||||
|
# Maintainer: Rogério da Silva Yokomizo <me@ro.ger.io>
|
||||||
|
pkgname=looking-glass
|
||||||
|
_gittag=b7_git20240607
|
||||||
|
pkgver=7b_git20240607
|
||||||
|
pkgrel=0
|
||||||
|
pkgdesc="Allows the use of a KVM configured for VGA PCI Pass-through without an attached physical monitor, keyboard or mouse"
|
||||||
|
url="https://looking-glass.io/"
|
||||||
|
arch="x86_64"
|
||||||
|
license="GPL-2.0-or-later"
|
||||||
|
makedepends="
|
||||||
|
cmake
|
||||||
|
fontconfig-dev
|
||||||
|
libsamplerate-dev
|
||||||
|
libx11-dev
|
||||||
|
libxcursor-dev
|
||||||
|
libxfixes-dev
|
||||||
|
libxi-dev
|
||||||
|
libxinerama-dev
|
||||||
|
libxkbcommon-dev
|
||||||
|
libxpresent-dev
|
||||||
|
libxscrnsaver-dev
|
||||||
|
nettle-dev
|
||||||
|
obs-studio-dev
|
||||||
|
pipewire-dev
|
||||||
|
pulseaudio-dev
|
||||||
|
samurai
|
||||||
|
spice-dev
|
||||||
|
wayland-dev
|
||||||
|
wayland-protocols
|
||||||
|
"
|
||||||
|
source="$pkgname-$_gittag.tar.gz::https://lab.ilot.io/mirrors/looking-glass/-/releases/$_gittag/downloads/tarball/looking-glass-$_gittag.tar.gz
|
||||||
|
missing-includes.patch
|
||||||
|
obs-plugins-lib.patch
|
||||||
|
werror.patch
|
||||||
|
"
|
||||||
|
subpackages="$pkgname-obs $pkgname-module"
|
||||||
|
builddir="$srcdir/$pkgname-$_gittag"
|
||||||
|
options="!check" # There are no tests nor --version.
|
||||||
|
|
||||||
|
build() {
|
||||||
|
cmake -S client -B build-client -G Ninja \
|
||||||
|
-DENABLE_BACKTRACE=OFF \
|
||||||
|
-DOPTIMIZE_FOR_NATIVE=OFF \
|
||||||
|
-DCMAKE_INSTALL_PREFIX=/usr
|
||||||
|
|
||||||
|
cmake -S obs -B build-obs -G Ninja \
|
||||||
|
-DENABLE_BACKTRACE=OFF \
|
||||||
|
-DOPTIMIZE_FOR_NATIVE=OFF \
|
||||||
|
-DCMAKE_INSTALL_PREFIX=/usr
|
||||||
|
|
||||||
|
cmake --build build-client
|
||||||
|
cmake --build build-obs
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
DESTDIR="$pkgdir" cmake --install build-client
|
||||||
|
DESTDIR="$pkgdir" cmake --install build-obs
|
||||||
|
}
|
||||||
|
|
||||||
|
module() {
|
||||||
|
pkgdesc="Looking Glass kernel module (AKMS)"
|
||||||
|
depends="akms"
|
||||||
|
install_if="looking-glass=$pkgver-r$pkgrel"
|
||||||
|
_modver=$(awk -F "=" '{if($1=="PACKAGE_VERSION"){print $2}}' src/looking-glass-B6/module/dkms.conf | tr -d '"')
|
||||||
|
|
||||||
|
install -Dm644 "$builddir"/module/Makefile "$subpkgdir"/usr/src/looking-glass/Makefile
|
||||||
|
install -Dm644 "$builddir"/module/kvmfr* "$subpkgdir"/usr/src/looking-glass/.
|
||||||
|
|
||||||
|
cat ->> "$subpkgdir"/usr/src/looking-glass/AKMBUILD <<EOF
|
||||||
|
modname=kvmfr
|
||||||
|
modver=$pkgver
|
||||||
|
built_modules='kvmfr.ko'
|
||||||
|
EOF
|
||||||
|
|
||||||
|
chmod -R u=rwX,go=rX-w "$subpkgdir"/usr/src/looking-glass
|
||||||
|
mkdir -p "$subpkgdir"/etc/udev/rules.d
|
||||||
|
echo 'SUBSYSTEM=="kvmfr", OWNER="root", GROUP="kvm", MODE="0660"' > "$subpkgdir"/etc/udev/rules.d/99-kvmfr.rules
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
obs() {
|
||||||
|
pkgdesc="$pkgdesc (obs plugin)"
|
||||||
|
amove usr/lib/obs-plugins
|
||||||
|
}
|
||||||
|
|
||||||
|
sha512sums="
|
||||||
|
959f49c91dc7bb06dfae890547bfbd1c02bd4154f4ba1c898a12d15a3579658d65fcb9fc4b951c04180e17fc9151e551858e0fb60f20e3f1a72d19b86c7dc3db looking-glass-b7_git20240607.tar.gz
|
||||||
|
6d2449764a8316dd3c1b5cc0aa552671068f89ed2f95297f3c5256af8529b93e5ec7af8f979bd2e744fd09b11063e8a93f3ed26284f0e49294e467ca10f6e772 missing-includes.patch
|
||||||
|
33c5463412a16691f47d7833ebf81d7cf20c560a077dca141dcc9f02a5d6dfb676e483835f39a06012b114be9f509dda4614fe253bb1c72a0142e82dc265a5ca obs-plugins-lib.patch
|
||||||
|
b952d1fd284aed15bcfe7990f160dec3a4565fb5833ce339920f62de6bb46fbc09265a0a79fe80d212eecc6a1813614e1e193a8846c37e2afd18431dc3a89ca4 werror.patch
|
||||||
|
"
|
2
backports/looking-glass/looking-glass.post-deinstall
Normal file
2
backports/looking-glass/looking-glass.post-deinstall
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
#!/bin/sh
|
||||||
|
exec /usr/sbin/akms uninstall kvmfr
|
92
backports/looking-glass/missing-includes.patch
Normal file
92
backports/looking-glass/missing-includes.patch
Normal file
|
@ -0,0 +1,92 @@
|
||||||
|
--- a/repos/PureSpice/src/agent.c
|
||||||
|
+++ b/repos/PureSpice/src/agent.c
|
||||||
|
@@ -31,6 +31,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
#include <unistd.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
#include <assert.h>
|
||||||
|
|
||||||
|
#include <sys/ioctl.h>
|
||||||
|
--- a/repos/PureSpice/src/channel_cursor.c
|
||||||
|
+++ b/repos/PureSpice/src/channel_cursor.c
|
||||||
|
@@ -25,6 +25,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
#include "channel_cursor.h"
|
||||||
|
|
||||||
|
#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
|
||||||
|
#include "messages.h"
|
||||||
|
|
||||||
|
--- a/repos/PureSpice/src/channel_display.c
|
||||||
|
+++ b/repos/PureSpice/src/channel_display.c
|
||||||
|
@@ -19,6 +19,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
|
||||||
|
#include "purespice.h"
|
||||||
|
#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
|
||||||
|
#include "ps.h"
|
||||||
|
#include "log.h"
|
||||||
|
--- a/repos/PureSpice/src/channel_inputs.c
|
||||||
|
+++ b/repos/PureSpice/src/channel_inputs.c
|
||||||
|
@@ -25,6 +25,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
#include "messages.h"
|
||||||
|
|
||||||
|
#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
|
||||||
|
const SpiceLinkHeader * channelInputs_getConnectPacket(void)
|
||||||
|
{
|
||||||
|
--- a/repos/PureSpice/src/channel_main.c
|
||||||
|
+++ b/repos/PureSpice/src/channel_main.c
|
||||||
|
@@ -24,6 +24,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
#include "messages.h"
|
||||||
|
|
||||||
|
#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
|
||||||
|
struct ChannelMain
|
||||||
|
{
|
||||||
|
--- a/repos/PureSpice/src/channel_playback.c
|
||||||
|
+++ b/repos/PureSpice/src/channel_playback.c
|
||||||
|
@@ -26,6 +26,8 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
|
||||||
|
#include "messages.h"
|
||||||
|
|
||||||
|
+#include <string.h>
|
||||||
|
+
|
||||||
|
const SpiceLinkHeader * channelPlayback_getConnectPacket(void)
|
||||||
|
{
|
||||||
|
typedef struct
|
||||||
|
--- a/repos/PureSpice/src/channel_record.c
|
||||||
|
+++ b/repos/PureSpice/src/channel_record.c
|
||||||
|
@@ -26,6 +26,8 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
|
||||||
|
#include "messages.h"
|
||||||
|
|
||||||
|
+#include <string.h>
|
||||||
|
+
|
||||||
|
const SpiceLinkHeader * channelRecord_getConnectPacket(void)
|
||||||
|
{
|
||||||
|
typedef struct
|
||||||
|
--- a/repos/PureSpice/src/log.c
|
||||||
|
+++ b/repos/PureSpice/src/log.c
|
||||||
|
@@ -25,6 +25,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
|
||||||
|
#include <stdarg.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
+#include <string.h>
|
||||||
|
|
||||||
|
static void log_stdout(const char * file, unsigned int line,
|
||||||
|
const char * function, const char * format, ...)
|
||||||
|
--- a/repos/PureSpice/src/ps.c
|
||||||
|
+++ b/repos/PureSpice/src/ps.c
|
||||||
|
@@ -37,6 +37,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
#include <unistd.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
#include <assert.h>
|
||||||
|
#include <errno.h>
|
||||||
|
|
25
backports/looking-glass/module_1075-fix-build-linux64.patch
Normal file
25
backports/looking-glass/module_1075-fix-build-linux64.patch
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
From e32b292cc1ba089db6ed28e4d5eb0fc8cc4c2235 Mon Sep 17 00:00:00 2001
|
||||||
|
From: esi <git@esibun.net>
|
||||||
|
Date: Fri, 12 May 2023 16:28:01 -0400
|
||||||
|
Subject: [PATCH] [module] Fix build on Linux 6.4 (fixes #1075)
|
||||||
|
|
||||||
|
---
|
||||||
|
module/dkms.conf | 2 +-
|
||||||
|
module/kvmfr.c | 4 ++++
|
||||||
|
2 files changed, 5 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/module/kvmfr.c b/module/kvmfr.c
|
||||||
|
index ca0cca685..c711e000e 100644
|
||||||
|
--- a/module/kvmfr.c
|
||||||
|
+++ b/module/kvmfr.c
|
||||||
|
@@ -539,7 +539,11 @@ static int __init kvmfr_module_init(void)
|
||||||
|
if (kvmfr->major < 0)
|
||||||
|
goto out_free;
|
||||||
|
|
||||||
|
+#if LINUX_VERSION_CODE < KERNEL_VERSION(6, 4, 0)
|
||||||
|
kvmfr->pClass = class_create(THIS_MODULE, KVMFR_DEV_NAME);
|
||||||
|
+#else
|
||||||
|
+ kvmfr->pClass = class_create(KVMFR_DEV_NAME);
|
||||||
|
+#endif
|
||||||
|
if (IS_ERR(kvmfr->pClass))
|
||||||
|
goto out_unreg;
|
23
backports/looking-glass/module_1124-fix-build-linux610.patch
Normal file
23
backports/looking-glass/module_1124-fix-build-linux610.patch
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
From 7305ce36af211220419eeab302ff28793d515df2 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Geoffrey McRae <geoff@hostfission.com>
|
||||||
|
Date: Fri, 7 Jun 2024 19:01:38 +1000
|
||||||
|
Subject: [PATCH] [module] fix build on linux 6.10
|
||||||
|
|
||||||
|
Fixes #1124 - Thanks @pongo1231
|
||||||
|
---
|
||||||
|
module/dkms.conf | 2 +-
|
||||||
|
module/kvmfr.c | 1 +
|
||||||
|
2 files changed, 2 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/module/kvmfr.c b/module/kvmfr.c
|
||||||
|
index b5acd18de..c99a5d79c 100644
|
||||||
|
--- a/module/kvmfr.c
|
||||||
|
+++ b/module/kvmfr.c
|
||||||
|
@@ -30,6 +30,7 @@
|
||||||
|
#include <linux/highmem.h>
|
||||||
|
#include <linux/memremap.h>
|
||||||
|
#include <linux/version.h>
|
||||||
|
+#include <linux/vmalloc.h>
|
||||||
|
|
||||||
|
#include <asm/io.h>
|
||||||
|
|
12
backports/looking-glass/obs-plugins-lib.patch
Normal file
12
backports/looking-glass/obs-plugins-lib.patch
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
--- a/obs/CMakeLists.txt
|
||||||
|
+++ b/obs/CMakeLists.txt
|
||||||
|
@@ -84,7 +84,8 @@ target_link_libraries(looking-glass-obs
|
||||||
|
)
|
||||||
|
|
||||||
|
install(TARGETS looking-glass-obs
|
||||||
|
- LIBRARY DESTINATION ${OBS_PLUGIN_PREFIX}/${CMAKE_PROJECT_NAME}/bin/${OBS_PLUGIN_DIR}
|
||||||
|
+ # LIBRARY DESTINATION ${OBS_PLUGIN_PREFIX}/${CMAKE_PROJECT_NAME}/bin/${OBS_PLUGIN_DIR}
|
||||||
|
+ LIBRARY DESTINATION /usr/lib/obs-plugins
|
||||||
|
)
|
||||||
|
|
||||||
|
feature_summary(WHAT ENABLED_FEATURES DISABLED_FEATURES)
|
24
backports/looking-glass/werror.patch
Normal file
24
backports/looking-glass/werror.patch
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
diff --git a/client/CMakeLists.txt b/client/CMakeLists.txt
|
||||||
|
index 836f814..7047365 100644
|
||||||
|
--- a/client/CMakeLists.txt
|
||||||
|
+++ b/client/CMakeLists.txt
|
||||||
|
@@ -68,7 +68,6 @@ add_compile_options(
|
||||||
|
"-Wno-unused-parameter"
|
||||||
|
"$<$<COMPILE_LANGUAGE:C>:-Wstrict-prototypes>"
|
||||||
|
"$<$<C_COMPILER_ID:GNU>:-Wimplicit-fallthrough=2>"
|
||||||
|
- "-Werror"
|
||||||
|
"-Wfatal-errors"
|
||||||
|
"-ffast-math"
|
||||||
|
"-fdata-sections"
|
||||||
|
diff --git a/obs/CMakeLists.txt b/obs/CMakeLists.txt
|
||||||
|
index 0491e65..60b37ff 100644
|
||||||
|
--- a/obs/CMakeLists.txt
|
||||||
|
+++ b/obs/CMakeLists.txt
|
||||||
|
@@ -18,7 +18,6 @@ add_feature_info(ENABLE_BACKTRACE ENABLE_BACKTRACE "Backtrace support.")
|
||||||
|
|
||||||
|
add_compile_options(
|
||||||
|
"-Wall"
|
||||||
|
- "-Werror"
|
||||||
|
"-Wfatal-errors"
|
||||||
|
"-ffast-math"
|
||||||
|
"-fdata-sections"
|
|
@ -79,9 +79,6 @@ build() {
|
||||||
case "$CARCH" in
|
case "$CARCH" in
|
||||||
aarch64*) _target="linux-aarch64" ;;
|
aarch64*) _target="linux-aarch64" ;;
|
||||||
arm*) _target="linux-armv4" ;;
|
arm*) _target="linux-armv4" ;;
|
||||||
mips64*) _target="linux64-mips64" ;;
|
|
||||||
# explicit _optflags is needed to prevent automatic -mips3 addition
|
|
||||||
mips*) _target="linux-mips32"; _optflags="-mips32" ;;
|
|
||||||
ppc) _target="linux-ppc" ;;
|
ppc) _target="linux-ppc" ;;
|
||||||
ppc64) _target="linux-ppc64" ;;
|
ppc64) _target="linux-ppc64" ;;
|
||||||
ppc64le) _target="linux-ppc64le" ;;
|
ppc64le) _target="linux-ppc64le" ;;
|
||||||
|
|
|
@ -1,39 +0,0 @@
|
||||||
# Maintainer: Andy Postnikov <apostnikov@gmail.com>
|
|
||||||
pkgname=php81-pecl-xmlrpc
|
|
||||||
_extname=xmlrpc
|
|
||||||
pkgver=1.0.0_rc3
|
|
||||||
_pkgver=${pkgver/_rc/RC}
|
|
||||||
pkgrel=1
|
|
||||||
pkgdesc="PHP 8.1 extension to write XML-RPC servers and clients - PECL"
|
|
||||||
url="https://pecl.php.net/package/xmlrpc"
|
|
||||||
arch="all"
|
|
||||||
license="PHP-3.01"
|
|
||||||
depends="php81-xml"
|
|
||||||
makedepends="php81-dev libxml2-dev"
|
|
||||||
source="php-pecl-$_extname-$pkgver.tar.gz::https://pecl.php.net/get/$_extname-$_pkgver.tgz"
|
|
||||||
builddir="$srcdir"/$_extname-$_pkgver
|
|
||||||
|
|
||||||
build() {
|
|
||||||
phpize81
|
|
||||||
./configure --prefix=/usr --with-php-config=/usr/bin/php-config81
|
|
||||||
make
|
|
||||||
}
|
|
||||||
|
|
||||||
check() {
|
|
||||||
make NO_INTERACTION=1 REPORT_EXIT_STATUS=1 test TESTS=--show-diff \
|
|
||||||
PHP_TEST_SHARED_EXTENSIONS=" \
|
|
||||||
-d extension=/usr/lib/php81/modules/xml.so \
|
|
||||||
-d extension=modules/$_extname.so"
|
|
||||||
php81 -d extension=modules/$_extname.so --ri $_extname
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
make INSTALL_ROOT="$pkgdir" install
|
|
||||||
local _confdir="$pkgdir"/etc/php81/conf.d
|
|
||||||
install -d $_confdir
|
|
||||||
echo "extension=$_extname" > $_confdir/$_extname.ini
|
|
||||||
}
|
|
||||||
|
|
||||||
sha512sums="
|
|
||||||
aa8e24d5a732b175adb9870357991d48ead046faed89e579eb63afe06c7ef20af9de29e2d70e71e54e5a15ee37265f69a7d52b39ef2465ced93ba818c1f7e9c1 php-pecl-xmlrpc-1.0.0_rc3.tar.gz
|
|
||||||
"
|
|
|
@ -1,40 +0,0 @@
|
||||||
# Maintainer: Andy Postnikov <apostnikov@gmail.com>
|
|
||||||
pkgname=php82-pecl-xmlrpc
|
|
||||||
_extname=xmlrpc
|
|
||||||
pkgver=1.0.0_rc3
|
|
||||||
_pkgver=${pkgver/_rc/RC}
|
|
||||||
pkgrel=1
|
|
||||||
pkgdesc="PHP 8.2 extension to write XML-RPC servers and clients - PECL"
|
|
||||||
url="https://pecl.php.net/package/xmlrpc"
|
|
||||||
arch="all"
|
|
||||||
license="PHP-3.01"
|
|
||||||
depends="php82-xml"
|
|
||||||
options="!check" # Failure
|
|
||||||
makedepends="php82-dev libxml2-dev"
|
|
||||||
source="php-pecl-$_extname-$pkgver.tar.gz::https://pecl.php.net/get/$_extname-$_pkgver.tgz"
|
|
||||||
builddir="$srcdir"/$_extname-$_pkgver
|
|
||||||
|
|
||||||
build() {
|
|
||||||
phpize82
|
|
||||||
./configure --prefix=/usr --with-php-config=/usr/bin/php-config82
|
|
||||||
make
|
|
||||||
}
|
|
||||||
|
|
||||||
check() {
|
|
||||||
make NO_INTERACTION=1 REPORT_EXIT_STATUS=1 test TESTS=--show-diff \
|
|
||||||
PHP_TEST_SHARED_EXTENSIONS=" \
|
|
||||||
-d extension=/usr/lib/php82/modules/xml.so \
|
|
||||||
-d extension=modules/$_extname.so"
|
|
||||||
php82 -d extension=modules/$_extname.so --ri $_extname
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
make INSTALL_ROOT="$pkgdir" install
|
|
||||||
local _confdir="$pkgdir"/etc/php82/conf.d
|
|
||||||
install -d $_confdir
|
|
||||||
echo "extension=$_extname" > $_confdir/$_extname.ini
|
|
||||||
}
|
|
||||||
|
|
||||||
sha512sums="
|
|
||||||
aa8e24d5a732b175adb9870357991d48ead046faed89e579eb63afe06c7ef20af9de29e2d70e71e54e5a15ee37265f69a7d52b39ef2465ced93ba818c1f7e9c1 php-pecl-xmlrpc-1.0.0_rc3.tar.gz
|
|
||||||
"
|
|
46
backports/py3-apsw/APKBUILD
Normal file
46
backports/py3-apsw/APKBUILD
Normal file
|
@ -0,0 +1,46 @@
|
||||||
|
# Contributor: Francesco Colista <fcolista@alpinelinux.org>
|
||||||
|
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
|
||||||
|
pkgname=py3-apsw
|
||||||
|
_pkgname=apsw
|
||||||
|
pkgver=3.45.2.0
|
||||||
|
pkgrel=1
|
||||||
|
pkgdesc="Another Python SQLite Wrapper"
|
||||||
|
url="https://github.com/rogerbinns/apsw"
|
||||||
|
arch="all"
|
||||||
|
license="Zlib"
|
||||||
|
depends="python3"
|
||||||
|
makedepends="
|
||||||
|
python3-dev
|
||||||
|
py3-gpep517
|
||||||
|
py3-setuptools
|
||||||
|
py3-wheel
|
||||||
|
sqlite-dev
|
||||||
|
"
|
||||||
|
subpackages="$pkgname-pyc"
|
||||||
|
source="$pkgname-$pkgver.zip::https://github.com/rogerbinns/apsw/releases/download/$pkgver/apsw-$pkgver.zip
|
||||||
|
detect-sqlite-config.patch
|
||||||
|
"
|
||||||
|
|
||||||
|
builddir="$srcdir/$_pkgname-$pkgver"
|
||||||
|
|
||||||
|
build() {
|
||||||
|
gpep517 build-wheel \
|
||||||
|
--wheel-dir .dist \
|
||||||
|
--output-fd 3 3>&1 >&2
|
||||||
|
}
|
||||||
|
|
||||||
|
check() {
|
||||||
|
python3 -m venv --clear --without-pip --system-site-packages .testenv
|
||||||
|
.testenv/bin/python3 -m installer .dist/*.whl
|
||||||
|
.testenv/bin/python3 setup.py build_test_extension test
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
python3 -m installer -d "$pkgdir" \
|
||||||
|
.dist/*.whl
|
||||||
|
}
|
||||||
|
|
||||||
|
sha512sums="
|
||||||
|
0260f6479d5f1188ad172dfc0dd7e4a03c9d809d2f80c2296e587a19286681bb2ce759b0bd19ec6957e2902f18729b7e79410e4db79dff9918089f57dd510828 py3-apsw-3.45.2.0.zip
|
||||||
|
8f3957bd6fecb5660a7cab367043e4ccdacd87d8963bbe41cc3d525265de28f08aa207099658d785be29c5c90b818c1418f766995cd780d02b8e36252a389758 detect-sqlite-config.patch
|
||||||
|
"
|
8
backports/py3-apsw/detect-sqlite-config.patch
Normal file
8
backports/py3-apsw/detect-sqlite-config.patch
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
diff --git a/setup.apsw b/setup.apsw
|
||||||
|
index 68dedb9..3ceb10b 100644
|
||||||
|
--- a/setup.apsw
|
||||||
|
+++ b/setup.apsw
|
||||||
|
@@ -1 +1,3 @@
|
||||||
|
# You can put ini format directives here in addition to command line flags
|
||||||
|
+[build_ext]
|
||||||
|
+use_system_sqlite_config = True
|
|
@ -2,8 +2,8 @@
|
||||||
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
||||||
pkgname=py3-arcus
|
pkgname=py3-arcus
|
||||||
# Needs to be upgraded in sync with libarcus
|
# Needs to be upgraded in sync with libarcus
|
||||||
pkgver=5.2.2
|
pkgver=5.3.0
|
||||||
pkgrel=3
|
pkgrel=0
|
||||||
pkgdesc="Python bindings for libarcus"
|
pkgdesc="Python bindings for libarcus"
|
||||||
url="https://github.com/Ultimaker/pyArcus"
|
url="https://github.com/Ultimaker/pyArcus"
|
||||||
arch="all"
|
arch="all"
|
||||||
|
@ -35,7 +35,7 @@ package() {
|
||||||
}
|
}
|
||||||
|
|
||||||
sha512sums="
|
sha512sums="
|
||||||
b24cbb9a5d7aa917b1b21e46f935b1293645e731d4e475a5abe364237f35708e8e96a1c6f06fe78e2e0e381737f4a27a6db87e42a5f4de9d48091d9de096f9b0 py3-arcus-5.2.2.tar.gz
|
d4a114994fa3e3156eae95dde58df13237b8bb0571a1219d6dee6b6338fd65f911f27887d6ab32b7a3cb32bc45ca6c25147e7c2d246cb0707326b88246abfbcd py3-arcus-5.3.0.tar.gz
|
||||||
f14e55cd31c13051981f26364e34da8c94e8eb5227b1cfd6fe44b9f97b5a4dcf6142a1751fa62eb0514a47583e6ec2d51dc253f23cf72c3fe6a1cb5dca136f21 cmake.patch
|
f14e55cd31c13051981f26364e34da8c94e8eb5227b1cfd6fe44b9f97b5a4dcf6142a1751fa62eb0514a47583e6ec2d51dc253f23cf72c3fe6a1cb5dca136f21 cmake.patch
|
||||||
de75b985607feae0a9c511742915814e9c3d4bc467183f010ccc334ce4d0d952b6ff86020360b78558c4738cc03cf62c386b44ed76bcec12075c4a93dd03eeb7 cmake-helpers.patch
|
de75b985607feae0a9c511742915814e9c3d4bc467183f010ccc334ce4d0d952b6ff86020360b78558c4738cc03cf62c386b44ed76bcec12075c4a93dd03eeb7 cmake-helpers.patch
|
||||||
ef593230d5c78da8ba0fc6ea83225c4543857de1837d3151c45e59ffd7c98063b8f97f25d01c15b6a8f90c26c919206f9f7fa26c9650117f4ce7be49ebca876f pyproject.patch
|
ef593230d5c78da8ba0fc6ea83225c4543857de1837d3151c45e59ffd7c98063b8f97f25d01c15b6a8f90c26c919206f9f7fa26c9650117f4ce7be49ebca876f pyproject.patch
|
||||||
|
|
|
@ -1,49 +0,0 @@
|
||||||
# Contributor: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
|
|
||||||
# Maintainer: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
|
|
||||||
pkgname=py3-cbor2
|
|
||||||
pkgver=5.6.1
|
|
||||||
pkgrel=0
|
|
||||||
pkgdesc="encoding and decoding for CBOR (RFC 8949)"
|
|
||||||
url="https://github.com/agronholm/cbor2"
|
|
||||||
arch="all"
|
|
||||||
license="MIT"
|
|
||||||
makedepends="
|
|
||||||
py3-gpep517
|
|
||||||
py3-setuptools
|
|
||||||
py3-setuptools_scm
|
|
||||||
py3-wheel
|
|
||||||
python3-dev
|
|
||||||
"
|
|
||||||
checkdepends="
|
|
||||||
py3-hypothesis
|
|
||||||
py3-pytest
|
|
||||||
py3-pytest-cov
|
|
||||||
py3-tomli
|
|
||||||
"
|
|
||||||
subpackages="$pkgname-pyc"
|
|
||||||
source="$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/c/cbor2/cbor2-$pkgver.tar.gz
|
|
||||||
fix-32bit-tests.patch
|
|
||||||
"
|
|
||||||
builddir="$srcdir/cbor2-$pkgver"
|
|
||||||
|
|
||||||
build() {
|
|
||||||
gpep517 build-wheel \
|
|
||||||
--wheel-dir .dist \
|
|
||||||
--output-fd 3 3>&1 >&2
|
|
||||||
}
|
|
||||||
|
|
||||||
check() {
|
|
||||||
python3 -m venv --clear --without-pip --system-site-packages .testenv
|
|
||||||
.testenv/bin/python3 -m installer .dist/*.whl
|
|
||||||
.testenv/bin/python3 -m pytest
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
python3 -m installer -d "$pkgdir" \
|
|
||||||
.dist/*.whl
|
|
||||||
}
|
|
||||||
|
|
||||||
sha512sums="
|
|
||||||
9ddf2c3690780816ff50ff4ed371435ca45b597b706254c37c9f01d1f1a699892e2c945a72e69b5506a803c41692f399b58b4e32d9409a0197c677e537e656b2 py3-cbor2-5.6.1.tar.gz
|
|
||||||
ba8a19a73fe2dc747846b77fde6cd621ccb500a514ba61192dfa28c875720003666165ad12c767260b31148b0dd25454e36e4f43dd8bb1d11928944c6a5b61dd fix-32bit-tests.patch
|
|
||||||
"
|
|
|
@ -1,29 +0,0 @@
|
||||||
Patch-Source: https://github.com/agronholm/cbor2/commit/75279162a019d20db3bff8d64d41c7e97b555b53
|
|
||||||
From 75279162a019d20db3bff8d64d41c7e97b555b53 Mon Sep 17 00:00:00 2001
|
|
||||||
From: =?UTF-8?q?Alex=20Gr=C3=B6nholm?= <alex.gronholm@nextday.fi>
|
|
||||||
Date: Tue, 6 Feb 2024 15:43:23 +0200
|
|
||||||
Subject: [PATCH] Fixed test_oversized_read failing on 32-bit platforms
|
|
||||||
|
|
||||||
Fixes #215.
|
|
||||||
---
|
|
||||||
tests/test_decoder.py | 4 ++--
|
|
||||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/tests/test_decoder.py b/tests/test_decoder.py
|
|
||||||
index cd0b45a..d11be6e 100644
|
|
||||||
--- a/tests/test_decoder.py
|
|
||||||
+++ b/tests/test_decoder.py
|
|
||||||
@@ -939,11 +939,11 @@ def test_decimal_payload_unpacking(impl, data, expected):
|
|
||||||
"payload",
|
|
||||||
[
|
|
||||||
pytest.param(
|
|
||||||
- unhexlify("5b7fffffffffffff00"),
|
|
||||||
+ unhexlify("41"),
|
|
||||||
id="bytestring",
|
|
||||||
),
|
|
||||||
pytest.param(
|
|
||||||
- unhexlify("7b7fffffffffffff00"),
|
|
||||||
+ unhexlify("61"),
|
|
||||||
id="unicode",
|
|
||||||
),
|
|
||||||
],
|
|
|
@ -1,45 +0,0 @@
|
||||||
# Contributor: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
|
|
||||||
# Maintainer: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
|
|
||||||
pkgname=py3-codespell
|
|
||||||
_pkgname=${pkgname#py3-}
|
|
||||||
pkgver=2.2.6
|
|
||||||
pkgrel=2
|
|
||||||
pkgdesc="Fix common misspellings in text files, primarily source code"
|
|
||||||
url="https://github.com/codespell-project/codespell/"
|
|
||||||
arch="noarch"
|
|
||||||
license="GPL-2.0-only"
|
|
||||||
makedepends="
|
|
||||||
py3-gpep517
|
|
||||||
py3-setuptools
|
|
||||||
py3-setuptools_scm
|
|
||||||
py3-wheel
|
|
||||||
"
|
|
||||||
checkdepends="py3-pytest-cov"
|
|
||||||
depends="py3-chardet"
|
|
||||||
subpackages="$pkgname-pyc"
|
|
||||||
source="$pkgname-$pkgver.tar.gz::https://github.com/codespell-project/codespell/archive/refs/tags/v$pkgver.tar.gz"
|
|
||||||
builddir="$srcdir"/$_pkgname-$pkgver
|
|
||||||
|
|
||||||
build() {
|
|
||||||
SETUPTOOLS_SCM_PRETEND_VERSION=$pkgver \
|
|
||||||
gpep517 build-wheel \
|
|
||||||
--wheel-dir .dist \
|
|
||||||
--output-fd 3 3>&1 >&2
|
|
||||||
}
|
|
||||||
|
|
||||||
check() {
|
|
||||||
python3 -m venv --clear --without-pip --system-site-packages .testenv
|
|
||||||
.testenv/bin/python3 -m installer .dist/*.whl
|
|
||||||
|
|
||||||
# tests want to run bin/codespell
|
|
||||||
PATH="$builddir/.testenv/bin:$PATH" .testenv/bin/python3 -m pytest
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
python3 -m installer -d "$pkgdir" \
|
|
||||||
.dist/*.whl
|
|
||||||
}
|
|
||||||
|
|
||||||
sha512sums="
|
|
||||||
37a6fbcf196447e8204a973499c6b3f7efda67e3caaaa707897da438c602834f91ca49b95020d2c03dcb95528c03451a2d9cfe145b2a24e88615c4a5418a4d2b py3-codespell-2.2.6.tar.gz
|
|
||||||
"
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Maintainer: Noel Kuntze <noel.kuntze@thermi.consulting>
|
# Maintainer: Noel Kuntze <noel.kuntze@thermi.consulting>
|
||||||
pkgname=py3-daemon
|
pkgname=py3-daemon
|
||||||
pkgver=2.3.2
|
pkgver=2.3.2
|
||||||
pkgrel=2
|
pkgrel=4
|
||||||
pkgdesc="Library to implement a well-behaved Unix daemon process"
|
pkgdesc="Library to implement a well-behaved Unix daemon process"
|
||||||
url="https://pagure.io/python-daemon"
|
url="https://pagure.io/python-daemon"
|
||||||
options="!check" # Has lots of dependencies
|
options="!check" # Has lots of dependencies
|
||||||
|
@ -11,7 +11,10 @@ license="Apache-2.0 AND GPL-3.0-or-later"
|
||||||
depends="py3-setuptools py3-lockfile"
|
depends="py3-setuptools py3-lockfile"
|
||||||
makedepends="py3-docutils"
|
makedepends="py3-docutils"
|
||||||
subpackages="$pkgname-pyc"
|
subpackages="$pkgname-pyc"
|
||||||
source="https://pypi.io/packages/source/p/python-daemon/python-daemon-$pkgver.tar.gz"
|
source="
|
||||||
|
https://pypi.io/packages/source/p/python-daemon/python-daemon-$pkgver.tar.gz
|
||||||
|
remove-docutils-depend.patch
|
||||||
|
"
|
||||||
builddir="$srcdir/python-daemon-$pkgver"
|
builddir="$srcdir/python-daemon-$pkgver"
|
||||||
|
|
||||||
prepare() {
|
prepare() {
|
||||||
|
@ -33,4 +36,5 @@ package() {
|
||||||
|
|
||||||
sha512sums="
|
sha512sums="
|
||||||
d9f6e6c376a496fae96bd9efed0a56d00a137617a3d1d5ef74802ef176bc813bb1d49bbb9164cdbec03213529f944b32b257bcc64283abfa4a3522ff00826bfd python-daemon-2.3.2.tar.gz
|
d9f6e6c376a496fae96bd9efed0a56d00a137617a3d1d5ef74802ef176bc813bb1d49bbb9164cdbec03213529f944b32b257bcc64283abfa4a3522ff00826bfd python-daemon-2.3.2.tar.gz
|
||||||
|
20bc4bce7fba9754d1c9bca298f9b4ff7fe90ecf51769df2020912f370650a5997f91c99c6be2ecffed10a6b359a29b1f64b0c391772451eb3c04769df381015 remove-docutils-depend.patch
|
||||||
"
|
"
|
||||||
|
|
16
backports/py3-daemon/remove-docutils-depend.patch
Normal file
16
backports/py3-daemon/remove-docutils-depend.patch
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
diff --git a/setup.py.orig b/setup.py
|
||||||
|
index 24f0e7cb98a..d712294c20b 100644
|
||||||
|
--- a/setup.py.orig
|
||||||
|
+++ b/setup.py
|
||||||
|
@@ -96,11 +96,6 @@ setup_kwargs = dict(
|
||||||
|
],
|
||||||
|
)
|
||||||
|
|
||||||
|
-# Docutils is only required for building, but Setuptools can't distinguish
|
||||||
|
-# dependencies properly.
|
||||||
|
-# See <URL:https://github.com/pypa/setuptools/issues/457>.
|
||||||
|
-setup_kwargs['install_requires'].append("docutils")
|
||||||
|
-
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
setup(**setup_kwargs)
|
|
@ -2,7 +2,7 @@
|
||||||
pkgname=py3-dateparser
|
pkgname=py3-dateparser
|
||||||
_pyname=${pkgname#py3-}
|
_pyname=${pkgname#py3-}
|
||||||
pkgver=1.2.0
|
pkgver=1.2.0
|
||||||
pkgrel=0
|
pkgrel=1
|
||||||
pkgdesc="Python parser for human readable dates"
|
pkgdesc="Python parser for human readable dates"
|
||||||
url="https://github.com/scrapinghub/dateparser"
|
url="https://github.com/scrapinghub/dateparser"
|
||||||
arch="noarch"
|
arch="noarch"
|
||||||
|
|
|
@ -1,51 +0,0 @@
|
||||||
# Contributor: Antoine Martin (ayakael) <dev@ayakael.net>
|
|
||||||
# Maintainer: Antoine Martin (ayakael) <dev@ayakael.net>
|
|
||||||
pkgname=py3-django-auth-ldap
|
|
||||||
#_pkgreal is used by apkbuild-pypi to find modules at PyPI
|
|
||||||
_pkgreal=django-auth-ldap
|
|
||||||
pkgver=4.8.0
|
|
||||||
pkgrel=1
|
|
||||||
pkgdesc="Django LDAP authentication backend"
|
|
||||||
url="https://pypi.python.org/project/django-auth-ldap"
|
|
||||||
# s390x | riscv64: test failure
|
|
||||||
arch="noarch !s390x !riscv64"
|
|
||||||
license="BSD"
|
|
||||||
# RuntimeError: slapd exited before opening port
|
|
||||||
options="!check"
|
|
||||||
depends="py3-django py3-ldap"
|
|
||||||
checkdepends="
|
|
||||||
py3-pytest
|
|
||||||
py3-pytest-django
|
|
||||||
py3-pytest-black
|
|
||||||
py3-isort
|
|
||||||
py3-flake8
|
|
||||||
openldap
|
|
||||||
openldap-back-mdb
|
|
||||||
openldap-clients
|
|
||||||
openldap-overlay-syncprov
|
|
||||||
"
|
|
||||||
makedepends="py3-setuptools py3-gpep517 py3-wheel"
|
|
||||||
source="$pkgname-$pkgver.tar.gz::https://github.com/django-auth-ldap/django-auth-ldap/archive/refs/tags/$pkgver.tar.gz"
|
|
||||||
builddir="$srcdir/$_pkgreal-$pkgver"
|
|
||||||
subpackages="$pkgname-pyc"
|
|
||||||
|
|
||||||
build() {
|
|
||||||
gpep517 build-wheel \
|
|
||||||
--wheel-dir .dist \
|
|
||||||
--output-fd 3 3>&1 >&2
|
|
||||||
}
|
|
||||||
|
|
||||||
check() {
|
|
||||||
python3 -m venv --clear --without-pip --system-site-packages .testenv
|
|
||||||
.testenv/bin/python3 -m installer .dist/*.whl
|
|
||||||
.testenv/bin/python3 -Wa -b -m django test --settings tests.settings
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
python3 -m installer -d "$pkgdir" \
|
|
||||||
.dist/*.whl
|
|
||||||
}
|
|
||||||
|
|
||||||
sha512sums="
|
|
||||||
559d6c0a556ccab2a0440866db9e1260b236e0bd4de92d07082660118b99886e7d362824cf0453de1f1d87ce1d5b5ab23d5181b8c970086d3a100ae32a29c482 py3-django-auth-ldap-4.8.0.tar.gz
|
|
||||||
"
|
|
|
@ -1,38 +0,0 @@
|
||||||
# Contributor: Leonardo Arena <rnalrd@alpinelinux.org>
|
|
||||||
# Maintainer: Will Sinatra <wpsinatra@gmail.com>
|
|
||||||
pkgname=py3-django-debug-toolbar
|
|
||||||
_pkgname=django-debug-toolbar
|
|
||||||
pkgver=4.3
|
|
||||||
pkgrel=0
|
|
||||||
pkgdesc="Configurable set of panels that display various debug information about the current request/response"
|
|
||||||
options="!check" # Requires unpackaged Selenium python3 module
|
|
||||||
url="https://github.com/jazzband/django-debug-toolbar"
|
|
||||||
arch="noarch"
|
|
||||||
license="BSD-3-Clause"
|
|
||||||
depends="py3-django py3-sqlparse"
|
|
||||||
makedepends="
|
|
||||||
py3-gpep517
|
|
||||||
py3-hatchling
|
|
||||||
"
|
|
||||||
# options="!check" #no testsuite
|
|
||||||
subpackages="$pkgname-pyc"
|
|
||||||
source="$pkgname-$pkgver.tar.gz::https://github.com/jazzband/$_pkgname/archive/$pkgver.tar.gz"
|
|
||||||
builddir="$srcdir"/$_pkgname-$pkgver
|
|
||||||
|
|
||||||
replaces="py-django-debug-toolbar" # Backwards compatibility
|
|
||||||
provides="py-django-debug-toolbar=$pkgver-r$pkgrel" # Backwards compatibility
|
|
||||||
|
|
||||||
build() {
|
|
||||||
gpep517 build-wheel \
|
|
||||||
--wheel-dir .dist \
|
|
||||||
--output-fd 3 3>&1 >&2
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
python3 -m installer -d "$pkgdir" \
|
|
||||||
.dist/*.whl
|
|
||||||
}
|
|
||||||
|
|
||||||
sha512sums="
|
|
||||||
caa8563d38e8c96305828b7a07006ce2ee0afae099d70d75d332f2196fc3ffcf7f3848440ea22c00f2b918029477672a172e30714f6f73a630404175aef3b925 py3-django-debug-toolbar-4.3.tar.gz
|
|
||||||
"
|
|
|
@ -1,8 +1,8 @@
|
||||||
# Contributor: lauren n. liberda <lauren@selfisekai.rocks>
|
# Contributor: lauren n. liberda <lauren@selfisekai.rocks>
|
||||||
# Maintainer: lauren n. liberda <lauren@selfisekai.rocks>
|
# Maintainer: lauren n. liberda <lauren@selfisekai.rocks>
|
||||||
pkgname=py3-flask-limiter
|
pkgname=py3-flask-limiter
|
||||||
pkgver=3.5.0
|
pkgver=3.7.0
|
||||||
pkgrel=1
|
pkgrel=0
|
||||||
pkgdesc="Rate Limiting extension for Flask"
|
pkgdesc="Rate Limiting extension for Flask"
|
||||||
url="https://github.com/alisaifee/flask-limiter"
|
url="https://github.com/alisaifee/flask-limiter"
|
||||||
arch="noarch"
|
arch="noarch"
|
||||||
|
@ -45,6 +45,6 @@ package() {
|
||||||
}
|
}
|
||||||
|
|
||||||
sha512sums="
|
sha512sums="
|
||||||
f97fd830fd0bbb2186c82451643413420be93872ed17d71d20c830a76ec3aee999bcda3a07b9d27d4602ef5fcd33f78888dc5d75c220eae5cb83ef02853151e6 flask-limiter-3.5.0.tar.gz
|
f546536e3efb86571515aac5b578155c240049fb1ccf96e55d4b1814d9e227e41cc18fc587f115706606154bb12a84b381533cf069cdfc56453b0f170ec19449 flask-limiter-3.7.0.tar.gz
|
||||||
1b90e9134076cda249695d5ea741db9d205a2ae452c7d6edfe01eb37a221ce6f64b0e8ddcdbbee9b0e0fb16a28e5eabf14f1c1e41e965c7e3b93ea4f42caf553 our-std-is-good-enough.patch
|
1b90e9134076cda249695d5ea741db9d205a2ae452c7d6edfe01eb37a221ce6f64b0e8ddcdbbee9b0e0fb16a28e5eabf14f1c1e41e965c7e3b93ea4f42caf553 our-std-is-good-enough.patch
|
||||||
"
|
"
|
||||||
|
|
|
@ -1,38 +0,0 @@
|
||||||
# Contributor: Fabian Affolter <fabian@affolter-engineering.ch>
|
|
||||||
# Maintainer: Fabian Affolter <fabian@affolter-engineering.ch>
|
|
||||||
pkgname=py3-flask-principal
|
|
||||||
_pkgname=flask-principal
|
|
||||||
pkgver=0.4.0
|
|
||||||
pkgrel=7
|
|
||||||
pkgdesc="Flask Identity management"
|
|
||||||
url="https://pythonhosted.org/Flask-Principal/"
|
|
||||||
arch="noarch"
|
|
||||||
license="MIT"
|
|
||||||
depends="python3 py3-blinker py3-flask"
|
|
||||||
makedepends="py3-setuptools py3-gpep517 py3-wheel"
|
|
||||||
checkdepends="py3-nose"
|
|
||||||
subpackages="$pkgname-pyc"
|
|
||||||
source="$pkgname-$pkgver.tar.gz::https://github.com/mattupstate/flask-principal/archive/$pkgver.tar.gz"
|
|
||||||
builddir="$srcdir"/$_pkgname-$pkgver
|
|
||||||
|
|
||||||
replaces="py-flask-principal" # Backwards compatibility
|
|
||||||
provides="py-flask-principal=$pkgver-r$pkgrel" # Backwards compatibility
|
|
||||||
|
|
||||||
build() {
|
|
||||||
gpep517 build-wheel \
|
|
||||||
--wheel-dir .dist \
|
|
||||||
--output-fd 3 3>&1 >&2
|
|
||||||
}
|
|
||||||
|
|
||||||
check() {
|
|
||||||
python3 -m venv --clear --without-pip --system-site-packages .testenv
|
|
||||||
gpep517 install-wheel --destdir .testenv --prefix '' .dist/*.whl
|
|
||||||
.testenv/bin/python3 -m nose
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
gpep517 install-wheel --destdir "$pkgdir" \
|
|
||||||
.dist/*.whl
|
|
||||||
}
|
|
||||||
|
|
||||||
sha512sums="ed8cb28c4e8d936de96db0bf9f7cb45b253dc204c4b8f8dd8022ef1552592ff6324b4a33d3ee862794a6e20eb8c32a0365e7b9397d427da5022c5ded3dfa308a py3-flask-principal-0.4.0.tar.gz"
|
|
|
@ -1,48 +0,0 @@
|
||||||
# Maintainer: Hoang Nguyen <folliekazetani@protonmail.com>
|
|
||||||
pkgname=py3-gitlab
|
|
||||||
_pyname=${pkgname/py3/python}
|
|
||||||
pkgver=4.4.0
|
|
||||||
pkgrel=0
|
|
||||||
pkgdesc="Python wrapper for Gitlab's API"
|
|
||||||
url="https://github.com/python-gitlab/python-gitlab"
|
|
||||||
arch="noarch"
|
|
||||||
license="LGPL-3.0-or-later"
|
|
||||||
depends="python3 py3-requests py3-requests-toolbelt"
|
|
||||||
makedepends="
|
|
||||||
py3-setuptools
|
|
||||||
py3-gpep517
|
|
||||||
py3-installer
|
|
||||||
py3-wheel
|
|
||||||
py3-sphinx
|
|
||||||
py3-sphinxcontrib-autoprogram
|
|
||||||
py3-myst-parser
|
|
||||||
"
|
|
||||||
checkdepends="py3-pytest py3-responses py3-build"
|
|
||||||
subpackages="$pkgname-doc $pkgname-pyc"
|
|
||||||
source="$pkgname-$pkgver.tar.gz::https://github.com/python-gitlab/python-gitlab/archive/refs/tags/v$pkgver.tar.gz"
|
|
||||||
options="!check" # Failing tests
|
|
||||||
builddir="$srcdir/$_pyname-$pkgver"
|
|
||||||
|
|
||||||
build() {
|
|
||||||
gpep517 build-wheel \
|
|
||||||
--wheel-dir .dist \
|
|
||||||
--output-fd 3 3>&1 >&2
|
|
||||||
sphinx-build -W -b man docs/ man/
|
|
||||||
}
|
|
||||||
|
|
||||||
check() {
|
|
||||||
python3 -m venv --clear --without-pip --system-site-packages .testenv
|
|
||||||
.testenv/bin/python3 -m installer .dist/*.whl
|
|
||||||
.testenv/bin/python3 -m pytest --ignore=tests/functional/
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
python3 -m installer -d "$pkgdir" \
|
|
||||||
.dist/*.whl
|
|
||||||
install -Dm644 man/$_pyname.1 \
|
|
||||||
"$pkgdir"/usr/share/man/man1/$_pyname.1
|
|
||||||
}
|
|
||||||
|
|
||||||
sha512sums="
|
|
||||||
cb572d169d948dcd74b1d85fb4e8fc2b2593ad167dd708f38bcaf5cccacc8a8b32231b2231d9cb69909e63ba0ce2c6f1cf522f21df56659343314ea2c0d39645 py3-gitlab-4.4.0.tar.gz
|
|
||||||
"
|
|
41
backports/py3-html5-parser/APKBUILD
Normal file
41
backports/py3-html5-parser/APKBUILD
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
# Maintainer: Cowington Post <cowingtonpost@gmail.com>
|
||||||
|
pkgname=py3-html5-parser
|
||||||
|
pkgver=0.4.12
|
||||||
|
pkgrel=1
|
||||||
|
pkgdesc="Fast C based HTML 5 parsing for python"
|
||||||
|
url="https://github.com/kovidgoyal/html5-parser"
|
||||||
|
arch="all"
|
||||||
|
license="Apache-2.0"
|
||||||
|
depends="py3-lxml py3-chardet"
|
||||||
|
makedepends="
|
||||||
|
libxml2-dev
|
||||||
|
py3-gpep517
|
||||||
|
py3-setuptools
|
||||||
|
py3-wheel
|
||||||
|
python3-dev
|
||||||
|
"
|
||||||
|
checkdepends="py3-beautifulsoup4"
|
||||||
|
subpackages="$pkgname-pyc"
|
||||||
|
source="https://github.com/kovidgoyal/html5-parser/archive/v$pkgver/py3-html5-parser-$pkgver.tar.gz"
|
||||||
|
builddir="$srcdir/html5-parser-$pkgver"
|
||||||
|
|
||||||
|
build() {
|
||||||
|
gpep517 build-wheel \
|
||||||
|
--wheel-dir .dist \
|
||||||
|
--output-fd 3 3>&1 >&2
|
||||||
|
}
|
||||||
|
|
||||||
|
check() {
|
||||||
|
python3 -m venv --clear --without-pip --system-site-packages .testenv
|
||||||
|
.testenv/bin/python3 -m installer .dist/*.whl
|
||||||
|
.testenv/bin/python3 setup.py test
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
python3 -m installer -d "$pkgdir" \
|
||||||
|
.dist/*.whl
|
||||||
|
}
|
||||||
|
|
||||||
|
sha512sums="
|
||||||
|
d2c031225b74d01a1ae3455837ac09e9afad8a4ec6ab1b8f66cbea8a86188db271a72570ef06e05ac56d369b41d97fc6f382455e25ca346a1897f62a3696a252 py3-html5-parser-0.4.12.tar.gz
|
||||||
|
"
|
|
@ -1,7 +1,7 @@
|
||||||
# Contributor: lauren n. liberda <lauren@selfisekai.rocks>
|
# Contributor: lauren n. liberda <lauren@selfisekai.rocks>
|
||||||
# Maintainer: lauren n. liberda <lauren@selfisekai.rocks>
|
# Maintainer: lauren n. liberda <lauren@selfisekai.rocks>
|
||||||
pkgname=py3-limits
|
pkgname=py3-limits
|
||||||
pkgver=3.10.1
|
pkgver=3.12.0
|
||||||
pkgrel=0
|
pkgrel=0
|
||||||
pkgdesc="Rate limiting using various strategies and storage backends such as redis & memcached"
|
pkgdesc="Rate limiting using various strategies and storage backends such as redis & memcached"
|
||||||
url="https://github.com/alisaifee/limits"
|
url="https://github.com/alisaifee/limits"
|
||||||
|
@ -45,6 +45,6 @@ package() {
|
||||||
}
|
}
|
||||||
|
|
||||||
sha512sums="
|
sha512sums="
|
||||||
5daa23a2a53dc56ba8e24fe72000bd69bfade9956a159c02731ef3a240682f467c4ae1f58878139fd9d0f67806bf115f6f97999160a2f66f34c64fdad1503d70 limits-3.10.1.tar.gz
|
2803dc26b18015e177342ed89e879f4dd680908579c99f9069d695edfa2beb3008b5bc47454ea2120a425bbcbc8a08928ab93a3058b33e11a2ae29431dfd9cd1 limits-3.12.0.tar.gz
|
||||||
8db0d96f860a07bbc554504a6e94b61546a6be22c0b9736c6b5aca628db9b618efc30609fce3702ee8e3812e1e34329c04d2f34bd69fdaecaa7c7fa0a2bde8a7 our-std-is-good-enough.patch
|
0364d51f9f879b95c6a4a3c9e9fd3d7d1e15ea214c50ae98cd36826b8c0b2d903cf1128741ac83738e305a207dae8955a0b2c8679484d2d6643e334595bdb1d7 our-std-is-good-enough.patch
|
||||||
"
|
"
|
||||||
|
|
|
@ -11,12 +11,12 @@
|
||||||
from limits.typing import Dict, List, NamedTuple, Optional, Tuple, Type, Union
|
from limits.typing import Dict, List, NamedTuple, Optional, Tuple, Type, Union
|
||||||
--- ./limits/typing.py.orig
|
--- ./limits/typing.py.orig
|
||||||
+++ ./limits/typing.py
|
+++ ./limits/typing.py
|
||||||
@@ -11,7 +11,7 @@
|
@@ -13,7 +13,7 @@
|
||||||
Union,
|
Union,
|
||||||
)
|
)
|
||||||
|
|
||||||
-from typing_extensions import ClassVar, Counter, ParamSpec, Protocol
|
-from typing_extensions import ClassVar, Counter, ParamSpec, Protocol, TypeAlias
|
||||||
+from typing import ClassVar, Counter, ParamSpec, Protocol
|
+from typing import ClassVar, Counter, ParamSpec, Protocol, TypeAlias
|
||||||
|
|
||||||
Serializable = Union[int, str, float]
|
Serializable = Union[int, str, float]
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
||||||
pkgname=py3-mapbox-earcut
|
pkgname=py3-mapbox-earcut
|
||||||
pkgver=1.0.1
|
pkgver=1.0.1
|
||||||
pkgrel=1
|
pkgrel=0
|
||||||
pkgdesc="Python bindings for the mapbox earcut c++ library"
|
pkgdesc="Python bindings for the mapbox earcut c++ library"
|
||||||
url="https://github.com/skogler/mapbox_earcut_python"
|
url="https://github.com/skogler/mapbox_earcut_python"
|
||||||
arch="all"
|
arch="all"
|
||||||
|
|
|
@ -4,15 +4,14 @@ pkgname=py3-microdata
|
||||||
#_pkgreal is used by apkbuild-pypi to find modules at PyPI
|
#_pkgreal is used by apkbuild-pypi to find modules at PyPI
|
||||||
_pkgreal=microdata
|
_pkgreal=microdata
|
||||||
pkgver=0.8.0
|
pkgver=0.8.0
|
||||||
pkgrel=1
|
pkgrel=0
|
||||||
pkgdesc="html5lib extension for parsing microdata"
|
pkgdesc="html5lib extension for parsing microdata"
|
||||||
url="https://pypi.python.org/project/microdata"
|
url="https://pypi.python.org/project/microdata"
|
||||||
license="CC0-1.0"
|
license="CC0-1.0"
|
||||||
arch="noarch"
|
arch="noarch"
|
||||||
depends="py3-html5lib"
|
depends="py3-html5lib"
|
||||||
checkdepends="python3-dev"
|
|
||||||
makedepends="py3-setuptools py3-gpep517 py3-wheel"
|
makedepends="py3-setuptools py3-gpep517 py3-wheel"
|
||||||
source="$pkgname-$pkgver.tar.gz::https://pypi.io/packages/source/m/microdata/microdata-$pkgver.tar.gz"
|
source="$pkgname-$pkgver.tar.gz::https://github.com/edsu/microdata/archive/refs/tags/v$pkgver.tar.gz"
|
||||||
builddir="$srcdir/$_pkgreal-$pkgver"
|
builddir="$srcdir/$_pkgreal-$pkgver"
|
||||||
subpackages="$pkgname-pyc"
|
subpackages="$pkgname-pyc"
|
||||||
|
|
||||||
|
@ -22,11 +21,17 @@ build() {
|
||||||
--output-fd 3 3>&1 >&2
|
--output-fd 3 3>&1 >&2
|
||||||
}
|
}
|
||||||
|
|
||||||
|
check() {
|
||||||
|
python3 -m venv --clear --without-pip --system-site-packages .testenv
|
||||||
|
.testenv/bin/python3 -m installer .dist/*.whl
|
||||||
|
.testenv/bin/python3 setup.py test
|
||||||
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
python3 -m installer -d "$pkgdir" \
|
python3 -m installer -d "$pkgdir" \
|
||||||
.dist/*.whl
|
.dist/*.whl
|
||||||
}
|
}
|
||||||
|
|
||||||
sha512sums="
|
sha512sums="
|
||||||
85ce750f11960e4bcae1cd7f7babbb43e47ad2e0133cc66fb8abb153b1471296b11dc642bee91059f89b45da363fcdd10cfe3770b43d3e7d4d82ff10ab700743 py3-microdata-0.8.0.tar.gz
|
e48c8c267f595faec97397fae470a3aa1f4f33d9f4ea7d186f07b104166b373ea768db7d73423aedd28af3e310f6b9fa268d946420c6aed9676d15f38396b07e py3-microdata-0.8.0.tar.gz
|
||||||
"
|
"
|
|
@ -1,24 +1,19 @@
|
||||||
# Contributor: Aiden Grossman <agrossman154@yahoo.com>
|
# Contributor: Aiden Grossman <agrossman154@yahoo.com>
|
||||||
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
||||||
pkgname=py3-pivy
|
pkgname=py3-pivy
|
||||||
_pkgname=pivy
|
pkgver=0.6.9_alpha0
|
||||||
pkgver=0.6.8
|
pkgrel=0
|
||||||
pkgrel=3
|
|
||||||
pkgdesc="Python3 bindings for coin"
|
pkgdesc="Python3 bindings for coin"
|
||||||
url="https://github.com/coin3d/pivy"
|
url="https://github.com/coin3d/pivy"
|
||||||
# riscv64 blocked by qt5-qtwebengine via py3-pyside2
|
# riscv64 blocked by py3-pyside6
|
||||||
# py3-pyside2 is not available on armhf
|
arch="all !riscv64"
|
||||||
# py3-pyside2 broken
|
|
||||||
#arch="all !armhf !riscv64"
|
|
||||||
license="ISC"
|
license="ISC"
|
||||||
depends="py3-pyside2"
|
depends="py3-pyside6"
|
||||||
makedepends="swig soqt-dev qt5-qtbase-dev python3-dev glu-dev cmake samurai"
|
makedepends="swig soqt-dev qt6-qtbase-dev python3-dev glu-dev cmake samurai"
|
||||||
checkdepends="py3-pytest"
|
checkdepends="py3-pytest"
|
||||||
options="!check" # test suite is interactive and requires full installation
|
options="!check" # test suite is interactive and requires full installation
|
||||||
source="$pkgname-$pkgver.tar.gz::https://github.com/coin3d/pivy/archive/refs/tags/$pkgver.tar.gz
|
source="$pkgname-$pkgver.tar.gz::https://github.com/coin3d/pivy/archive/refs/tags/${pkgver//_alpha/.a}.tar.gz"
|
||||||
qt5.patch
|
builddir="$srcdir/pivy-${pkgver//_alpha/.a}"
|
||||||
"
|
|
||||||
builddir="$srcdir/$_pkgname-$pkgver"
|
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
if [ "$CBUILD" != "$CHOST" ]; then
|
if [ "$CBUILD" != "$CHOST" ]; then
|
||||||
|
@ -37,6 +32,5 @@ package() {
|
||||||
}
|
}
|
||||||
|
|
||||||
sha512sums="
|
sha512sums="
|
||||||
723b09028f2e3075056b9588cebad0ddccbc98d0c15552b9565c177b0de764b9645f88ea2bc534ccf606f2e0b59f91e1d03551b55ece66c0654ce9cdf09a1a7c py3-pivy-0.6.8.tar.gz
|
1bfefd58d2921c8be170a97efa30cad53b01f636ea0cf236acca242be4f691669a4c310cd61c64d3e0c55e55e8be96d36945cd244380ddc0b3a06170d0f8b691 py3-pivy-0.6.9_alpha0.tar.gz
|
||||||
7750ded3eb09da510ba5f84e7957c2ae1f92be0df280901fd9c9eba4164758a8f2d436e2d6ae7634a91aed12609f4eefd181922e6caed0b4906c6bc9dbd7b562 qt5.patch
|
|
||||||
"
|
"
|
||||||
|
|
|
@ -1,11 +0,0 @@
|
||||||
--- ./qtinfo.py
|
|
||||||
+++ ./qtinfo.py
|
|
||||||
@@ -7,7 +7,7 @@
|
|
||||||
if qmake_command:
|
|
||||||
self._qmake_command = qmake_command
|
|
||||||
else:
|
|
||||||
- self._qmake_command = [find_executable("qmake"),]
|
|
||||||
+ self._qmake_command = [find_executable("qmake-qt5"),]
|
|
||||||
self._dict = {}
|
|
||||||
# bind all variables early at __init__ time.
|
|
||||||
for thing in self.__class__.__dict__:
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
|
||||||
pkgname=py3-pyinstrument
|
pkgname=py3-pyinstrument
|
||||||
pkgver=4.6.2
|
pkgver=4.6.2
|
||||||
pkgrel=0
|
pkgrel=1
|
||||||
pkgdesc="Call stack profiler for Python"
|
pkgdesc="Call stack profiler for Python"
|
||||||
url="https://github.com/joerick/pyinstrument"
|
url="https://github.com/joerick/pyinstrument"
|
||||||
arch="all"
|
arch="all"
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Maintainer: Anjandev Momi <anjan@momi.ca>
|
# Maintainer: Anjandev Momi <anjan@momi.ca>
|
||||||
pkgname=py3-pynest2d
|
pkgname=py3-pynest2d
|
||||||
pkgver=5.2.2
|
pkgver=5.2.2
|
||||||
pkgrel=2
|
pkgrel=4
|
||||||
pkgdesc="Python bindings for libnest2d"
|
pkgdesc="Python bindings for libnest2d"
|
||||||
url="https://github.com/Ultimaker/pynest2d"
|
url="https://github.com/Ultimaker/pynest2d"
|
||||||
arch="all"
|
arch="all"
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue