You are not logged in.

#1 2025-10-11 20:57:38

silverhikari
Member
Registered: 2018-09-09
Posts: 19

recommended way to alter a submodule commit via PKGBUILD?

i am the packager for the giada package. recently an issue was found by a user with a submodule setting the required commit and after checking it seem the commit that the submodule was pinned at no longer exists. so i am wondering how and if it would be a good idea to change the commit of the submodule in the pkgbuild.

Last edited by silverhikari (2025-10-11 21:05:14)

Offline

#2 2025-10-11 21:46:51

loqs
Member
Registered: 2014-03-06
Posts: 18,630

Re: recommended way to alter a submodule commit via PKGBUILD?

To fetch the unreferenced commit.

diff --git a/PKGBUILD b/PKGBUILD
index 111377d..c43cf5b 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -39,6 +39,8 @@ sha512sums=('SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP')
 b2sums=('SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP')
 
 prepare() {
+  git -C rtaudio remote add network-origin https://github.com/monocasual/rtaudio.git
+  git -C rtaudio fetch network-origin 8a362b1082ce17d3be1f47bd116839e40f189cf1
   cd "$pkgname"
   git submodule init
   git config submodule.src/deps/juce.url "$srcdir/JUCE"

Or fork https://github.com/monocasual/rtaudio.git add a tag that references 8a362b1082ce17d3be1f47bd116839e40f189cf1 so it will be pulled automatically by `git clone --mirror` and switch the source to your fork.

Additionally I suggest raising the issue with upstream as they are still using the same commit in their git HEAD.

Offline

#3 2025-10-11 23:17:08

silverhikari
Member
Registered: 2018-09-09
Posts: 19

Re: recommended way to alter a submodule commit via PKGBUILD?

thanks for the fix added to the pkgbuild and have notified upstream about the commit issue!

Offline

Board footer

Powered by FluxBB