aboutsummaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
authorAndrzej Telszewski <atelszewski@gmail.com>2011-07-28 09:58:29 -0300
committerNiels Horn <niels.horn@slackbuilds.org>2011-07-28 09:58:29 -0300
commit3dfc7de500436317b8eb9f2788a86ed4fec22476 (patch)
treed9282523bc9ac1bca815df30d6257fcbd87be30e /python
parent23637dd85cab104b2e98b480c6525021e6401300 (diff)
python/gerbmerge: Added (A Gerber-file merging program)
Signed-off-by: Niels Horn <niels.horn@slackbuilds.org>
Diffstat (limited to 'python')
-rw-r--r--python/gerbmerge/README10
-rw-r--r--python/gerbmerge/fix-install-paths.patch24
-rw-r--r--python/gerbmerge/gerbmerge.SlackBuild59
-rw-r--r--python/gerbmerge/gerbmerge.info10
-rw-r--r--python/gerbmerge/slack-desc19
5 files changed, 122 insertions, 0 deletions
diff --git a/python/gerbmerge/README b/python/gerbmerge/README
new file mode 100644
index 0000000000000..d3758f88e5d05
--- /dev/null
+++ b/python/gerbmerge/README
@@ -0,0 +1,10 @@
+GerbMerge is a program for combining (panelizing) the CAM data from
+multiple printed circuit board designs into a single set of CAM files. The
+purpose of doing so is to submit a single job to a board manufacturer,
+thereby saving on manufacturing costs.
+
+Advice: "Users of GerbMerge complain that the configuration file is the
+biggest hurdle to overcome in using the program. Don't panic. Start with
+a sample configuration file and modify it for your own jobs".
+
+This requires SimpleParse.
diff --git a/python/gerbmerge/fix-install-paths.patch b/python/gerbmerge/fix-install-paths.patch
new file mode 100644
index 0000000000000..dd6ea36f71636
--- /dev/null
+++ b/python/gerbmerge/fix-install-paths.patch
@@ -0,0 +1,24 @@
+diff -Naur gerbmerge-1.8old/setup.py gerbmerge-1.8new/setup.py
+--- gerbmerge-1.8old/setup.py 2011-07-11 19:15:46.000000000 +0200
++++ gerbmerge-1.8new/setup.py 2011-07-11 19:13:20.000000000 +0200
+@@ -37,7 +37,7 @@
+ BinFiles = ['misc/gerbmerge.bat']
+ BinDir = '.'
+ else:
+- DestLib = distutils.sysconfig.get_config_var('LIBPYTHON')
++ DestLib = "/usr/lib/python2.6"
+ DestDir = os.path.join(DestLib, 'gerbmerge')
+ BinFiles = ['misc/gerbmerge']
+ BinDir = distutils.sysconfig.get_config_var('BINDIR')
+@@ -74,10 +74,7 @@
+ url = "http://ruggedcircuits.com/gerbmerge",
+ packages = ['gerbmerge'],
+ platforms = ['all'],
+- data_files = [ (DestDir, AuxFiles),
+- (os.path.join(DestDir,'testdata'), SampleFiles),
+- (os.path.join(DestDir,'doc'), DocFiles),
+- (BinDir, BinFiles) ]
++ data_files = [ (BinDir, BinFiles) ]
+ )
+
+ do_fix_perms = 0
diff --git a/python/gerbmerge/gerbmerge.SlackBuild b/python/gerbmerge/gerbmerge.SlackBuild
new file mode 100644
index 0000000000000..d3c89b1398a96
--- /dev/null
+++ b/python/gerbmerge/gerbmerge.SlackBuild
@@ -0,0 +1,59 @@
+#!/bin/sh
+
+# Slackware build script for GerbMerge
+
+# Written by Andrzej Telszewski <atelszewski@gmail.com>
+
+PRGNAM=gerbmerge
+VERSION=1.8
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i486 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM-$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
+cd $PRGNAM-$VERSION
+
+patch -p1 < $CWD/fix-install-paths.patch
+
+chown -R root:root .
+find . \
+ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
+ -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
+ -exec chmod 644 {} \;
+
+python setup.py install --root=$PKG
+
+find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
+ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
+
+chmod 0755 $PKG/usr/bin/gerbmerge
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a doc testdata COPYING \
+ $PKG/usr/doc/$PRGNAM-$VERSION
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
diff --git a/python/gerbmerge/gerbmerge.info b/python/gerbmerge/gerbmerge.info
new file mode 100644
index 0000000000000..cab1cac75280e
--- /dev/null
+++ b/python/gerbmerge/gerbmerge.info
@@ -0,0 +1,10 @@
+PRGNAM="gerbmerge"
+VERSION="1.8"
+HOMEPAGE="http://ruggedcircuits.com/gerbmerge/"
+DOWNLOAD="http://ruggedcircuits.com/gerbmerge/gerbmerge-1.8.tar.gz"
+MD5SUM="b34d86e47de1f5c9ce3d2d4c3b35662c"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+MAINTAINER="Andrzej Telszewski"
+EMAIL="atelszewski@gmail.com"
+APPROVED="Niels Horn"
diff --git a/python/gerbmerge/slack-desc b/python/gerbmerge/slack-desc
new file mode 100644
index 0000000000000..def81e65b49d8
--- /dev/null
+++ b/python/gerbmerge/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description. Line
+# up the first '|' above the ':' following the base package name, and the '|'
+# on the right side marks the last column you can put a character in. You must
+# make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':'.
+
+ |-----handy-ruler------------------------------------------------------|
+gerbmerge: GerbMerge (A Gerber-file merging program)
+gerbmerge:
+gerbmerge: GerbMerge is a program for combining (panelizing) the CAM data from
+gerbmerge: multiple printed circuit board designs into a single set of CAM
+gerbmerge: files.
+gerbmerge:
+gerbmerge: The purpose of doing so is to submit a single job to a board
+gerbmerge: manufacturer, thereby saving on manufacturing costs.
+gerbmerge:
+gerbmerge:
+gerbmerge: