The time now is Mon 20 May 2013, 00:58
All times are UTC - 4 |
| Author |
Message |
AkhIL
Joined: 02 Mar 2008 Posts: 3
|
Posted: Sun 02 Mar 2008, 20:43 Post subject:
petget replacement |
|
ok. About my expireince of using peteget.
Deinstalation of Python-2.5.1 takes 10 minutes
Some times petget writes garbage in / directory
When petget process multiple package it does one job multiple times
I have to push OK button after every installed package. Try to install 100 package
I already have patch which makes deinstallation 10 times faster. But it is work around. So I suggest to do not remove directories form packagename.files and then just sort with -r this list and do rmdir if dir or remove file if file.
rmdir can't delete not empty directory so you do not need to check is it empty (eack ls -1 takes 0.2 seconds)
I can help you in developing new petget but first you have to make petget code less linear and split petget to separate gui and functional part.
Fuctional part should be fast and work without human interaction.
I already did some stuffs like:
dirsplit - part of new2dir script which split dir to EXE,DOC,DEV and NLS
mkpet - makes pet file form direcotry without questions
src2pet - compiles source and makes pet file. Can install packages from pet or compile from source, make pet and then install it.
metmerge - portage like package manager which uses all scripts above
Once again I NEED TOOL TO INSTALL\DEINSTALL PET FROM COMMAND LINE
|
|
Back to top
|
|
 |
MU

Joined: 24 Aug 2005 Posts: 13642 Location: Karlsruhe, Germany
|
Posted: Sun 02 Mar 2008, 20:48 Post subject:
|
|
you need pkgtool:
http://murga-linux.com/puppy/viewtopic.php?t=15285
Mark
_________________ my recommended links
|
|
Back to top
|
|
 |
wow
Joined: 29 Jun 2006 Posts: 950
|
Posted: Sun 02 Mar 2008, 21:05 Post subject:
|
|
Nathan F wrote another package manager for Puppy/Grafpup which install and uninstall .tar.gz packages. I haven't used it lately but you can learn some tricks from it.
pkgtool-0.4 CLI package manager
http://www.murga-linux.com/puppy/viewtopic.php?t=15285
_________________

|
|
Back to top
|
|
 |
Lobster
Official Crustacean

Joined: 04 May 2005 Posts: 15109 Location: Paradox Realm
|
Posted: Sun 02 Mar 2008, 21:36 Post subject:
|
|
| Quote: | | I already have patch which makes deinstallation 10 times faster. But it is work around. |
Welcome to the kennels
The package installer is being worked on right now by Barry (as far as I know)
Please let us see your patch code
_________________ Puppy WIKI
Last edited by Lobster on Mon 03 Mar 2008, 10:46; edited 1 time in total
|
|
Back to top
|
|
 |
plinej
Joined: 13 Aug 2006 Posts: 1517
|
Posted: Sun 02 Mar 2008, 23:31 Post subject:
|
|
I just hacked pkgtool to accept installation of dotpets. It will only do one at a time so you'd have to use a simple script to install multiple files. Something like:
| Code: |
#!/bin/bash
ls *.pet | while read FILE
do
pkgtool -install "$FILE"
done
|
That would install all the dotpets in the current directory. Here's the hacked pkgtool script.
| Description |
|

Download |
| Filename |
pkgtool.tar.gz |
| Filesize |
6.57 KB |
| Downloaded |
454 Time(s) |
|
|
Back to top
|
|
 |
BarryK
Puppy Master

Joined: 09 May 2005 Posts: 6855 Location: Perth, Western Australia
|
Posted: Mon 03 Mar 2008, 06:36 Post subject:
|
|
Well, it is a bit delayed. I plan to work on petget soon.
| Quote: | | Once again I NEED TOOL TO INSTALL\DEINSTALL PET FROM COMMAND LINE |
petget does install and uninstall from the commandline. See some docs at the start of the script.
_________________ http://bkhome.org/blog2/
|
|
Back to top
|
|
 |
AkhIL
Joined: 02 Mar 2008 Posts: 3
|
Posted: Mon 03 Mar 2008, 07:16 Post subject:
|
|
| BarryK wrote: | Well, it is a bit delayed. I plan to work on petget soon.
|
Any chence to push petmerge as main package managing tool?
I'll share sources in few days. I have to fix some non logical parts of code.
Petmerge can be used even to automaticaly build distro from unleashed.
| BarryK wrote: |
petget does install and uninstall from the commandline. See some docs at the start of the script. |
Yes. but I have to push ok button after each package
2plinej
Nice tool. But once again you are doing:
| Code: |
find ./$APKGNAME -mindepth 2 -mount -type f | sed -e "$APATTERN" | sed -e 's/\/root0\//\/root\//g' > ./$APKGNAME.files
find ./$APKGNAME -mindepth 2 -mount -type l | sed -e "$APATTERN" | sed -e 's/\/root0\//\/root\//g' >> ./$APKGNAME.files
|
but we can make deinstalation much faster by doing:
| Code: |
find ./$APKGNAME -mindepth 2 -mount | sed -e "$APATTERN" | sed -e 's/\/root0\//\/root\//g' > ./$APKGNAME.files
|
because of at uninstallation stage we will able to replace
| Code: |
for ONEFILE in `cat ./$APKGNAME.files`
do
#v2.14 if there is a .desktop file, then need to regenerate the menu...
[ ! "`echo -n "$ONEFILE" | grep '\.desktop$'`" = "" ] && FDESK="$ONEFILE"
#.files file may be malformed. check entry is a genuine file...
#v2.11 some symlinks may not get removed. '-e' will not work if symlink
#is pointing to a non-existent file. So, check for symlink...
REMFILE=""
[ -h $ONEFILE ] && REMFILE="yes"
[ -e $ONEFILE ] && REMFILE="yes"
if [ "$REMFILE" = "yes" ];then
if [ ! -d $ONEFILE ];then
#v2.0.0
if [ -e /initrd/pup_ro2$ONEFILE ];then
#the problem is, deleting the file on the top layer places a ".wh" whiteout file,
#that hides the original file. what we want is to remove the installed file, and
#restore the original pristine file...
cp -af /initrd/pup_ro2$ONEFILE $ONEFILE
else
rm -f $ONEFILE
fi
#v2.0.0 also, delete empty dirs...
DELDIR="`dirname $ONEFILE`"
[ "`ls -1 $DELDIR`" = "" ] && rmdir $DELDIR
fi
fi
done
#v2.11 go through again and remove any empty dirs...
#note, it is done above, but is incomplete. this should catch the rest...
for ONEFILE in `cat ./$APKGNAME.files`
do
DELDIR="`dirname $ONEFILE`"
[ -d $DELDIR ] && [ "`ls -1 $DELDIR`" = "" ] && rmdir $DELDIR
#check one level up... but do not delete top dir, like /opt...
DELLEVELS=`echo -n "$DELDIR" | sed -e 's/[^/]//g' | wc -c | sed -e 's/ //g'`
if [ $DELLEVELS -gt 2 ];then
DELDIR="`dirname $DELDIR`"
[ -d $DELDIR ] && [ "`ls -1 $DELDIR`" = "" ] && rmdir $DELDIR
fi
done
#if [ -f ./$APKGNAME.keyword ];then
# #code here to remove menu entries etc...
# #if it's a forced removal, due to same package existing in live-cd, don't want to
# #remove from menus...
# CPATTERN="\"${APKGNAME}\""
# if [ "`cat /tmp/forcepkgremove.txt | grep "$CPATTERN"`" = "" ];then
# AKEYWORD="`cat ./$APKGNAME.keyword`"
# #v1.0.5
# /usr/sbin/fixmenus /root \-$AKEYWORD
# fi
#fi
[ ! "$FDESK" = "" ] && /usr/sbin/fixmenus #v2.14
rm -f ./$APKGNAME.*
|
by
| Code: |
#v1.0.6 do not remove w.m. menu config files...
for ONEFILE in `cat ./$APKGNAME.files | grep -v "\\.icewm/menu" | grep -v "\\.jwmrc" | grep -v "\\.fvwm95rc" | sort -r `
do
#.files file may be malformed. check entry is a genuine file...
#v2.11 some symlinks may not get removed. '-e' will not work if symlink
#is pointing to a non-existent file. So, check for symlink...
REMFILE=""
if [ -d $ONEFILE ]
then
rmdir $ONEFILE 2> /dev/null # rmdir can't delete non empty dir!
elif [ -h $ONEFILE ] || [ -e $ONEFILE ]
then
#v2.0.0
if [ -e /initrd/pup_ro2$ONEFILE ];then
#the problem is, deleting the file on the top layer places a ".wh" whiteout file,
#that hides the original file. what we want is to remove the installed file, and
#restore the original pristine file...
cp -af /initrd/pup_ro2$ONEFILE $ONEFILE
else
rm -f $ONEFILE
fi
fi
done
if [ -f ./$APKGNAME.remove ];then
./$APKGNAME.remove
fi
#if [ -f ./$APKGNAME.keyword ];then
# #code here to remove menu entries etc...
# #if it's a forced removal, due to same package existing in live-cd, don't want to
# #remove from menus...
# CPATTERN="\"${APKGNAME}\""
# if [ "`cat /tmp/forcepkgremove.txt | grep "$CPATTERN"`" = "" ];then
# AKEYWORD="`cat ./$APKGNAME.keyword`"
# #v1.0.5
# /usr/sbin/fixmenus /root \-$AKEYWORD
# fi
#fi
#v2.14 if there is a .desktop file, then need to regenerate the menu...
grep -q '\.desktop' ./$APKGNAME.files && /usr/sbin/fixmenus #v2.14
rm -f ./$APKGNAME.*
|
which will work TEN times faster, (tested with time tool)
I hope together we will made great job.
I think petget should be splited. For example petget - is nice GUI which uses pkgtool to install and uninstall packages.
And one more thing. Why you are useing so much syncs?
|
|
Back to top
|
|
 |
AkhIL
Joined: 02 Mar 2008 Posts: 3
|
Posted: Fri 07 Mar 2008, 20:44 Post subject:
|
|
Ok. This is my petage. Still not works as well but compiles and installs gimp without problem.
How to build gimp:
First you have to get clean puppy301 and devx
Then check your internet connection. Petmerge will download sources for you.
Extract petage anywhere and do
now you have to fix broken paths in .la files which come form devx. I wrote python script which did it for you (attached). but you need python to run it. So lat's get it
| Code: | | petmerge --sources Python |
after merging run | Code: | | python dotla_relocator.py |
We are ready to get gimp:
| Code: | | petmerge --sources gimp |
now and lat's draw
you may look in distfiles dir. there is a lot of pet packages.
next time you can merge it without devx from this packages
| Description |
|

Download |
| Filename |
dotla_relocator.py.gz |
| Filesize |
714 Bytes |
| Downloaded |
439 Time(s) |
| Description |
|

Download |
| Filename |
petage.tar.bz2 |
| Filesize |
14.23 KB |
| Downloaded |
415 Time(s) |
|
|
Back to top
|
|
 |
|
|
|
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
|