You are not logged in.

#1 2016-02-15 05:56:31

twnaing
Member
Registered: 2016-02-15
Posts: 2

[Request for review] first package SoftEtherVPN

I'm new to AUR packaging. Please help me reviewing the following PKGBUILD for SoftEtherVPN.

Currently, AUR has softethervpn-git and it bases on git and downloads the whole git repo (almost 500 MB). I am trying to create AUR with SoftEtherVPN RTM source.

# Maintainer: Tun Win Naing <twnaing(at)outlook(dot)com>
pkgname=softethervpn
pkgver=v4.18_9570
pkgrel=1
pkgdesc="Multi-protocol VPN Program from University of Tsukuba"
arch=('i686' 'x86_64')
source=('http://www.softether-download.com/files/softether/v4.18-9570-rtm-2015.07.26-tree/Source_Code/softether-src-v4.18-9570-rtm.tar.gz' 
		'softethervpn-bridge.service' 
		'softethervpn-client.service' 
		'softethervpn-server.service')
sha1sums=('1ab52bd794a3ae9cf6b9b8c0ad978ef0d222349b'
          'e3d0c38be26123bb533e80f0a595e9867e9cf6ad'
          'efd246e8176683237609b7dae2e12300169b297f'
          'cdfb0c943128286bb318b5c044e5ca53c1dcffff')
license=('GPL')
makedepends=()
depends=('bash' 'openssl')
url="http://www.softether.org/"

#pkgver() {
#  cd "SoftEtherVPN"
#  git log | grep -o -m1 'v[0-9].*' | tr '-' '.'
#}

build(){
  cd "${srcdir}/${pkgver//_/-}"
  if [ "${CARCH}" == "i686" ]; then 
    cp src/makefiles/linux_32bit.mak Makefile
  elif [ "${CARCH}" == "x86_64" ]; then 
    cp src/makefiles/linux_64bit.mak Makefile
  fi
  make
}

package(){
  cd "${srcdir}/${pkgver//_/-}"
  install -Dm644 bin/vpnserver/hamcore.se2 "${pkgdir}"/usr/lib/softethervpn/hamcore.se2
  install -d "${pkgdir}"/usr/bin
  for inst in vpnclient vpnserver vpnbridge vpncmd
  do
    install -Dm755 bin/${inst}/${inst} "${pkgdir}"/usr/lib/softethervpn/${inst}/${inst}
    ln -s /usr/lib/softethervpn/hamcore.se2 "${pkgdir}"/usr/lib/softethervpn/${inst}/hamcore.se2
    echo "#!/bin/sh" > "${pkgdir}"/usr/bin/${inst}
    echo /usr/lib/softethervpn/${inst}/${inst} '"$@"' >> "${pkgdir}"/usr/bin/${inst}
    echo 'exit $?' >> "${pkgdir}"/usr/bin/${inst}
    chmod 755 "${pkgdir}"/usr/bin/${inst}
  done
  install -d "${pkgdir}"/usr/lib/systemd/system
  install -Dm644 "${srcdir}"/*.service "${pkgdir}"/usr/lib/systemd/system
}

There are also some questions I would like to have answers for.

  1. the PKGBUILD file is based on ava1ar's softethervpn-git, should I add him as # Maintainer: ava1ar - <mail(at)ava1ar(dot)me>?

  2. should I include conflicts=('softethervpn-git')? I do not see other git-based package included that

Offline

#2 2016-02-15 06:25:10

x33a
Forum Fellow
Registered: 2009-08-15
Posts: 4,587

Re: [Request for review] first package SoftEtherVPN

twnaing wrote:

tthe PKGBUILD file is based on ava1ar's softethervpn-git, should I add him as # Maintainer: ava1ar - <mail(at)ava1ar(dot)me>?

Add him as a contributor, not maintainer.

should I include conflicts=('softethervpn-git')? I do not see other git-based package included that

You should add that.

Also, remove the empty makedepends line.

Offline

#3 2016-02-15 20:14:29

Stefan Husmann
Member
From: Germany
Registered: 2007-08-07
Posts: 1,391

Re: [Request for review] first package SoftEtherVPN

You should probably then also add provides=('softethervpn-git'), but normally this is done the other way around: in the vcs-packages.

Offline

#4 2016-02-16 05:57:32

twnaing
Member
Registered: 2016-02-15
Posts: 2

Re: [Request for review] first package SoftEtherVPN

Thank you for the reviews. I'll make changes when I get back from work.

Offline

Board footer

Powered by FluxBB