summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 4eb004cf74cb924226a030f84d6129f820dd83c3 (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
# Maintainer: Dario Pellegrini <pellegrini dot dario at gmail dot com>

pkgname='openscad-mcad-dev-git'
_gitname='MCAD'
pkgver=r491.3a9b9ab
pkgrel=1
pkgdesc='Development branch of the OpenSCAD MCAD library'
url=https://github.com/openscad/MCAD
license=('LGPL')
arch=('any')
source=("git+https://github.com/openscad/MCAD.git#branch=dev")
sha512sums=(SKIP)
depends=('openscad')

pkgver() {
 cd "$_gitname"
 printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

package() {
 mkdir -p $pkgdir/usr/share/openscad/libraries/MCAD/
 cd "$_gitname"

 # The following files are already provided by OpenSCAD
 # removing them to avoid conflicts
 rm array.scad
 rm boxes.scad
 rm curves.scad
 rm gridbeam.scad
 rm lego_compatibility.scad
 rm multiply.scad
 rm polyholes.scad
 rm nuts_and_bolts.scad
 rm screw.scad

 find . -name '*.scad' -exec install -Dm644 {} $pkgdir/usr/share/openscad/libraries/MCAD/{} \;
}