Last active
February 21, 2019 03:25
-
-
Save madc/1f19f440b1bc5e904967c7a9ce2acf0a to your computer and use it in GitHub Desktop.
For makerbot-desktop 3.8.0, https://aur.archlinux.org/packages/makerbot-desktop
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
post_remove() { | |
update-mime-database /usr/share/mime | |
update-desktop-database -q | |
gtk-update-icon-cache | |
[[ -z $2 ]] && echo -e "Stopping conveyor.service" | |
[[ -z $2 ]] && echo -e "Disabling conveyor.service" | |
systenctl disable conveyor 2>/dev/null | |
userdel -r conveyor >/dev/null 2>/dev/null | |
[[ -z "$2" ]] && echo -e "Restoring /run/lock's permissions" | |
chmod g-w /run/lock | |
true | |
} | |
post_install() { | |
## Reuse post_remove code | |
post_remove "null" "null" | |
## Create conveyor user | |
echo -e "\nAdding user: conveyor" | |
if ! getent passwd conveyor >/dev/null; then | |
useradd --system \ | |
-M -d /dev/null \ | |
--shell /bin/false conveyor | |
gpasswd -a conveyor lp | |
gpasswd -a conveyor uucp | |
fi | |
# Create and set permissions for /var/run/conveyor | |
mkdir -p -m 3777 /var/run/conveyor | |
chmod g+s /var/run/conveyor | |
chgrp conveyor /var/run/conveyor | |
# Set proper permissions for any existing lock files | |
chgrp conveyor /var/run/conveyor/* >/dev/null 2>&1 || true | |
chown conveyor /var/run/conveyor/* >/dev/null 2>&1 || true | |
chmod 0644 /var/run/conveyor/* >/dev/null 2>&1 || true | |
# Create and set permissions for /var/log/conveyor | |
mkdir -p -m 3777 /var/log/conveyor | |
chmod g+w /var/log/conveyor | |
chgrp conveyor /var/log/conveyor | |
# Set proper permissions for any existing log files | |
chgrp conveyor /var/log/conveyor/* >/dev/null 2>&1 || true | |
chown conveyor /var/log/conveyor/* >/dev/null 2>&1 || true | |
chmod 0664 /var/log/conveyor/* >/dev/null 2>&1 || true | |
echo -e "Changing /run/lock's permissions. Setting g+w" | |
chmod g+w /run/lock | |
gpasswd -a conveyor root | |
chown /var/log/conveyor/conveyord.log | |
## Enable and start conveyor service | |
msg2 "Enable and start conveyor.service to be able to connect to printer\n #~ systemctl enable conveyor.service && systemctl start conveyor.service" | |
} | |
post_upgrade() { | |
touch /var/log/conveyor/conveyord.log | |
chown conveyor /var/log/conveyor/conveyord.log | |
#msg2 "Please restart conveyor.service with\n #~ systemctl restart conveyor.service" | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Maintainer: Francisco Martinez <zomernifalt at gmail dot com> | |
pkgname=makerbot-desktop | |
pkgver=3.8.0 | |
_openmeshver=3.2_3.2 | |
pkgrel=2 | |
pkgdesc="A complete, free 3D printing solution for discovering, managing, and sharing your 3D prints." | |
arch=('x86_64') | |
url="https://www.makerbot.com/desktop" | |
license=('GPL') | |
depends=('boost' 'glibc>=2.4' 'hicolor-icon-theme' 'libdbus>=1.0.2' 'libgl' 'qt5-base>=5.3.0' 'qt5-webkit>=5.0.2' 'zenity' 'zlib>=1.1.4') | |
options=('!strip') | |
install="$pkgname.install" | |
_fakeubunturelease=15.04 | |
_baseurl="http://downloads.makerbot.com/makerware/ubuntu/pool/main" | |
if [ $CARCH == "x86_64" ]; then | |
_arch="amd64" | |
md5sums=( | |
'd80b74478b91d2145a3ca809437bc426' | |
'6971eaa9d67001aa73e4739bf36780d6' | |
'c8c59831ef18615de4fe4c322d7726b6' | |
'3f617f3a6a9c0bf2fd42920bed7868a3' | |
'e0c6678cb4dba22c04e173b63eb711e1' | |
'51b5f5afa0750582bb0603643b8abb49' | |
'9caaa528f50a3b4a5082361a09457b4d' | |
'b81ca46ec103428452cc6042e0338f4a' | |
# '960a9946a5d20b8e35936d8e55b97da8' | |
'0a4814dd96e5ab61a26b0b03f01173dc' | |
'94134f3f575b327006cc0524037dce87' | |
'8545ac7f1db4c7a2d23f5864b6f78a9b' | |
'14cad79fd2ba8862c75166986261752e' | |
'e96db9bf01aab3b00d72cb7f9e541d90') | |
else | |
_arch="i386" | |
md5sums=( | |
'2c28b1732a6f2053df1b1e4c08ff0c4f' | |
'45faed2b2c244e2c1879d3ba68a93616' | |
'c91f77866d1c83d707616745cf37285c' | |
'0f77872559c4d9c6cb0880df18824e7a' | |
'9b3d3dac9590a06216b549506d10ad3d' | |
'bccccd52305356ecca096c6c9b9aea06' | |
'2aa71634bf86a0aee2ffd6bea9abb811' | |
'9e0a389f8644f283a57a7e4d32a0dac6' | |
# '15f5ff9c402fff71b59e93a98ff46325' | |
'437590ee186f57c7effaf6bdbe0fd007' | |
'52c78dc84e9a695bb12f0e16bbdbb9ec' | |
'ee24c1da5b85fb146e3ef6164031447c' | |
'93903b032f99a0efcf3c270673f2be2d' | |
'3aabeea413dab5b9a1085d26572d4599') | |
fi | |
source=( | |
"$_baseurl/m/makerware/makerware_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"$_baseurl/m/makerware/conveyor_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"$_baseurl/m/makerware/conveyor-common_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"$_baseurl/m/makerware/conveyor-ui_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"$_baseurl/m/makerware/libmbqtutils_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"$_baseurl/m/makerware/libthing_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"$_baseurl/m/makerware/libtinything_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"$_baseurl/m/makerware/libtoolpathviz_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
# "$_baseurl/m/makerware/mb-libjsoncpp_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"$_baseurl/m/makerware/mb-fopenhack_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"$_baseurl/m/makerware/mb-libjsonrpc_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"$_baseurl/m/makerware/mbacceleration_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"$_baseurl/m/makerware/sliceconfig_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"$_baseurl/o/openmesh/libopenmesh-${_openmeshver}-${_fakeubunturelease}_${_arch}.deb") | |
noextract=( | |
"makerware_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"conveyor_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"conveyor-ui_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"conveyor-common_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"libmbqtutils_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"libthing_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"libtinything_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"libtoolpathviz_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
# "mb-libjsoncpp_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"mb-fopenhack_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"mb-libjsonrpc_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"mbacceleration_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"sliceconfig_${pkgver}-${_fakeubunturelease}_${_arch}.deb" | |
"libopenmesh-${_openmeshver}-${_fakeubunturelease}_${_arch}.deb") | |
install="$pkgname.install" | |
package() { | |
cd ${pkgdir} | |
msg2 "Extracting DEBs" | |
for file in $srcdir/*.deb; do ar p $file data.tar.xz | tar -xJ; done | |
msg2 "Moving files around" | |
mv lib/udev/ usr/lib/ | |
rm -r lib | |
for i in program_options filesystem system serialization date_time; do | |
ln -fs /usr/lib/libboost_$i.so usr/lib/libboost_$i.so.1.55.0 | |
done | |
#msg2 "Creating log files" | |
#touch /var/log/conveyor/conveyord.log | |
#chmod g+w /var/log/conveyor/conveyord.log | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Sorry for the late reply. Seems, one does not get notifications on comments here. Unfortunately, I', quite busy atm but I'll have a proper look at it as soon as possible. The PKGBUILD above was not my last try and i managed to run the Makerbot software once (with a new version of jsoncpp0), but got some errors when i tried to run it again.