You are not logged in.

#1 2023-04-18 06:13:21

ABOhiccups
Member
Registered: 2017-08-27
Posts: 97

[HELP] Keep torguard-bin up-to-date

Hello,
I've created torguard-bin due to the other TorGuard AUR package was not up-to-date. My AUR Package works better then other one.

I need help to keep torguard-bin up-to-date.

If you want to help out to keep torguard-bin up-to-date on AUR.
Send me your AUR Username and your GitHub Username.
Then I will add you as Co-Maintainer on AUR, and Collaborator on GitHub.

You just need AUR Account and GitHub Account. I will show you instruction how to update torguard-bin when a newer version of TorGuard for Linux is release.

1) Download Arch Linux Version from TorGuard website.
https://torguard.net/downloads/new/torg … rch.tar.gz

2) Open Terminal and enter this command.

git clone ssh://aur@aur.archlinux.org/torguard-bin.git

3) Extract TorGuard for Linux from Tar.gz folder you've downloaded from TorGuard website. Go into a folder you've extracted from and copy the following files "PKGBUILD" and "torguard.install" and place it into torguard-bin folder from AUR you've clone it from. Replace both PKGBUILD and torguard.install.

4) Go to GitHub page.
https://github.com/ABOhiccups/TorGuard-AUR/releases

You want to upload torguard-vXXX-XXX-amd64-arch.tar folder from extracted folder into GitHub release.

5) Open PKGBUILD. Remove all message/note lines from the top (we don't need it). Then change the following lines.

pkgname=torguard > pkgname=torguard-bin
source=("torguard-vXXX-XXX-amd64-arch.tar") > source=("https://github.com/ABOhiccups/TorGuard-AUR/releases/download/AUR/torguard-vXXX-XXX-amd64-arch.tar")

Save the file.

6) Open the Terminal and enter this command.

makepkg --printsrcinfo > .SRCINFO

Do the rest as normal to push torguard-bin into AUR Repro.

Last edited by ABOhiccups (2023-04-18 06:15:04)

Offline

#2 2023-04-18 12:17:58

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 13,012

Re: [HELP] Keep torguard-bin up-to-date

Why are you manually downloading an archive , extracting something from it then uploading the something and finally let makepkg download the something ??

The PKGBUILD should be adjusted to let makepkg do that job . See the torguard pkgbuild for an example how to extract stuff in prepare() .


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#3 2023-04-18 13:03:56

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,330
Website

Re: [HELP] Keep torguard-bin up-to-date

More importantly, you should not just create a new package because the existing one is outdated.  If the maintainer of the existing package isn't going to maintain it you can submit an orphan request and (later) take over that package.


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#4 2023-04-18 20:32:17

ABOhiccups
Member
Registered: 2017-08-27
Posts: 97

Re: [HELP] Keep torguard-bin up-to-date

To answer you two questions. Yes, I know the other TorGuard AUR package exist. That package was outdated and it has not been updated. The package I've tried it does not automatically open after boot up and login to desktop after enable Auto Startup in TorGuard Settings. My AUR package release (and also official PKGBUILD by TorGuard Support) does not have that problem.

I have submit a request to be co-maintainer or for their package to be orphan several days ago. But, what I'm understanding. It takes 180 days to accept if the maintainer did not respond or update a package to latest version. If the other TorGuard package is now in orphan or I'm added as maintainer. Then yes, I will delete torguard-bin package sense I'm running the other TorGuard package.

The torguard-bin package I'm maintaining. The PKGBUILD was done by TorGuard Team. I'm publishing their official PKGBUILD to AUR (unless if TorGuard officially release their own package in Arch Linux Default Repository). All I have to do is modify PKGBUILD a little bit by change the name to torguard-bin (without mixed up with outdated package) and change the source where the Tar file (formally located with PKGBUILD and torguard.install) is now located in GitHub Release Download.

Last edited by ABOhiccups (2023-04-18 20:34:28)

Offline

#5 2023-04-18 23:25:52

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,330
Website

Re: [HELP] Keep torguard-bin up-to-date

ABOhiccups wrote:

I have submit a request to be co-maintainer or for their package to be orphan several days ago. But, what I'm understanding. It takes 180 days to accept if the maintainer did not respond

No.  The waiting period is two weeks from when the package is flagged outdated.  Then orphan requests should be granted so long as the current maintainer doesn't reply in a reasonable period.  The 180 days is the opposite end of the spectrum: if a package is outdated for 180 days the request would be granted immediately.

If this package has been outdated for (more than) two weeks, your orphan request is valid and the TU(s) are likely to grant it at any time now if the current maintainer hasn't replied.

In any case, submitting a duplicate package is not appropriate.

Last edited by Trilby (2023-04-18 23:26:20)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#6 2023-04-18 23:55:33

ABOhiccups
Member
Registered: 2017-08-27
Posts: 97

Re: [HELP] Keep torguard-bin up-to-date

Trilby wrote:
ABOhiccups wrote:

I have submit a request to be co-maintainer or for their package to be orphan several days ago. But, what I'm understanding. It takes 180 days to accept if the maintainer did not respond

No.  The waiting period is two weeks from when the package is flagged outdated.  Then orphan requests should be granted so long as the current maintainer doesn't reply in a reasonable period.  The 180 days is the opposite end of the spectrum: if a package is outdated for 180 days the request would be granted immediately.

If this package has been outdated for (more than) two weeks, your orphan request is valid and the TU(s) are likely to grant it at any time now if the current maintainer hasn't replied.

In any case, submitting a duplicate package is not appropriate.

I have submitted a request for orphan. The AUR Package was been flagged out-of-date on March 23, 2023. If what you’re saying is true. I should be automatically accepted. Plus, I have tried to push a new version of torguard with git command and it won’t let me push under torguard repro.

https://wiki.archlinux.org/title/AUR_su … nes#Orphan

Offline

#7 2023-04-19 01:32:34

Scimmia
Fellow
Registered: 2012-09-01
Posts: 12,150

Re: [HELP] Keep torguard-bin up-to-date

No, the grace period is 2 weeks after you submitted the request. It's only automatic if it's been out of date for 180 days.

Offline

#8 2023-04-19 03:52:00

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,330
Website

Re: [HELP] Keep torguard-bin up-to-date

ABOhiccups wrote:
Trilby wrote:

if a package is outdated for 180 days the request would be granted immediately.

If what you’re saying is true. I should be automatically accepted.

Do you not understand how if statements work, or do you think March 23 was more than 180 days ago?

I suspect your request should be accepted soon(ish).  Though if you go around selectively quoting and interpreting in such ways, you stand a fair chance of alienating anyone who would be in a position to process that request.

Last edited by Trilby (2023-04-19 03:52:40)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#9 2023-04-19 06:15:27

ABOhiccups
Member
Registered: 2017-08-27
Posts: 97

Re: [HELP] Keep torguard-bin up-to-date

I toke Coco's torguard PKGBUILD. Modify by remove some of package that are not required by TorGuard, add all packages that are required by TorGuard, and leave out some packages as optional (such as wireguard-tools).

I remove torguard.sysusers. I add torguard.install (required by TorGuard). I changed "package" lines to matched from PKGBUILD by TorGuard Support.

After I done testing. TorGuard works perfect! The app does auto startup after booting up and login to desktop.

The best part is with this modify PKGBUILD. No uploading to GitHub required! (I'm referring to torguard-bin. Sense AUR don't take larger files like .Tar folder.)

Here's a modify PKGBUILD.

# Maintainer: coco
# Co-Maintainer: dramm <dramm at archlinux dot email>
# Co-Maintainer: ABOhiccups <https://twitter.com/ABOhiccups>
# Contributor: thatgeek
# Contributor: TorGuard Support <support@torguard.com>
pkgname=torguard
pkgver=4.8.17
build=build.242.1+gcefc4e9
pkgrel=1
pkgdesc="TorGuard VPN Software
 Stay private online with TorGuard's anonymous VPN software and connect to 37+ countries worldwide."
arch=('x86_64')
url="https://www.torguard.net"
depends=('iproute2' 'psmisc' 'libxkbcommon-x11')
optdepends=('wireguard-tools: wireguard support')
license=(custom)
source=("https://updates.torguard.biz/Software/Linux/torguard-v${pkgver}-amd64-arch.tar.gz")
sha256sums=('f4b6d999ed0db54739e261d2ab44afdde7bbb87ba84f71670a61baa291cbcfc0')
install=torguard.install

prepare() {
	tar -xf "${srcdir}/${pkgname}-v${pkgver}-${build}-amd64-arch/torguard-v${pkgver}-${build}-amd64-arch.tar"
}

package() {
        cp -r "$srcdir"/*/* "$pkgdir"
	find "$pkgdir"/opt/torguard/ -type f -exec chmod 644 {} \;
        find "$pkgdir"/opt/torguard/ -name torguard -exec chmod 755 {} \;
        find "$pkgdir"/opt/torguard/ -name torguard-wrapper -exec chmod 755 {} \;
        find "$pkgdir"/opt/torguard/ -name ss-local -exec chmod 755 {} \;
        find "$pkgdir"/opt/torguard/ -name openvpn -exec chmod 755 {} \;
        find "$pkgdir"/opt/torguard/ -name openconnect -exec chmod 755 {} \;
        find "$pkgdir"/opt/torguard/ -name vpnc-script -exec chmod 755 {} \;
        find "$pkgdir"/opt/torguard/ -name stunnel_5_42 -exec chmod 755 {} \;
        find "$pkgdir"/opt/torguard/ -name stunnel_5_57 -exec chmod 755 {} \;
        find "$pkgdir"/opt/torguard/bin/ -name torguard-startup.desktop -exec chmod 664 {} \;
        find "$pkgdir"/etc/sudoers.d/ -name torguard -exec chmod 440 {} \;

	install -d "$pkgdir"/usr/bin/
	ln -s /opt/torguard/bin/torguard-wrapper "$pkgdir"/usr/bin/torguard
}

Should I update it to torguard-bin or wait until torguard is in orphan (or a maintainer add me as co-maintainer)?

Last edited by ABOhiccups (2023-04-19 06:17:52)

Offline

#10 2023-04-19 11:14:58

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 13,012

Re: [HELP] Keep torguard-bin up-to-date

The PKGBUIILD looks a lot better but does need some changes.

build=build.242.1+gcefc4e9

The build var doesn't appear anywhere else in the PKGBUILD, can that line be removed (or commented if it is info) ?

license=(custom)

Custom licenses need to be placed in $pkgdir/usr/share/licenses/$pkgname , see https://wiki.archlinux.org/title/PKGBUILD#license

For  a proper review you should also post the contents of torguard.install .

ABOhiccups wrote:

Should I update it to torguard-bin or wait until torguard is in orphan (or a maintainer add me as co-maintainer)?

Personally I'd file a deletion request for torguard-bin and post the new PKGBUILD (or a link to it and other needed files ) in the aur comments for torguard .


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#11 2023-04-19 17:58:54

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

Re: [HELP] Keep torguard-bin up-to-date

I suspect you can remove prepare() and the cp plus all the find lines from package and replace it with

bsdtar -xf "${srcdir}/${pkgname}-v${pkgver}-${build}-amd64-arch/torguard-v${pkgver}-${build}-amd64-arch.tar" -C "$pkgdir" -s"/torguard-v${pkgver}-${build}-amd64-arch//"

Offline

#12 2023-04-19 18:45:09

ABOhiccups
Member
Registered: 2017-08-27
Posts: 97

Re: [HELP] Keep torguard-bin up-to-date

Lone_Wolf wrote:

The build var doesn't appear anywhere else in the PKGBUILD, can that line be removed (or commented if it is info) ?

I think it's not possible. If I remove build line. PKGBUILD won't install TorGuard. Every versions has different build numbers.

Lone_Wolf wrote:

Custom licenses need to be placed in $pkgdir/usr/share/licenses/$pkgname , see https://wiki.archlinux.org/title/PKGBUILD#license

I was thinking about that. Sense Official PKGBUILD by TorGuard Support shows Custom on License. Do you have a better name for License?

Offline

#13 2023-04-19 19:30:36

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

Re: [HELP] Keep torguard-bin up-to-date

ABOhiccups wrote:
Lone_Wolf wrote:

Custom licenses need to be placed in $pkgdir/usr/share/licenses/$pkgname , see https://wiki.archlinux.org/title/PKGBUILD#license

I was thinking about that. Sense Official PKGBUILD by TorGuard Support shows Custom on License. Do you have a better name for License?

The licenses files in opt/torguard/license/ include at least the following common licenses Apache, BSD, GPL2+, GPL3, LGPL21, LGPL3, MIT and zlib as well as Custom and public-domain.

Offline

#14 2023-04-19 20:19:22

ABOhiccups
Member
Registered: 2017-08-27
Posts: 97

Re: [HELP] Keep torguard-bin up-to-date

Okay, I've made some changes based on request. After testing it. It works perfect as the same from last time I've modify it. The lines in PKGBUILD is now smaller.

Here's the finish progress.

# Maintainer: ABOhiccups <https://twitter.com/ABOhiccups>
# Contributor: Arch Linux Community
# Contributor: TorGuard Support <support@torguard.com>
pkgname=torguard
pkgver=4.8.17
build=build.242.1+gcefc4e9
pkgrel=1
pkgdesc="TorGuard VPN Software
 Stay private online with TorGuard's anonymous VPN software and connect to 37+ countries worldwide."
arch=('x86_64')
url="https://www.torguard.net"
depends=('iproute2' 'psmisc' 'libxkbcommon-x11')
optdepends=('wireguard-tools: wireguard support')
license=(custom)
source=("https://updates.torguard.biz/Software/Linux/torguard-v${pkgver}-amd64-arch.tar.gz")
sha256sums=('f4b6d999ed0db54739e261d2ab44afdde7bbb87ba84f71670a61baa291cbcfc0')
install=torguard.install

package() {
        bsdtar -xf "${srcdir}/${pkgname}-v${pkgver}-${build}-amd64-arch/torguard-v${pkgver}-${build}-amd64-arch.tar" -C "$pkgdir" -s"/torguard-v${pkgver}-${build}-amd64-arch//"

	install -d "$pkgdir"/usr/bin/
	ln -s /opt/torguard/bin/torguard-wrapper "$pkgdir"/usr/bin/torguard
}

With me know what you think.

Offline

#15 2023-04-20 09:26:46

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 13,012

Re: [HELP] Keep torguard-bin up-to-date

loqs wrote:
ABOhiccups wrote:
Lone_Wolf wrote:

Custom licenses need to be placed in $pkgdir/usr/share/licenses/$pkgname , see https://wiki.archlinux.org/title/PKGBUILD#license

I was thinking about that. Sense Official PKGBUILD by TorGuard Support shows Custom on License. Do you have a better name for License?

The licenses files in opt/torguard/license/ include at least the following common licenses Apache, BSD, GPL2+, GPL3, LGPL21, LGPL3, MIT and zlib as well as Custom and public-domain.

GPL* & LGPL* only need to be mentioned in licenses array in PKGBUILD , the others need to be mentioned but also require separate license files.
The simplest solution is to copy the whole content of $pkgdir/opt/torguard/license to $pkgdir/usr/share/licenses/$pkgname .


Since you didn't post torguard.install yet, here it is (copied from the 4.8.17 download) .:

pre_install() {
        if ! grep -q "^torguard:" /etc/group ; then groupadd --system torguard; fi
}

pre_upgrade() {
        if ! grep -q "^torguard:" /etc/group ; then groupadd --system torguard; fi
}

post_remove() {
}

That looks like a generic method to add a usergroup from the sysv init days and is very likely to cause issues on systemd using distros like archlinux .
See cups for an example how to create a system group with systemd .
Also check https://man.archlinux.org/man/sysusers.d.5.en for details.

Last edited by Lone_Wolf (2023-04-20 09:52:19)


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

Board footer

Powered by FluxBB