Skip to content

Instantly share code, notes, and snippets.

@lacostej
Created December 25, 2012 18:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lacostej/4374626 to your computer and use it in GitHub Desktop.
Save lacostej/4374626 to your computer and use it in GitHub Desktop.
Fix lexmark-printer-utility-1.0-2.i386.deb
dir=tmp
rm -r $dir
mkdir $dir
dpkg -x lexmark-printer-utility-1.0-2.i386.deb $dir
dpkg-deb -e lexmark-printer-utility-1.0-2.i386.deb $dir/DEBIAN
file=$dir/usr/local/lexmark/printer_utility/etc/lxpsu.desktop
sed -e 's/\$JARVIS_VENDOR_SHORT_NAME%%/lexmark/g' $file > $file.1
mv $file.1 $file
file=tmp/usr/local/lexmark/printer_utility/bin/.scripts/lxpsu
sed -e 's/%%JARVIS_VENDOR_SHORT_NAME/lexmark/g' $file > $file.1
mv $file.1 $file
file=tmp/DEBIAN/postinst
sed -e 's/%%JARVIS_VENDOR_PREFIX%%/lx/g' $file > $file.1
mv $file.1 $file
chmod +x $file
grep -r JARVIS $dir
mkdir -p build
dpkg-deb -b $dir build
ls build
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment