SINP Is Not Portage

December 27, 2006 at 10:08 pm 4 comments

There was some interesting talk on the ##slackware channel about someone running a portage on Slackware. It’s a cool idea to think about, so I decided to rig up a script to integrate SlackBuilds from the project with Slack’s native package manager. The result is SINP. Unlike portage SINP is not a package manager. All it does is download SlackBuilds, run the SlackBuilds, and install the resulting package. And in true Slackware fashion it does not track dependencies. This means that there is no local database that you have to keep updated, and you don’t have to worry about a broken database that winds up corrupting everything. (as has been my luck with from source distros)

The script isn’t nearly as polished as it will be, but it gets the job done, and it needs to be run as root.

./sinp -s something searches for whatever something is.
./sinp -d something downloads the SlackBuild tarball
./sinp -p tells sinp to actuall run the SlackBuild

and finally ./sinp -i full_path_to_package calls installpkg to install the new package

When using -d I recommend having the argument as (including the quotes) `./sinp -s whatever` because that’s the format the download function needs. FOR NOW

Also when using -i you need to put the full path to the tgz file. Again, something that will be cleaned up.

A full run (download, make package, install package) for supertux would look like ./sinp -d `./sinp -s supertux` -p -i /tmp/supertux*.tgz

When all the smoothing out is complete it should look like ./sinp -dpi supertux

I’d like to eventually host the project on a Slackware specific site, but sourceforge would be OK.

If you’d like to try it out the script is the first comment. Any feedback is welcome. 🙂

Entry filed under: Uncategorized. Tags: , , , , , , .

Duplicates: The Horror!!! SINP Update

4 Comments Add your own

  • 1. dosnlinux  |  December 27, 2006 at 10:09 pm


    # SINP: SINP is not portage

    # source package addon to pkgtools
    # uses slackbuild files from to make packages to install

    # requires ncftp, wget

    # TODO: fix how $FILE is handled to decrease dependacies of other options
    FILE="" # file to download/search for

    # search for the slackbuild by name
    # $1 = regex to use in search
    # TODO: make it so that only the tarball name is matched
    FILE=`ncftpls -1R | grep '.tar' | grep $1`

    echo $FILE

    # download the slackbuild tarball
    # TODO: work FILE better
    # TODO: work with Search function better
    # $1 = tarball path relative to
    FILE=`echo $1 | sed 's/\.\///'`


    # download the source tarball from *.info
    # TODO: check md5sum after downloading
    DOWNLOAD=`grep DOWNLOAD *.info | cut -d '=' -f2`
    MD5SUM=`grep MD5SUM *.info | cut -d '=' -f2`

    wget $DOWNLOAD

    # make the binary package

    # untar
    TARBALL=`echo $FILE | sed 's/.*\///'`
    FILE=`echo $TARBALL | sed 's/.tar.*$//'`

    tar xf $TARBALL || exit 1
    cd $FILE


    sh ./*.SlackBuild

    # TODO: clean up
    # TODO: make it so this doesn't need an arg
    installpkg $1

    # init
    while getopts pi:d:s: option
    case $option in
    s) SlackBuild_search $OPTARG;;
    d) SlackBuild_download $OPTARG;;
    p) SlackBuild_package;;
    i) SlackBuild_installpkg $OPTARG;;
    *) exit 1;;

  • 2. dosnlinux  |  December 27, 2006 at 10:15 pm

    also, future features that I plan to add to it.

    Search by description
    md5 checking
    install from personal mirror of
    updatepkg support

  • 3. Michiel  |  December 28, 2006 at 12:40 am

    if you really want to go all out eventually with a pkgtool integration perhaps you could also look at ‘dialog’ for the interface?

  • 4. dosnlinux  |  December 28, 2006 at 12:54 am

    OOOO… that would be cool! 😀 Plus I’ve always wanted to learn how to make those kinds of GUI’s. 🙂


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Trackback this post  |  Subscribe to the comments via RSS Feed


%d bloggers like this: