Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Wed 20 Aug 2014, 16:35
All times are UTC - 4
 Forum index » Advanced Topics » Cutting edge
[ANNOUNCE] src2pkg-2.1 released
Moderators: Flash, Ian, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 3 [31 Posts]   Goto page: 1, 2, 3 Next
Author Message
amigo

Joined: 02 Apr 2007
Posts: 2232

PostPosted: Sun 10 Jan 2010, 13:26    Post subject:  [ANNOUNCE] src2pkg-2.1 released
Subject description: fixes for glibc>=2.10 and/or gcc-4.4.x
 

I've just released a new version of src2pkg which fixes some issues when using src2pkg with recent versions of glibc and/or gcc.

Puppy users shouldn't be affected by these problems unless they have upgraded their toolchain somehow to use glibc>=2.10 and/or gcc-4.4.x.

Still, this release also includes a few minor fixes and/or additions which have been made over the last three weeks since the last version of src2pkg was released.

The new installable pet package can be downloaded here.


Edit: the above version is updated from the original src2pkg-2.1-noarch-3.pet to include more changes for 64-bit compatibility, plus whatever other changes have gone in in the last few days.

As always, feedback is highly useful, so, if you are using, or have in the past used src2pkg your comments and suggestions are more than welcome. You can PM me here on the forum, or email me directly at:
< amigo AT ibiblio DOT org >
Gilbert
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2232

PostPosted: Sun 17 Jan 2010, 13:00    Post subject:  

The original version of src2pkg posted in this thread has been updated, so if you have any probelms building src2pkg-helpers, use the updated version. See the top post for the link to the new package.
Any feedback would really be appreciated.
Back to top
View user's profile Send private message 
big_bass

Joined: 13 Aug 2007
Posts: 1747

PostPosted: Tue 19 Jan 2010, 14:22    Post subject:  

Hey Gilbert here's a screen output on slaxer_pup

hope this helps

Joe

--------------


note: using the tgz package I havent tried the pet everything is auto built
this is just a screen output after you install for the first time what to expect to see








#
Code:
src2pkg --setup

Notice - Creating src2pkg-helpers:
src2pkg uses a shared library and a few programs
when creating packages. These binaries will be
compiled on your system for best compatibility,
and installed. When done, src2pkg is ready for use.

TEMP_DIR=/usr/src/src2pkg/builds/src2pkg-helpers
Starting build in 5 seconds
Unpacking sources - OK
Creating libsentry - OK
Creating tar-1.13 - OK
Creating coreutils - OK
Creating unionfs-fuse - OK
- Creating Slackware-type tgz package -

Slackware package maker, version 3.14159.

Searching for symbolic links:
usr/libexec/src2pkg/bin/install -> ginstall

Making symbolic link creation script:
( cd usr/libexec/src2pkg/bin ; rm -rf install )
( cd usr/libexec/src2pkg/bin ; ln -sf ginstall install )

Unless your existing installation script already contains the code
to create these links, you should append these lines to your existing
install script. Now's your chance. :^)

Would you like to add this stuff to the existing install script and
remove the symbolic links ([y]es, [n]o)? n


This next step is optional - you can set the directories in your package
to some sane permissions. If any of the directories in your package have
special permissions, then DO NOT reset them here!

Would you like to reset all directory permissions to 755 (drwxr-xr-x) and
directory ownerships to root.root ([y]es, [n]o)? n

Creating Slackware package: /usr/src/src2pkg/src2pkg-helpers/src2pkg-helpers-1.0-i486-1.tgz

./
install/
install/doinst.sh
install/slack-desc
usr/
usr/share/
usr/share/doc/
usr/share/doc/src2pkg-helpers-1.0/
usr/share/doc/src2pkg-helpers-1.0/README
usr/libexec/
usr/libexec/src2pkg/
usr/libexec/src2pkg/bin/
usr/libexec/src2pkg/bin/unionfs
usr/libexec/src2pkg/bin/install
usr/libexec/src2pkg/bin/unlink
usr/libexec/src2pkg/bin/touch
usr/libexec/src2pkg/bin/stat
usr/libexec/src2pkg/bin/rmdir
usr/libexec/src2pkg/bin/rm
usr/libexec/src2pkg/bin/readlink
usr/libexec/src2pkg/bin/mv
usr/libexec/src2pkg/bin/mknod
usr/libexec/src2pkg/bin/mkdir
usr/libexec/src2pkg/bin/ln
usr/libexec/src2pkg/bin/link
usr/libexec/src2pkg/bin/groups
usr/libexec/src2pkg/bin/ginstall
usr/libexec/src2pkg/bin/cp
usr/libexec/src2pkg/bin/chown
usr/libexec/src2pkg/bin/chmod
usr/libexec/src2pkg/bin/cat
usr/libexec/src2pkg/bin/tar-1.13
usr/libexec/src2pkg/bin/version
usr/libexec/src2pkg/lib/
usr/libexec/src2pkg/lib/libsentry.so

Slackware package /usr/src/src2pkg/src2pkg-helpers/src2pkg-helpers-1.0-i486-1.tgz created.

Done
Notice - The finished package: src2pkg-helpers-1.0-i486-1.tgz
is located in: /usr/src/src2pkg/src2pkg-helpers
- Installing Slackware-type tgz package -

+==============================================================================
| Installing new package ./src2pkg-helpers-1.0-i486-1.tgz
+==============================================================================

Verifying package src2pkg-helpers-1.0-i486-1.tgz.
Installing package src2pkg-helpers-1.0-i486-1.tgz:
PACKAGE DESCRIPTION:
# src2pkg-helpers Binaries and Libs used by src2pkg
#
# This package contains the libraries and binary programs used
# by src2pkg for building packages. This package is built and
# installed by src2pkg itself when it is run the first time or
# when run with the command 'src2pkg --setup'. These programs are
# compiled on your system to insure compatibility with your
# kernel and glibc versions and machine architecture. The sources
# for src2pkg-helpers are part of the src2pkg package itself.
#
# Packaged by src2pkg
Executing install script for src2pkg-helpers-1.0-i486-1.tgz.
Package src2pkg-helpers-1.0-i486-1.tgz installed.


Done src2pkg is now ready to use.
#

_________________
debian wheezy ,linux mint, slackware I use them all and they all have good points
Mint would be best for general users though
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2232

PostPosted: Tue 19 Jan 2010, 15:48    Post subject:  

The perfect build!
Back to top
View user's profile Send private message 
big_bass

Joined: 13 Aug 2007
Posts: 1747

PostPosted: Wed 20 Jan 2010, 12:53    Post subject:  

Hey Gilbert

Quote:
Any feedback would really be appreciated.


you asked for feedback this is a special thing
an advanced option

you already provided for using a config file /etc/src2pkg/src2pkg.conf

you can uncomment options you prefer from the list


well, for first time users that can be a
little uncomfortable until you get the hang of things

so one little line of code could be easily added to
help out and then this could be made into an extra options
menu hint, hint

well for starters it could activate lines of code like this example


Code:
sed '230i\
[[ $PKG_DEST_DIR ]] || PKG_DEST_DIR="$CWD"' /etc/src2pkg/src2pkg.conf>>/etc/src2pkg/src2pkg.conf.personal
 


so if you check line 230 the edit was made for you Very Happy

I know that the src2pkg.conf.personal option is not a valid option for now


but the idea is already there and a menu driven GUI would be easy to add with xdialog since I am working on a package manager
I thought about this would blend in nicely for src2pkg also

you can always PM me


Joe

_________________
debian wheezy ,linux mint, slackware I use them all and they all have good points
Mint would be best for general users though
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2232

PostPosted: Wed 20 Jan 2010, 13:53    Post subject:  

In the conf file, I do mention that I personally set everythig to build in the current directory -but the conf file has grown so big that one needs to be 'in the mood' to read it through.

I did, not long ago, add a command-line option '-CWD' which does the same thing as uncommenting those 4-5 lines (vis-a-vis working driectories).

You can use a personal conf file, although if you are the only one using src2pkg on your system it doesn't make anymore sense to setup up a personal conf file, than to simply use the main one in /etc/src2pkg/src2pkg.conf -the main one does not get overwritten if you upgrade src2pkg.

I'd be interested in what you come up with as a GUI -especially if it uses dialog/Xdialog -that way it could be use from CLI or from X. Every now and then, a user asks about a GUI for src2pkg, but I simply can't get a picture in my mind of how it should look and work. I've done so much to streamline the command-line use that it seems to me that a GUI would just get in the way. Most users (as far as I can tell), only use 3-4 options to src2pkg. But, as I said, i would be interestes to see what you come up with -even just ideas...

If you want to use a personal conf file, just create it as:
$HOME/.src2pkg.conf
src2pkg even provides a way fopr administrators to 'lock out' users from using a personal conf file, or to override any settings that the admin considers dangerous.

What is even 'kewler' is that src2pkg allows you to create 'extensions' which add functionality at any one of or all of *32* different spots in the code. To be precise, you can create an extension which runs before and/or after each one of the 16 main package-creation steps.

extensions should be placed in the directory '$HOME/.src2pkg/extensions' which you have to create. For instance, if you want to add coe which does something just after the 'fake_install' instruction is run, you simply create a file named $HOME/.src2pkg/extensions/08.post and add the code in there. (fake_install is the eighth step). to run code just before the 6th step, you'd put in a file named:$HOME/.src2pkg/extensions/06.pre

Any code you put in an extension gets priority -that is if it is supposed to run before the name step, then it really gets run first. And if it is a 'post' extension, then it runs after all the rest of the code in the step.

Once again, an administrator can lock one or all users out from using extensions.

I think we need to get our heads together on the package manager -I have already done extensive work on pkgtools to make the database *much* more capable for tracking dependencies and keeping package meta-data, md5sums, etc. I've evn done some work on 'spkg' which is a clone of pktools written in C. It can install and remove packages *much* faster than the script-based tools -up to 30 times faster removing packages.
Of course, whatever you have in mind for a LiveCD distro will bring in some other factors, but I think you'd do well to incorporate your ideas into what I am working on. My database even makes it possible to create a compile-order list. Also, it uses the files which make it compatible with slap-get/gslapt and slackpkg. Of course, all the database files are generated by src2pkg (with a single switch: '-E').
I have also built-in the ability to use pre-install, pre-remove and post-remove scripts (in addition to pkgtools' post-install (doinst.sh))

I really am getting quite close to having a full enough environment for you to start using to create your extra packages -I actually already have enough packages, but need to get them wrapped into an installation CD.
Back to top
View user's profile Send private message 
big_bass

Joined: 13 Aug 2007
Posts: 1747

PostPosted: Thu 21 Jan 2010, 13:54    Post subject:  

Hey Gilbert



Quote:
In the conf file, I do mention that I personally set everything to build in the current directory -but the conf file has grown so big that one needs to be 'in the mood' to read it through.


well I printed out the 8 pages of options
so I could dig in deeper to build the GUI

I can already visualize it
and started on it


*BTW I did see afterwards where you allowed for the "CWD"
to be used in lines 207-211 but the sed command allows for a quick fix to get started






and you left a lot of liberty to build for many special uses
which is good

what needs to be set down now is a "format"
so that all the work that is done wont have to be rebuilt
the painful way

this is easy though and the GUI will "guide" the the packagers on the road so if they stray its because they didn't follow the format

so for an example if you send me your personal
/etc/src2pkg/src2pkg.conf

that must be used for your packages to be built
without extra command line options being used


maybe you run a lot at the command line
changing options when needed
the GUI makes that easier to communicate that into options
that can be clicked on Smile
sort of like once you know how to compile the kernel you can do it manually but the menu is sure a big help and not really something
"extra" when you need it



I can process the GUI to default those values you prefer to be set for the GUI as checked
and the special options unchecked that dont compromise the package
format needed by the package management

some examples



so you get the visual




Joe
src2pkg-gui.png
 Description   
 Filesize   33.83 KB
 Viewed   1223 Time(s)

src2pkg-gui.png


_________________
debian wheezy ,linux mint, slackware I use them all and they all have good points
Mint would be best for general users though
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2232

PostPosted: Fri 22 Jan 2010, 16:28    Post subject:  

Actually, what you have going there looks like a good way to offer a GUI tool to setup the conf file. here's what mine looks like:
Code:
PACKAGER="my name and email address"
SIGNATURE="Packaged by $PACKAGER"
[[ $ADD_SRC2PKG_SCRIPT ]] || ADD_SRC2PKG_SCRIPT="YES"
[[ $COMPRESSION_SIZE_LIMIT ]] || COMPRESSION_SIZE_LIMIT=50

[[ $SOURCES_DIR ]] || SOURCES_DIR="$CWD"
[[ $SRC_BUILDS_DIR ]] || SRC_BUILDS_DIR="$CWD"
[[ $PKG_BUILDS_DIR ]] || PKG_BUILDS_DIR="$CWD"
[[ $PKG_DEST_DIR ]] || PKG_DEST_DIR="$CWD"
[[ $BACKUP_DIR ]] || BACKUP_DIR="$CWD"

[[ $EXTRA_FLAGS ]] || EXTRA_FLAGS="-pipe -fomit-frame-pointer"
[[ $EXTRA_LDFLAGS ]] || EXTRA_LDFLAGS="--relax,--sort-common,--no-keep-memory"
AUTO_CONFIG_OPTIONS="sysconfdir localstatedir"
[[ $AUTO_DESKTOP ]] || AUTO_DESKTOP=YES
AUDIO_NOTIFICATION=SAY


Very minimal as you can see.

I usually start the building of a new source by dragging the tarbal onto the src2pkg-dnd icon on the destktop. This is setup to run src2pkg -N -Q to write a new script, prompting you to correct, if needed, the NAME and VERSION for the package. I usually try to download a source rpm or the debian patch for the sources, if available. Doing so means that src2pkg will write a much better slack-desc file when the package is built.

I then start the build by running:
src2pkg -X -E -A
While that gets started, I look around in the sources -having a look at the README, or any other files which might gives hints about any opzions to configure that I might need. If you have used an rpm or the debian patch, you can use the option '-ACF' to try and automatically add configure options taken from the debian/rules or NAME.spec file. Otherwise, I let the build run until it finishes or fails. (Using the -VV option is good on the first run to see the full output of the configure, make, make install steps.
if the build fails, then I do whatever is indicated by the failure -add some configure options or download and package any dependencies. To add extra options to configure, I then rename the NAME.src2pkg.auto file to simply NAME.src2pkg and then open it in my favorite editor, uncomment the line:
# EXTRA_CONFIGS=""
and add any extra config options there. You should not put the --prefix= option in EXTRA_CONFIGS, and you don't have to woryy about mandir or infodir either. libdir will be added automatically for you, depending on whether your are running a 64bit system. Only really individual options (to the package) need to be set in EXTRA_CONFIGS
I then save the file and re-run:
src2pkg -X -E -A

Once the build succeeds, you will have a pretty good slack-desc file if you used an rpm or had the debian patch(there are other ways that src2pkg can get text for the desc file in some cases). If it needs any fine-tuning I do that and then save it. The -A option causes src2pkg to generate a slack-desc which is included in the package and a *copy* is created in the current directory named new.slack-desc. If you modify this new.slack-desc file, you should then rename it to simply 'slack-desc'. That means that it will be used in the next build without gernerating a new one.

I usually then re-run the whole build with:
src2pkg -X -E
unless it is something which takes a long time to compile. In that case, I might do this:
src2pkg -X -E --resume=fake_install (or resume_configure_source)

You can add the -W option if you are confident that the package will then be right. For small package that compile pretty quickly, I usually run the build several times, from the beginning to be sure that the build goes smotthly all the way through. If any other options need to be changed, or special code needs to be added to the NAME.src2pkg script (like to add or remove extra files) I go along adding that code till everything is just as wanted.

A final build can be done with options like:
src2pkg -X -E -Z2 --splitppkg=devel,i18n -W
-E is for extra databse files which make the package compatible with slapt-get. -Z2 means manpages will be bzipped and binaries will be compressed with upx/upx-ucl. splitpkg explaind itself and -W removes all temoprary build files when done.

If you want to build several packages of different formats, you can do so without rebuilding the sources:
src2pkg -X -TGZ
src2pkg -X -PET --resume=fake_install
src2pkg -X -PET2 --resume=fake_install
etc, etc.

For a GUI for setting up the conf file, I'd just make a list of the options by going through the conf file and picking out the ones that look like good candidates for your users.
Of course for Puppy, you'll want to use PKG_FORMAT=PET (or PET2 for the new-style package database). For Puppy, you may want/need to set FHS_POLICY=NONE if you plan to build packages that install to /usr/local or other non-standard package paths.
If you build packages which install things to /root, then you will need the option FAIL_ON_BAD_DIRS=NO
(To enforce better package standards, do not set these last two above)

I could write many, many pages, but let's go slowly...
Back to top
View user's profile Send private message 
big_bass

Joined: 13 Aug 2007
Posts: 1747

PostPosted: Mon 08 Feb 2010, 13:28    Post subject: GUI for conf  

Hey Gilbert

here's a GUI for the config its all Xdialog

hope you can adapt it into your src2pkg



I am done with puppy

but not with linux

I am always available to help
a friend though

Joe
GUI_src2pkg_conf2.tar.gz
Description 
gz

 Download 
Filename  GUI_src2pkg_conf2.tar.gz 
Filesize  3.12 KB 
Downloaded  447 Time(s) 
GUI.png
 Description   
 Filesize   41.02 KB
 Viewed   1131 Time(s)

GUI.png


_________________
debian wheezy ,linux mint, slackware I use them all and they all have good points
Mint would be best for general users though
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2232

PostPosted: Mon 08 Feb 2010, 15:03    Post subject:  

Yeah, I got your PM and have started looking at what you put together. There are some good ideas in there for how to put together something useful for non-geeky users to make things nicer. At least one slacker has asked about a GUI for src2pkg and I told him to feedback some ideas of how he thought it ought to look or what it should do, but nothing yet...

I'm about through with slackware, myself. Actually, I've only been using a small quantity of slack packages for years as my GUI is made up of a lot of stuff which doesn't come with slack. I'm still plugging away on KISS, but I don't always have a chance to do much on it. Still, I guess I'm just a few packages away from ahving an installable and extnedable system -but I still need to put together an installed intrd before creating any iso. Much of the delay is due to working on the package format, the adapted pkgtools and src2pkg features which drive/support that format. I've even done some work with spkg which is a pkgtools clone written in C -much, much faster -running that is, but also slower to hack LOL

Joe, have you managed to collect all the various sources needed for creating packages of all the puppy stuff you use? I have a whole lot of stuff here waiting for review (and rewrite since most of it is *so* sloppy). Some things should just be started over from scratch -for instance all the init scripts should just be chucked and re-done in a saner way which will run faster too. And the whole pup_save/sfs mess needs to be re-designed to work better. All the efforts to make puppy run on OLPC and other light hardware is a waste of time as the save-times and load-times for the large initrd mean that boot-times and shutdown-times are not optimal. I lnog ago came up with a better balance between boot-times and initial app startup times which works better and doesn't use up all the RAM these small machines have.
Back to top
View user's profile Send private message 
big_bass

Joined: 13 Aug 2007
Posts: 1747

PostPosted: Tue 09 Feb 2010, 12:29    Post subject:  

Hey Gilbert



I am waiting on divine intervention Very Happy

or I am not moving

Joe

_________________
debian wheezy ,linux mint, slackware I use them all and they all have good points
Mint would be best for general users though
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2232

PostPosted: Tue 09 Feb 2010, 13:26    Post subject:  

Sorry, I can't make heads or tails of that response... PM or email me if it's a secret.
Back to top
View user's profile Send private message 
big_bass

Joined: 13 Aug 2007
Posts: 1747

PostPosted: Wed 10 Feb 2010, 10:48    Post subject:  

Hey Gilbert

divine intervention is not explainable
well, not in simple scientific terms but here I go

I had a dream last night of a man trying to rescue a sunk ship
it was big and rusty it cost the man an incredible large sum of money
to lift the ship from the bottom of the deep ocean
(which was just a totally gutted out shell of a ship )
I saw this from a divers view
as if I was filming it as it was happening

In the dream I tried talking to this guy
showing him different things and asking him
what it was worth to see if he understood the value of things correctly
because I just couldn't understand why he spent so much money
on something he could have bought something new thousands
of times better and at small fraction of the cost
he paid for an old rusty shell
of a ship he recovered from the ocean

well, that was the divine intervention Very Happy



when you calculate time into the equation
time is a limited resource

I spent a few years solving puzzles that keeps changing
as far as a mental exercise goes it made me sharp
but I am not the sharpest knife in the drawer because
as far a productivity goes I am very busy but going nowhere Laughing

its quite liberating to remove preset limits
and get out of the box

I agree with you on packaging
this is how I think about it
the OS is not the goal it is a "result"
of well planed packages

if you need help testing anything send it my way
I will be glad try it out and offer feedback

Joe

_________________
debian wheezy ,linux mint, slackware I use them all and they all have good points
Mint would be best for general users though
Back to top
View user's profile Send private message 
aragon

Joined: 15 Oct 2007
Posts: 1698
Location: Germany

PostPosted: Wed 10 Feb 2010, 12:01    Post subject:  

you guys are terrific. not only that you do those clever things and you know why you're doing it in your way, it now gets a lyrical component ...

aragon

_________________
PUPPY SEARCH: http://wellminded.com/puppy/pupsearch.html
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2232

PostPosted: Wed 10 Feb 2010, 15:48    Post subject:  

Very interesting Joe, a perfect analogy for what you've been doing....
I also have been dragging up old rusty ships for a long time -if only to keep my mind sharp. Though I did learn early that it is sometimes better to simply have a good look at the rusty hulk without disturbing it and then re-create the good parts of it from a fresh start.

Say aragon, since you are just around the corner from me, perhaps you'd like to get together over coffee some weekend? I'd give a pretty Penny to make such a date with Joe -though I'd rather be around the corner from him instead of the other way around... AYYYY! Jalisco!
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 3 [31 Posts]   Goto page: 1, 2, 3 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Cutting edge
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.1220s ][ Queries: 12 (0.0039s) ][ GZIP on ]