LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   debian packages (https://www.linuxquestions.org/questions/slackware-14/debian-packages-810276/)

icecubeflower 05-26-2010 02:02 PM

debian packages
 
Hey so I downloaded the guitar pro6 demo:
http://www.guitar-pro.com/en/index.php

But it's a .deb package. So uh... now what? It's commercial software. It's not like I can do the ./configure, make, make install thing.

brianL 05-26-2010 02:14 PM

src2pkg can convert .debs to Slackware packages, I think.

ctkroeker 05-26-2010 02:16 PM

It doesn't offer any other format? You could try http://lihavim.wordpress.com/2006/10...-on-slackware/

dugan 05-26-2010 02:18 PM

You can uncompress them with ar.

Intel_ 05-26-2010 02:31 PM

You can use Alien to convert between different package formats, if I understand you.

icecubeflower 05-26-2010 03:09 PM

I don't think I want to bother with Alien, it looks like someone's side project for fun. He says it's experimental. I bet by the time I got it set up it wouldn't even work on my guitar pro .deb package for some reason.

dive 05-26-2010 03:25 PM

Have a look at the slackbuild for google chrome, it repackages deb packages to regular slackware:

http://slackbuilds.org/slackbuilds/1...ome.SlackBuild

T3slider 05-26-2010 03:29 PM

You're stuck with alien or src2pkg I think for the easy way out. I've repackaged Debian binaries in the past but it was always a manual effort culminating in a SlackBuild for future use. `ar -x file.deb` should work, and then you'll want to untar the control and data files. data is the main catch but there are pre/post-install/removal scripts that you would have to adapt for Slackware. Also pay attention to any startup scripts, which would have to be adapted for Slackware's BSD-style init scripts unless you want inconsistency.

icecubeflower 05-26-2010 03:37 PM

So if ar can extract from .deb files then how do I extract from .rpm's? ar says .rpm is an unrecognized format.

T3slider 05-26-2010 03:43 PM

I'm partial to
Code:

rpm2cpio package.rpm | cpio -imdv
but rpm2tgz could be easier. You'd have to pull the scripts separately if you use rpm2cpio.

icecubeflower 05-26-2010 03:48 PM

Oh snap, slack 13.1 is out! Okay this is on hold now. I'm a sub-par linux user and I don't bother with any extra partitions except for swap space so I just save a few files to a removable hard drive and restart from scratch.

T3slider 05-26-2010 04:21 PM

guitarpro6.SlackBuild:
Code:

#!/bin/sh

# Slackware build script for Guitar Pro 6 (demo)

# Copyright 2010 T3slider
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
# permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
#    notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ''AS IS'' AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.


PRGNAM=guitarpro6
PKGNAM=GuitarPro6Demo
VERSION=rev7994
ARCH=${ARCH:-i386}
BUILD=${BUILD:-1}
TAG=${TAG:-_t3s}
CWD=$(pwd)
TMP=${TMP:-/tmp/t3s}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}

rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP || exit 1
rm -rf $PRGNAM-$VERSION
mkdir -p $PRGNAM-$VERSION
cd $PRGNAM-$VERSION
ar -x $CWD/$PKGNAM-$VERSION.deb || exit 1
tar -xvf data.tar.gz || exit 1
chown -R root:root .
chmod -R a-s,u+w,go+r-w .

find -type d -exec chmod 755 {} \;

mv usr opt $PKG

mkdir -p $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
cat $CWD/doinst.sh > $PKG/install/doinst.sh

cd $PKG
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz

slack-desc:
Code:

# 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------------------------------------------------------|
guitarpro6: guitarpro6
guitarpro6:
guitarpro6: Guitar Pro is first and foremost a software designed to edit
guitarpro6: tablatures for guitar, bass, and other fretted instruments from 4 to
guitarpro6: 8 strings.
guitarpro6:
guitarpro6: http://www.guitar-pro.com/
guitarpro6:
guitarpro6:
guitarpro6:
guitarpro6:

doinst.sh:
Code:

if [ -x /usr/bin/update-desktop-database ]; then
  /usr/bin/update-desktop-database usr/share/applications >/dev/null 2>&1
fi
if [ -x /usr/bin/gtk-update-icon-cache ]; then
  /usr/bin/gtk-update-icon-cache -f -t usr/share/icons/hicolor > /dev/null 2>&1
fi

All untested, so keep that in mind. The package builds properly but I only have a pure 64-bit install so I can't test the app. There may be missing dependencies but I have no idea...you'll see when you try to run it I suppose. Running ldd on the executable might tell you any missing dependencies.

icecubeflower 05-26-2010 04:50 PM

What. You wrote a shellscript just for me? I feel special. I am torrenting 32 bit slack 13.1 right now. I will install it later today and give your script a try and see what happens.


All times are GMT -5. The time now is 06:49 AM.