blob: f90fcf33bf15b616b7716cada28a183148f18dfd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
# Maintainer: Sven Schneider <archlinux.sandmann@googlemail.com>
pkgname=youbot_driver-git
pkgver=20150530
pkgrel=1
pkgdesc="Drivers for the KUKA youBot robot"
arch=('i686' 'x86_64')
url="http://www.youbot-store.com/"
license=('LGPL' 'BSD')
depends=('boost-libs')
makedepends=('git' 'cmake' 'boost')
provides=('youbot-driver')
conflicts=('youbot-driver')
_gitroot="https://github.com/svenschneider/youbot_driver.git"
_gitname="youbot_driver"
_gitbranch="ethercat_injection"
prepare() {
cd "${srcdir}"
msg "Connecting to GIT server...."
if [ -d ${_gitname} ] ; then
cd ${_gitname} && git pull origin
msg "The local files are updated."
else
git clone -b ${_gitbranch} ${_gitroot} ${_gitname}
fi
msg "GIT checkout done or server timeout"
msg "Starting make..."
rm -rf "${srcdir}/${_gitname}-build"
git clone "${srcdir}/${_gitname}" "${srcdir}/${_gitname}-build"
}
build() {
cd "${srcdir}/${_gitname}-build/"
sed "s/ADD_LIBRARY(soem/ADD_LIBRARY(soem SHARED/g" -i src/soem/CMakeLists.txt
sed "s/add_library(YouBotDriver/add_library(YouBotDriver SHARED/g" -i CMakeLists.txt
cmake -DCMAKE_INSTALL_PREFIX=/usr .
make
}
package() {
cd "${srcdir}/${_gitname}-build/"
make DESTDIR="${pkgdir}" install
}
|