Compare commits

...
9 Commits
Author SHA1 Message Date
Arjan van de Ven c360ffe52c update packages file 2025-01-09 19:17:51 +00:00
Arjan van de Ven f092f66d8d update packages file 2024-12-19 06:03:26 +00:00
Brett T. Warden 704e8c90b8 Cleanup parsing of version from specfile in catchup targets
Make sure we only parse %{version} one time while doing a catchup.
2024-12-05 17:11:40 -08:00
Brett T. Warden 1ca80a16a3 Implement catchup targets
Implement a new target 'catchup' that will backport upstream commits
from the current package version to HEAD.
Implement a new target 'catchup-<commit|tag>' that will backport
upstream commits up to the target, as resolvable by git. This powers
'catchup'.
Rework the target 'backport-<commit>' to clone and use the upstream
git repository instead of using GitHub URLs. This also simplifies the
resolution of targets to full commit hashes, as needed to ensure unique
patch names and entries in 'series'.

'make catchup' will backport all the patches to catch this package up to
the upstream's HEAD
'make catchup-v5.0' will backport all the patches to catch this package
up to tag "v5.0" upstream.
'make catchup-ffdcba' will backport all the patches between this
package's current version and the upstream commit ffdcba.
'make backport-ffdcba' will backport ONLY upstream commit ffdcba.

All targets will produce patches named "backport-<commit>.patch", where
<commit> is the full SHA1 commit hash, regardless of whether you used an
abbreviated hash (or a tag, for catchup-%).

Patches are added to 'series' in chronological order, unless they're
already anywhere in that file.
2024-12-05 16:00:31 -08:00
Arjan van de Ven 27e359bda0 update packages file 2024-12-05 19:57:20 +00:00
Brett T. Warden 3db02dd609 Implement backport-<commit> target
For packages with a GitHub repo configured in options.conf, allow
downloading and applying backport patches via the 'backport-<commit>'
target. If given an abbreviated commit ID, it will still create a
backport-<commit>.patch file with the full commit hash, plus add it (if
it does not already exist) to the end of the series file.

Because this handles a single commit at a time, this should be wrappable
by a future Makefile target that applies individual commits to catch up
to a target tag, for example.
2024-12-02 16:13:06 -08:00
Arjan van de Ven 5866d7afbf update packages file 2024-11-25 21:15:54 +00:00
Arjan van de Ven 437d1ee01a update packages file 2024-11-13 17:16:18 +00:00
Arjan van de Ven cb5d78bb2f update packages file 2024-11-05 04:43:02 +00:00
2 changed files with 96 additions and 18 deletions
+72
View File
@@ -582,6 +582,78 @@ cloc: $(SRPMFILE)
@$(MOCK) --clean --scrub=chroot --uniqueext=$(PKG_NAME) @$(MOCK) --clean --scrub=chroot --uniqueext=$(PKG_NAME)
cat results/cloc.txt cat results/cloc.txt
#help catchup: Backport the commits from the current version to the upstream HEAD (not release).
#help Only works if giturl is defined and the current package version can be mapped to a git tag.
catchup:
$(MAKE) catchup-HEAD
#help catchup-<commit|tag>: Backport the commits from the current version to the specified commit or tag.
#help Only works if giturl is defined and the current package version can be mapped to a git tag.
catchup-%:
@target=$*; \
giturl=$$(grep -E '^giturl\s*=\s*\S+' options.conf | sed 's/giturl\s*=\s*//' 2>/dev/null); \
if [[ -z "$${giturl}" ]]; then \
echo "Error: giturl not defined in options.conf"; \
exit 1; \
fi; \
mkdir -p results; \
if [[ -d results/$(PKG_NAME) ]]; then \
echo "Reusing existing repository..."; \
git -C results/$(PKG_NAME) fetch origin; \
else \
echo "Cloning upstream repository..."; \
git -C results clone "$${giturl}" $(PKG_NAME); \
fi; \
if ! git -C results/$(PKG_NAME) rev-parse --verify --quiet "$${target}" >/dev/null; then \
echo "Error: Target commit/tag $${target} not found"; \
exit 1; \
fi; \
version=$$(rpm -q --qf '%{VERSION}\n' --specfile $(SPECFILE) | head -1); \
echo "Version: $${version}"; \
current_tag=$$(git -C results/$(PKG_NAME) tag --list | grep -E "^($(PKG_NAME)-)?v?$${version}$$") || { \
echo "Error: No tag found for current package version"; \
exit 1; \
}; \
echo "Catching up from $${current_tag} to $${target}"; \
for commit in $$(git -C results/$(PKG_NAME) log --reverse --pretty=oneline $${current_tag}..$${target} | cut -d' ' -f1); do \
$(MAKE) backport-$${commit}; \
done;
#help backport-<commit>: Retrieve a commit from the upstream git repository and save it as a backport patch.
#help The giturl is read from options.conf.
backport-%:
@commit=$*; \
echo "Backporting commit: $${commit}"; \
giturl=$$(grep -E '^giturl\s*=\s*\S+' options.conf | sed 's/giturl\s*=\s*//' 2>/dev/null); \
if [[ -z "$${giturl}" ]]; then \
echo "Error: giturl not defined in options.conf"; \
exit 1; \
fi; \
mkdir -p results; \
if [[ -d results/$(PKG_NAME) ]]; then \
echo "Reusing existing repository..."; \
git -C results/$(PKG_NAME) fetch origin; \
else \
echo "Cloning upstream repository..."; \
git -C results clone "$${giturl}" $(PKG_NAME); \
fi; \
full_commit=$$(git -C results/$(PKG_NAME) show --pretty=oneline $${commit} 2>/dev/null | head -1 | cut -d' ' -f 1); \
if [[ -z "$${full_commit}" ]]; then \
echo "Error: Commit for $${commit} not found"; \
exit 1; \
fi; \
patch=backport-$${full_commit}.patch; \
git -C results/$(PKG_NAME) format-patch -1 --stdout $${full_commit} > $${patch}; \
if [[ -s $${patch} ]]; then \
echo "$${patch} created"; \
grep -qE "^$${patch}$$" series 2>/dev/null || echo "$${patch}" >> series; \
else \
rm -f $${patch}; \
echo "Error: Failed to create backport patch"; \
exit 1; \
fi \
.PHONY: whatrequires .PHONY: whatrequires
#help whatrequires: Output a list of packages that directly depend on this one, #help whatrequires: Output a list of packages that directly depend on this one,
#help showing the subpackage-level breakdown. Each line of output has the format #help showing the subpackage-level breakdown. Each line of output has the format
+24 -18
View File
@@ -180,6 +180,7 @@ R-Ryacas
R-SGP R-SGP
R-SGPdata R-SGPdata
R-SQUAREM R-SQUAREM
R-SimDesign
R-Sleuth2 R-Sleuth2
R-SnowballC R-SnowballC
R-SparseM R-SparseM
@@ -232,6 +233,7 @@ R-bayesplot
R-bazar R-bazar
R-bbmle R-bbmle
R-bdsmatrix R-bdsmatrix
R-beepr
R-beeswarm R-beeswarm
R-bench R-bench
R-benchr R-benchr
@@ -871,6 +873,7 @@ R-rsvg
R-runjags R-runjags
R-rversions R-rversions
R-rvest R-rvest
R-rworldmap
R-s2 R-s2
R-sampling R-sampling
R-sandwich R-sandwich
@@ -1204,6 +1207,7 @@ boost
borgbackup borgbackup
boto3 boto3
botocore botocore
bottom
bovo bovo
box2d box2d
bpftool bpftool
@@ -1234,6 +1238,7 @@ buildreq-qmake
buildreq-qt6 buildreq-qt6
buildreq-scons buildreq-scons
buildx buildx
bwidget
byobu byobu
bz2file bz2file
bzip2 bzip2
@@ -1340,6 +1345,7 @@ compat-cairomm-soname10
compat-codec2-soname1 compat-codec2-soname1
compat-enchant-soname1 compat-enchant-soname1
compat-ffmpeg-4.4 compat-ffmpeg-4.4
compat-ffmpeg-6
compat-fuse-soname2 compat-fuse-soname2
compat-gcc-10 compat-gcc-10
compat-gcr-soname1 compat-gcr-soname1
@@ -1361,6 +1367,7 @@ compat-libvpx-soname8
compat-pangomm-soname14 compat-pangomm-soname14
compat-protobuf-soname29 compat-protobuf-soname29
compat-protobuf-soname32 compat-protobuf-soname32
compat-python3-rolling
compat-re2-soname10 compat-re2-soname10
compat-readline-soname5 compat-readline-soname5
compat-taglib-soname1 compat-taglib-soname1
@@ -1581,6 +1588,7 @@ fsearch
fuse fuse
fwupd fwupd
fwupd-efi fwupd-efi
game-music-emu
garcon garcon
gawk gawk
gbinder-python gbinder-python
@@ -1840,6 +1848,7 @@ ipe
iperf iperf
ipmitool ipmitool
ipp-crypto ipp-crypto
ipp-usb
iproute2 iproute2
ipset ipset
iptables iptables
@@ -1852,6 +1861,7 @@ irrlicht
irrlichtmt irrlichtmt
irssi irssi
isa-l isa-l
isl
iso-codes iso-codes
isodate isodate
isomd5sum isomd5sum
@@ -2258,6 +2268,7 @@ libmbim
libmediaart libmediaart
libmemcached libmemcached
libmicrohttpd libmicrohttpd
libmikmod
libmnl libmnl
libmodbus libmodbus
libmodplug libmodplug
@@ -2378,6 +2389,7 @@ libva
libva-intel-driver libva-intel-driver
libva-utils libva-utils
libvdpau libvdpau
libversion
libvirt libvirt
libvirt-dbus libvirt-dbus
libvirt-glib libvirt-glib
@@ -3732,6 +3744,7 @@ pynvim
pyotherside pyotherside
pyotp pyotp
pyparted pyparted
pypi-Yapps
pypi-absl_py pypi-absl_py
pypi-abydos pypi-abydos
pypi-accelerate pypi-accelerate
@@ -3749,7 +3762,6 @@ pypi-alabaster
pypi-altair pypi-altair
pypi-altgraph pypi-altgraph
pypi-amqp pypi-amqp
pypi-aniso8601
pypi-annotated_types pypi-annotated_types
pypi-ansi2html pypi-ansi2html
pypi-ansible_builder pypi-ansible_builder
@@ -3785,7 +3797,6 @@ pypi-atpublic
pypi-attr pypi-attr
pypi-attrdict pypi-attrdict
pypi-attrs pypi-attrs
pypi-autocommand
pypi-automat pypi-automat
pypi-awesomeversion pypi-awesomeversion
pypi-awscrt pypi-awscrt
@@ -3803,7 +3814,6 @@ pypi-babel
pypi-backcall pypi-backcall
pypi-backoff pypi-backoff
pypi-backports.ssl_match_hostname pypi-backports.ssl_match_hostname
pypi-bash_kernel
pypi-bashlex pypi-bashlex
pypi-bcrypt pypi-bcrypt
pypi-beartype pypi-beartype
@@ -3842,14 +3852,12 @@ pypi-cachy
pypi-cairocffi pypi-cairocffi
pypi-cairosvg pypi-cairosvg
pypi-calver pypi-calver
pypi-capturer
pypi-cattrs pypi-cattrs
pypi-cerberus pypi-cerberus
pypi-certbot pypi-certbot
pypi-certbot_dns_google pypi-certbot_dns_google
pypi-certifi pypi-certifi
pypi-cffi pypi-cffi
pypi-cffsubr
pypi-cfgv pypi-cfgv
pypi-chai pypi-chai
pypi-chaospy pypi-chaospy
@@ -3859,7 +3867,6 @@ pypi-check_jsonschema
pypi-check_manifest pypi-check_manifest
pypi-cheetah3 pypi-cheetah3
pypi-cheroot pypi-cheroot
pypi-cherrypy
pypi-cibuildwheel pypi-cibuildwheel
pypi-ciscoisesdk pypi-ciscoisesdk
pypi-ciso8601 pypi-ciso8601
@@ -3871,11 +3878,11 @@ pypi-click_log
pypi-clikit pypi-clikit
pypi-cloudevents pypi-cloudevents
pypi-cloudflare pypi-cloudflare
pypi-clr_artifact
pypi-cmarkgfm pypi-cmarkgfm
pypi-cmd2 pypi-cmd2
pypi-codecov pypi-codecov
pypi-colorama pypi-colorama
pypi-coloredlogs
pypi-colorlog pypi-colorlog
pypi-columnize pypi-columnize
pypi-comm pypi-comm
@@ -3896,6 +3903,7 @@ pypi-coveralls
pypi-cppy pypi-cppy
pypi-crashtest pypi-crashtest
pypi-crcmod pypi-crcmod
pypi-crypt_r
pypi-cryptography pypi-cryptography
pypi-cryptography_vectors pypi-cryptography_vectors
pypi-cs pypi-cs
@@ -3918,6 +3926,7 @@ pypi-decorator
pypi-deepmerge pypi-deepmerge
pypi-deepspeed pypi-deepspeed
pypi-dep_logic pypi-dep_logic
pypi-dependency_groups
pypi-deprecated pypi-deprecated
pypi-deprecation pypi-deprecation
pypi-devpi_client pypi-devpi_client
@@ -4112,10 +4121,8 @@ pypi-isort
pypi-itsdangerous pypi-itsdangerous
pypi-janus pypi-janus
pypi-jaraco.classes pypi-jaraco.classes
pypi-jaraco.collections
pypi-jaraco.context pypi-jaraco.context
pypi-jaraco.functools pypi-jaraco.functools
pypi-jaraco.text
pypi-jarn.viewdoc pypi-jarn.viewdoc
pypi-javaproperties pypi-javaproperties
pypi-jedi pypi-jedi
@@ -4128,7 +4135,6 @@ pypi-jinxed
pypi-jmespath pypi-jmespath
pypi-joblib pypi-joblib
pypi-josepy pypi-josepy
pypi-jsmin
pypi-json5 pypi-json5
pypi-jsondiff pypi-jsondiff
pypi-jsonlines pypi-jsonlines
@@ -4176,6 +4182,7 @@ pypi-lazy
pypi-lazy_loader pypi-lazy_loader
pypi-lazy_object_proxy pypi-lazy_object_proxy
pypi-ldap3 pypi-ldap3
pypi-legacy_cgi
pypi-levenshtein pypi-levenshtein
pypi-libarchive_c pypi-libarchive_c
pypi-libevdev pypi-libevdev
@@ -4360,6 +4367,7 @@ pypi-progress
pypi-progressbar pypi-progressbar
pypi-prometheus_client pypi-prometheus_client
pypi-prompt_toolkit pypi-prompt_toolkit
pypi-propcache
pypi-proto_plus pypi-proto_plus
pypi-protobuf pypi-protobuf
pypi-psautohint pypi-psautohint
@@ -4375,7 +4383,6 @@ pypi-py3dns
pypi-py3nvml pypi-py3nvml
pypi-py_cpuinfo pypi-py_cpuinfo
pypi-pyaml pypi-pyaml
pypi-pyarrow
pypi-pyasn1 pypi-pyasn1
pypi-pyasn1_modules pypi-pyasn1_modules
pypi-pybind11 pypi-pybind11
@@ -4415,7 +4422,6 @@ pypi-pylint
pypi-pymdown_extensions pypi-pymdown_extensions
pypi-pynacl pypi-pynacl
pypi-pynetbox pypi-pynetbox
pypi-pynsist
pypi-pynvml pypi-pynvml
pypi-pyomo pypi-pyomo
pypi-pyopengl pypi-pyopengl
@@ -4505,6 +4511,7 @@ pypi-rapidfuzz
pypi-rapidfuzz_capi pypi-rapidfuzz_capi
pypi-rcssmin pypi-rcssmin
pypi-rdflib pypi-rdflib
pypi-re2
pypi-readme_renderer pypi-readme_renderer
pypi-readtime pypi-readtime
pypi-recommonmark pypi-recommonmark
@@ -4514,7 +4521,6 @@ pypi-regress
pypi-reportlab pypi-reportlab
pypi-repoze.lru pypi-repoze.lru
pypi-requests pypi-requests
pypi-requests_download
pypi-requests_file pypi-requests_file
pypi-requests_gssapi pypi-requests_gssapi
pypi-requests_kerberos pypi-requests_kerberos
@@ -4530,7 +4536,6 @@ pypi-retrolab
pypi-retry pypi-retry
pypi-retry_decorator pypi-retry_decorator
pypi-retryz pypi-retryz
pypi-retype
pypi-rfc3339_validator pypi-rfc3339_validator
pypi-rfc3986 pypi-rfc3986
pypi-rfc3986_validator pypi-rfc3986_validator
@@ -4674,7 +4679,6 @@ pypi-tornado_xstatic
pypi-tox pypi-tox
pypi-tqdm pypi-tqdm
pypi-traitlets pypi-traitlets
pypi-trampolim
pypi-transformers pypi-transformers
pypi-translationstring pypi-translationstring
pypi-trimesh pypi-trimesh
@@ -4684,7 +4688,6 @@ pypi-trove_classifiers
pypi-truststore pypi-truststore
pypi-ttp pypi-ttp
pypi-twine pypi-twine
pypi-typed_ast
pypi-typeguard pypi-typeguard
pypi-types_cffi pypi-types_cffi
pypi-types_colorama pypi-types_colorama
@@ -4715,7 +4718,6 @@ pypi-tzdata
pypi-tzlocal pypi-tzlocal
pypi-ua_parser pypi-ua_parser
pypi-uc_micro_py pypi-uc_micro_py
pypi-ufo2ft
pypi-ufolib2 pypi-ufolib2
pypi-uharfbuzz pypi-uharfbuzz
pypi-ujson pypi-ujson
@@ -4984,6 +4986,7 @@ s3fs-fuse
salt salt
samba samba
samtools samtools
sane-airscan
sane-backends sane-backends
sassc sassc
sbc sbc
@@ -4996,6 +4999,7 @@ scour
scowl scowl
screen screen
scummvm scummvm
scx
sddm sddm
sddm-kcm sddm-kcm
seahorse seahorse
@@ -5107,7 +5111,9 @@ tallow
tar tar
taskwarrior taskwarrior
tbb tbb
tbtools
tcl tcl
tclx
tcpdump tcpdump
tdb tdb
tecla tecla
@@ -5176,7 +5182,6 @@ usb-modeswitch-data
usbredir usbredir
usbutils usbutils
userspace-rcu userspace-rcu
usrbinjava
usrbinvi usrbinvi
usrsctp usrsctp
utf8proc utf8proc
@@ -5322,6 +5327,7 @@ xrandr
xrdb xrdb
xrdp xrdp
xrestop xrestop
xscorch
xscreensaver xscreensaver
xsel xsel
xset xset