repackage preinstalled packages

Here is a place for your projects which are not officially supported by the Porteus Team. For example: your own kernel patched with extra features; desktops not included in the standard ISO like Gnome; base modules that are different than the standard ISO, etc...
User avatar
bigbass
Contributor
Contributor
Posts: 151
Joined: 13 Jan 2012, 14:35
Distribution: slackware 14

repackage preinstalled packages

Post#1 by bigbass » 21 Jan 2012, 23:28

this isnt an official package

some tools I wrote a few years ago that I am porting to Porteus
this has a Xdialog front end using a modified rebuildpkg backend * I commented the sources

# repackage any installed packages
# they are placed in /tmp/build##
# packages remain installed nothing is removed just copied

I always do one package at a time to test everything

I am leaving this as a plain *.tgz
so that devs here can test and if they like it they can make a module

this is nice to be able to rebuild any installed package without having to have an
internet connection
so you could rebuild the package and if you wanted to modify it and re install it
bumping the package number of course


I will be rebranding my packages with a _PORT.tgz
that means I tested it on Porteus all my other packages have a different signature
I will be testing and rebranding as I go

http://bigbass-porteus.googlecode.com/f ... 5_PORT.tgz

Joe
Last edited by bigbass on 16 Feb 2012, 15:35, edited 1 time in total.

User avatar
brokenman
Site Admin
Site Admin
Posts: 6105
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v4 all desktops
Location: Brazil

Re: repackage preinstalled packages

Post#2 by brokenman » 23 Jan 2012, 00:02

I found this one a little difficult to use.

simplaret --update usbutils-002-i486-1

Porteus has no gnupg by default so this will result in errors.
this is nice to be able to rebuild any installed package without having to have an
internet connection so you could rebuild the package and if you wanted to modify it and re install it
bumping the package number of course
Can you give an example of how to accomplish this? This would be useful. Porteus has 'extpkg' which will extract a package from a running porteus or from a base module which sounds similar to what this function accomplishes.
How do i become super user?
Wear your underpants on the outside and put on a cape.

User avatar
bigbass
Contributor
Contributor
Posts: 151
Joined: 13 Jan 2012, 14:35
Distribution: slackware 14

Re: repackage preinstalled packages

Post#3 by bigbass » 23 Jan 2012, 03:42

Hey brokenman
Can you give an example of how to accomplish this? This would be useful.
sure, I don't know all the nice features that are now available with Porteus (still learning) what you added however this is a tool I used before and wanted to see if it would work for preinstalled packages
there may be a few ways to achieve the same end result if this is already a built in feature
than its was just a double effort

here is a screen shot how it works

Image

the program reads all the files in /var/log/packages/ash-0.4.0-i486-2
in the above example

then the package gets rebuilt in /tmp/build##
as a *.tgz



P.S the Porteus package management looks great congrats !

Joe

User avatar
brokenman
Site Admin
Site Admin
Posts: 6105
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v4 all desktops
Location: Brazil

Re: repackage preinstalled packages

Post#4 by brokenman » 23 Jan 2012, 12:03

Great works OK. Just a few small glitches that can be easily fixed.

ERROR: Can't make output package in current directory.
done: package rebuilt and stored at /tmp/build4176/.tgz


It will spit a few 'not found' errors as locales and header are exported for shipping in 'devel' base module and many docs are removed. While it didn't recreate the .tgz package it left everything waiting in the build#### directory as designed. Great work!
How do i become super user?
Wear your underpants on the outside and put on a cape.

User avatar
bigbass
Contributor
Contributor
Posts: 151
Joined: 13 Jan 2012, 14:35
Distribution: slackware 14

Re: repackage preinstalled packages

Post#5 by bigbass » 23 Jan 2012, 14:54

Hey brokenman

thanks for trying and the detailed feedback
brokenman » 23 Jan 2012, 12:03
Great works OK. Just a few small glitches that can be easily fixed.

ERROR: Can't make output package in current directory.
done: package rebuilt and stored at /tmp/build4176/.tgz
this is not a Porteus problem or the original apps fault
the reason why so many cool older tools don't and wont work with slackware's pkgtool and company
explodepkg, installpkg, makepkg ,pkgtool ,removepkg ,upgradepkg

is it has a root block and a current directory block this happened around 13.0 or 13.1
*I started adding tools for slackware 12 my stuff stopped working and had to find out why

if you have some free time you could boot clean live cd (no save files) and install the package there
http://forum.porteus.org/viewtopic.php? ... dd4b9bb55d

it fixes the problem that root users have with the recent version of pkgtool and company



It will spit a few 'not found' errors as locales and header are exported for shipping in 'devel' base module and many docs are removed.
well if its there or the devel base module is added or not
it will reproduce only what is installed so if for some reason a cut down version of the package is
installed that is what it will make (a good thing if you dont want to mix dev packages with the cut down installed packages ) it would package them separately since they would have different names


P.S. from another question before I didnt answer
I didnt tweak or test all of the other scripts that are part of simplepkg I only tested rebuildpkg to work

a Big thanks for for trying and the detailed feedback
I started and ended this with a thanks because its
a pleasure to have an easy to read error report

Joe

User avatar
brokenman
Site Admin
Site Admin
Posts: 6105
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v4 all desktops
Location: Brazil

Re: repackage preinstalled packages

Post#6 by brokenman » 23 Jan 2012, 15:31

it has a root block and a current directory block this happened around 13.0 or 13.1
Yep this is what i meant. I believe you can change out from current directory and then create the package no?

Code: Select all

cd ~
makepkg /tmp/someppackage.txz /tmp/buildxxxx
it will reproduce only what is installed
Perfect for Porteus.

In any case i tested the version you suggested (as root) and it does indeed create the package as required. Works flawlessly. Nice. Thanks again for introducing your work to Porteus.
How do i become super user?
Wear your underpants on the outside and put on a cape.

Post Reply