arch里的torque已经有两年没有更新了,最新版都更新到了4.2.6.1了,而AUR里还是4.2.0的版本.重新修改了一下PKGBUILD.

首先执行yaourt -S torque,等到下载开始后,终止下载,可以去官网直接下4.2.6.1v版.做这一步的原因是要systemd的配置文件.从/tmp/yaourt-aur-user/文件下吧torque的整个文件夹拷贝出来,换成下面的PKGBUILD文件,重新makepkg PKFGUILD.适合systemd的arch.

# Maintainer: flub
# Change: hsyyf

pkgname=torque
pkgver=4.2.6.1
pkgrel=2
pkgdesc='An open source resource manager providing control over batch jobs and distributed compute nodes.'
url='http://www.adaptivecomputing.com/products/open-source/torque/'
arch=('i686' 'x86_64')
license=('GPL')
depends=('openssh' 'libxml2')
makedepends=('make' 'gcc')
optdepends=()
install=torque.install
options=(!libtool)
backup=(var/spool/torque/server_name var/spool/torque/mom_priv/config var/spool/torque/serv_priv/{nodes,serverdb})
source=("http://adaptive.wpengine.com/resources/downloads/${pkgname}/${pkgname}-${pkgver}.tar.gz"
"torque-server" "torque-node" "torque-scheduler"
"torque-server.service" "torque-node.service" "torque-scheduler.service")
md5sums=('a87afed9436967cf10468ef76a7e8fcd'
'41581ea0fba02960ec7c128432f8f6ec'
'dfe8aa183dd9ec5dfcc2ba6a5f234053'
'e17b16f4898f1bfbbc4a6c208973889e'
'ba0040be81343b261b2add9451e350cc'
'5ae10463e54d33ec34fc5dc09f3d619e'
'0059e2e8fb803ccf0ecea0aa708a61ea')

build() {
cd "${srcdir}/${pkgname}-${pkgver}"
./configure --with-default-server=localhost \
--with-server-home=/var/spool/torque \
--with-rcp=scp \
--with-tcl=no \
--disable-gui \
--prefix=/usr \
--disable-gcc-warnings \
--mandir=/usr/share/man || return 1
mv src/resmom/Makefile src/resmom/Makefile.old
cat src/resmom/Makefile.old | sed 's/$(MOMLIBS) $(PBS_LIBS)/$(PBS_LIBS) $(MOMLIBS)/g' > src/resmom/Makefile
make || return 1
}

package() {
cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}/" install || return 1
mkdir -p ${pkgdir}/etc/systemd/system/
cp ${srcdir}/*.service ${pkgdir}/etc/systemd/system/.
}

# vim:set ts=2 sw=2 et:

作者 hsyyf

在 “最新版torque的PKGBUILD” 有 1 条评论
  1. 首先执行yaourt -S torque,等到下载开始后,终止下载,可以去官网直接下4.2.6.1v版.做这一步的原因是要systemd的配置文件.从/tmp/yaourt-aur-user/文件下吧torque的整个文件夹拷贝出来,换成下面的PKGBUILD文件,重新makepkg PKFGUILD.适合systemd的arch.

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注