Slaxer_Pup 4.12 solid and stable non woof build

Under development: PCMCIA, wireless, etc.
Message
Author
User avatar
Aitch
Posts: 6518
Joined: Wed 04 Apr 2007, 15:57
Location: Chatham, Kent, UK

#421 Post by Aitch »

Aw shucks, Joe
I just had my first fail to load.....
My new toy, an Edubook, [1Ghz 586 compatible/512Mb ram] won't load Slaxer_Pup
Gets so far, then can't find the Pupfiles on the external usb DVDR
I think it's because the usb drivers don't load early enough
ttuuxxx's 214X is the same, though TurboPup, Pupeee4.2, and 4.3 with 2.6.30.5 kernel all load successfully, though the video driver seems twitchy at 1280x600@60hz, - D1010 VGA and the network isn't recognised - RDC PCI5.sys in windoze
It does have an RT73 wifi card in, but my wireless is blocked, as I have broadband

Any thoughts?

Aitch :)

User avatar
pakt
Posts: 1157
Joined: Sat 04 Jun 2005, 16:54
Location: Sweden

#422 Post by pakt »

Aitch wrote:Aw shucks, Joe
I just had my first fail to load.....
My new toy, an Edubook, [1Ghz 586 compatible/512Mb ram] won't load Slaxer_Pup
Gets so far, then can't find the Pupfiles on the external usb DVDR
I think it's because the usb drivers don't load early enough
Aitch, I succeeded getting SlaxerPup to boot on my Edubook using a USB stick, but video wasn't right and wireless didn't work (didn't try LAN).

I tried this some time ago, but iirc, I think the vesa driver loaded automatically giving me some kind of display.
Methinks Raspberry Pi were ideal for runnin' Puppy Linux

User avatar
pakt
Posts: 1157
Joined: Sat 04 Jun 2005, 16:54
Location: Sweden

Edubook drivers for SlaxerPup

#423 Post by pakt »

That brings me to a request.

I wonder if Joe could take up the challenge to compile the video and wireless drivers for the Edubook. These are the only drivers I've found:

http://www.deviceonchip.com/index.php?o ... &id=13:vga
http://www.deviceonchip.com/index.php?o ... 4:wireless

I can't remember how to get sound or the LAN working. I think sound was some kind of patch and LAN was supported in the newer kernels.
Methinks Raspberry Pi were ideal for runnin' Puppy Linux

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#424 Post by big_bass »

Hey Paul (pakt)

I will be able to take a look at that in a few days

thanks for posting links for the sources

hope all is well with you

-----------------------------------------------------
I am finished with a Xdialog version of the slackware package tools
but testing still

I had to do a complete re write of some sections more then I originally planned to do
because of differences in dialog and xdialog
this was tricky to allow both
a xdialog and the original console package
tools to work together without conflicts

so best of both worlds in or out of X

I also added in some bonus things its looking good
trying to make the change over to using package tools
better in the X environment

heres a sneak peek at it
Joe
Attachments
xdialog package tools.png
(22.24 KiB) Downloaded 1162 times
x view.png
(30.92 KiB) Downloaded 1169 times

User avatar
Aitch
Posts: 6518
Joined: Wed 04 Apr 2007, 15:57
Location: Chatham, Kent, UK

#425 Post by Aitch »

Hi Paul, thanks

Joe

I just got sent a link to the manufacturer's site, which gives much more detail, by Jonathan, who I bought the Edubook from, and includes this quote,
I believe somebody has made an Edubook friendly Puppy distro too. There is a Debian/Ubuntu Install PDF on the DM&P site which outlines how to get most things going. Give it a whirl it helped me.
http://www.dmp.com.tw/tech/vortex86dx/#os

I found this, but so far, it doesn't work - see Barry's posts

http://www.murga-linux.com/puppy/viewtopic.php?p=390875

HTH

Aitch :)

User avatar
pakt
Posts: 1157
Joined: Sat 04 Jun 2005, 16:54
Location: Sweden

#426 Post by pakt »

big_bass wrote:I will be able to take a look at that in a few days

thanks for posting links for the sources
Hi Joe,

No hurry with compilng the sources.

Adding a user interface (GUI) is IMO one of the hardest things to program so I understand the work you're doing.

Thanks for the sneak peek of the GUI 8)

I hope you don't mind a couple of comments on the wording though.

I find these two lines somewhat ambiguous:
Install packages from the current directory
If there is more than one package in the directory, will *all* be installed or will a choice be given?
Remove packages that are currently installed
Sounds like *all* packages will be either removed or uninstalled


May I suggest instead (depending on what you mean):
Add: Install all packages from the current directory
or
Add: Install one or more packages from the current directory
Remove: Remove all packages that are currently installed
or
Remove: Remove one or more packages that are currently installed
Paul
Methinks Raspberry Pi were ideal for runnin' Puppy Linux

amigo
Posts: 2629
Joined: Mon 02 Apr 2007, 06:52

#427 Post by amigo »

That's the wording from the original pkgtool. Both simply lead to another window which lists all the packages in the CWD or all those installed and lety you choose which packages to operate on.

User avatar
pakt
Posts: 1157
Joined: Sat 04 Jun 2005, 16:54
Location: Sweden

#428 Post by pakt »

Hi amigo,

Does the menu have to follow the original wording? There's no way that the user can tell there are one or more windows that follow.

Might be a good opportunity here to correct the ambiguities :wink:

Paul
Methinks Raspberry Pi were ideal for runnin' Puppy Linux

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#429 Post by big_bass »

Hey Paul (pakt)

Thanks for the suggestions

those are /were the official messages of pgktools
but I agree if they could be made clearer lets do it :D

I had to edit installpkg also to display xdialog
that shows more info of what is happening
I attached a screen shot


and I added in the menu your edited messages
heres a screen shot

if you poke inside of pkgtools you will see that it is
a complex multi function script a lot of checks are made to the packages

xdialog by default design is for static menus
but I figured out a work around to generate dynamic menus :D

for the remove packages and the view packages
the dialog version uses the up and down arrows and the spacebar
to control the selections

using Xdialog you have the mouse and slide bar instead
to control your selections which is more user friendly
when your not in the console


Joe
Attachments
x menu.png
(21.56 KiB) Downloaded 1166 times
install box.png
(32.39 KiB) Downloaded 1119 times

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#430 Post by big_bass »

pkgtoolsx
UPDATED 2-20-2010

moved to current page


ok here it is

Xdialog version of packagetools (pkgtools)

so now its an X environment tool !

you should have the my pkgtools-13.0-patched-10-i486-slxr.pet
already installed its safe to have both since no files get over written

one for console one for X

Tip:if you have your packages in another directory copy the
pkgtoolx script into that folder and run it from there the
default is root

fixed slack-desc typo
added in a bug fix update from the official package
changed $TMP and ADM_DIR back to the defaults
I hard linked them while writing the script
to track down problems with echoing vars

Joe
Last edited by big_bass on Tue 23 Feb 2010, 17:00, edited 6 times in total.

amigo
Posts: 2629
Joined: Mon 02 Apr 2007, 06:52

#431 Post by amigo »

Joe, are they both against the slackware-13.0 version of pkgtools?

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#432 Post by big_bass »

Hey Gilbert (amigo)

yeah so if you diff them out you'll see the changes

only a small edit on the bottom of the script comment out
the fixmenus and the jwm restart you could remove
before testing on a "slackware" base besides that it should be fine

for the official tools pkgtools and installpkg were changed
the other scripts weren't modified
some new scripts get auto built in /var/log/setup/tmp

/var/log/setup/tmp/xremove_package_viewer
/var/log/setup/tmp/view_all_tgz
/var/log/setup/tmp/viewsrc2
/var/log/setup/tmp/xpackage_viewer
/var/log/setup/tmp/new_installer_list
/var/log/setup/tmp/list_of_installed_packages2
/var/log/setup/tmp/reply2




also I will only use tgz or txz
Joe

User avatar
Aitch
Posts: 6518
Joined: Wed 04 Apr 2007, 15:57
Location: Chatham, Kent, UK

#433 Post by Aitch »

Nice, Joe, thanks :D

Aitch :)

amigo
Posts: 2629
Joined: Mon 02 Apr 2007, 06:52

#434 Post by amigo »

I looked at those last night for a while. I noticed a couple of things you might want/need to change. This:

Code: Select all

diff -pruN pkgtools/sbin/installpkg joes-pkgtools/sbin/installpkg
--- pkgtools/sbin/installpkg	2009-08-16 23:22:10.000000000 +0200
+++ joes-pkgtools/sbin/installpkg	2009-07-19 03:09:35.000000000 +0200
@@ -283,7 +283,7 @@ if [ "$MODE" = "warn" ]; then
     fi
     echo "The following files will be overwritten when installing this package."
     echo "Be sure they aren't important before you install this package:"
-    ( $packagecompression -dc | $TAR tvvf - ) < $1 | grep -v 'drwx'
+    ( $TAR tzvvf - ) < $1 | grep -v 'drwx'
     echo
     shift 1
   done
breaks the use of 'txz' packages (the 'z' means use gzip) You could probably use 'a' for autodetection, but that would assume the user has a certain verion of tar.
Also, I notice that in both packages you have 'slack.desc' files. They should be named 'slack-desc' to be properly used by installpkg. It will succeed in removing them when the package has installed since it uses:
rm -f install/slack*
but for the descriptive text to be included in the database entry under /var/log/packages, it needs to be named 'slack-desc'.

I'm still reviewing pkgtoolx -lots of changes there to what is already messy code. I wonder, why did you change all the $TMP references to hard-coded paths? If you ever plan on having a slack-type installer CD, you'll need all those relative paths working, because the tools will be working on a mounted partition, so that ADM_DIR becomes:
/var/log/setup/tmp/var/log/packages or some such dir. That's why the code has those vars. It also makes it possible to use the tools from a running system to work on a system which you have mounted.

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#435 Post by big_bass »

Hey Gilbert (amigo)

fixed slack-desc typo
added in a bug fix update from the official package
changed $TMP and ADM_DIR back to the defaults
I hard linked them while writing the script
to track down problems with echoing vars


because of the mishap with $TMP
is usually /tmp
and not /var/log/setup/tmp
as package tools uses

this will be a lot easier to read
but not clean just yet :)

thanks for the xz update
I must of had an earlier version without the bug fix
I didn't change that line of code

I know its a bit messy because of the parts I had to generate
the dynamic menus with xdialog using an echo which makes it
messy to read maybe after you'll find a better solution to doing that part keep me posted open to suggestions

this is still very alpha but it is working as expected
thanks for pointing out some of the errors

I updated the package again
pkgtoolsx-13.0-noarch-5.tgz
Joe
Last edited by big_bass on Sun 21 Feb 2010, 00:40, edited 2 times in total.

amigo
Posts: 2629
Joined: Mon 02 Apr 2007, 06:52

#436 Post by amigo »

Actually, the 'neatest' patches are to be had by separating the changes between bug-fix, feature, formatting and hacks -or other such 'categories'. It just means making a couple of extra inetrmediate diffs as you add in all your changes, but it keeps the code separate -especially for features/hacks. You'll be glad you did the netx time you go to apply the changes against a new version of the original tools, or whatever.
Personally, I'd just leave the functioning code for the tbz/tlz packages as it will make your patches shorter and neater. Or just comment it and leave it -when you change the number of lines drastically the diffs are harder interpret visually with xdiff or other such viewer.

I agree with the commenting/removal of the code which doesn't allow to use makepkg in the current directory -that's new lately in slack pkgtools.

I appreciate you posting your work -I was able to get an overview of what you had changed pretty easily. Oh, BTW, you have a routine there which creates a script in /var/log/setup -there's a line (~326) in /etc/rc.d/rc.S which wipes that out on every boot. Probably best to create that first when your tool runs and then remove it when finished.

I'm looking at how to integrate some of that into my pkgtools version. I'm also working making all my init routines use dash to speed boot-times. I'm using a statically-linked /bin/dash called specifically by the main rc.* files. /bin/sh is still linked to bash to avoid problems with any scripts we don't have control of.

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#437 Post by big_bass »

Hey Gilbert (amigo)


thanks for the tips !
-----------------------

here's a small script to help out with those lazy people who like drag N drop package installs :D

if you don't care to see the progress remove the -hold
from the xterm command
*you'll have to manually close the box

Code: Select all

#!/bin/sh

#code by Joe arose  big_bass  
#this is a very fast drag n drop tool
#for installing tgz packages
#it coupled with rox to get the right click 
#in the menu
#call this script install_tgz

#.tgz	  
if echo `basename "$1"` | grep -q '.tgz$'; then
   
   
Xdialog --wrap --title "YES/NO BOX" \
        --yesno "Do you want to install $1" 0 0

case $? in
  0)
    echo "Yes chosen.";;
  1)
    echo "No chosen."
    exit;;
  255)
    echo "Box closed."
    exit;;

esac
             

xterm -hold -geometry 40x30+150+40 -e installpkg "$1"         

Xdialog --title "Complete" \
        	--infobox "\nInstalling $1 has finished.\n" 0 0 3000


#get the menus updated 
/usr/sbin/fixmenus #hack for JWM and ICEWM  
jwm -restart       #hack for JWM and ICEWM  Joe Arose aka big_bass 


else
 Xdialog --title "not a tgz " \
        	--infobox "\ntgz only.\n" 0 0 4000


fi


big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#438 Post by big_bass »

Hey Gilbert (amigo)
Actually, the 'neatest' patches are to be had by separating the changes between bug-fix, feature, formatting and hacks -or other such 'categories'. It just means making a couple of extra inetrmediate diffs as you add in all your changes, but it keeps the code separate -especially for features/hacks. You'll be glad you did the netx time you go to apply the changes against a new version of the original tools, or whatever.
well ,I agree and offer the neatest solution
I wish I had something like this when I started trying to figure out
pkgtools !

I made these as all in one scripts that can be run stand alone
the code is cleaner and works and shows what is happening
with a few more comments so I don't forget either
I found another way the EOF is cleaner than the echoing


these scripts are just for demonstrating the code in parts
if you installed my packagetoolsx they are already included

Code: Select all


#!/bin/sh

# this allows you to run the official package tools without editing 
# any files used by it so its safe to use this New GUI at any time
# The new files will be made and used 
# by Joe Arose 2-17-2010

# list_of_installed_packages2   located in /var/log/setup/tmp
# xpackage_viewer               located in /var/log/setup/tmp
# viewsrc2                      located in /var/log/setup/tmp

# list_of_installed_packages2   needs a new list generated for xdialog to work 
# xpackage_viewer               is the main viewer for the all package list view   
# viewsrc2                      this shows the individual selected package

# xpackage_viewer               is auto generated from this script
# viewsrc2                      is auto generated from this script  

# this replaces the dialog version for xdialog            
# a problem was dialog uses a --file option that is done differently with xdialog
# so  adjustments to the formating of how the PACKAGE DESCRIPTION:
# was parsed generates a valid xdialog list now
# then a new script replaced viewsrc with xpackage_view + viewsrc2
# I split it into subroutines 



#  there are 4 parts needed 
#  part 1 is generate list_of_installed_packages2 
#  part 2 is the xpackage_viewer
#  part 3 is run by viewsrc2 automatically
#  part 4  is reading the package selected reply2
#          and piping that into Xdialog 




#----------------------------------------
# generate list_of_installed_packages2 
#----------------------------------------

    	FILES=$(ls /var/log/packages)
        cd /var/log/packages
      { grep '^PACKAGE DESCRIPTION:$' -Z -H -m1 -A1 $FILES; echo; } \
      | sed -n 'h;n;/\x00/{h;n;};x;s/  */ /g;s/ $//;s/[\"`$]/\\&/g
       s/\(.*\)\x00\([^:]*:\)\? *\(.*\)/ "\1"    "" OFF \\/;p' > /var/log/setup/tmp/list_of_installed_packages2 
touch  /var/log/setup/tmp/list_of_installed_packages2 
     


#----------------------------------------
# generate viewsrc2
#----------------------------------------

cat << 'EOF' >/var/log/setup/tmp/viewsrc2
#!/bin/sh

#make the package selected to view a string value called RETURN2
RETURN2=`cat /var/log/setup/tmp/return2`

#then pipe that into xdialog 

echo "`cat /var/log/packages/$RETURN2`" | Xdialog --title " $RETURN2    files " \--backtitle " $RETURN2   list   "     \--textbox "-" 30 70 0
EOF

chmod a+x /var/log/setup/tmp/viewsrc2




#----------------------------------------
# generate /var/log/setup/tmp/xpackage_viewer
#----------------------------------------
# this makes a script using echo 
# with the new formated PACKAGE DESCRIPTION:

# make the xdialog head 

cat << 'EOF' >/var/log/setup/tmp/xpackage_viewer
#!/bin/sh
Xdialog --title " Package you wish to view more info"\
--backtitle "Installed packages info  "     \
--radiolist "Select a package you want to view       \
                                             \n"  35 50 2  \
EOF
                                             
# build the list of installed packages                                     
# this the body of the script 

echo "`cat /var/log/setup/tmp/list_of_installed_packages2`">>/var/log/setup/tmp/xpackage_viewer 

# the chosen value is used to view just that file from the main list 

cat << 'EOF' >>/var/log/setup/tmp/xpackage_viewer
2> /var/log/setup/tmp/return2 


case $? in
  0)
    echo "Yes chosen.";;
  1)
    echo "No chosen."
    exit;;
  255)
    echo "Box closed."
    exit;;

esac 

/var/log/setup/tmp/viewsrc2
EOF


# make it executable
chmod a+x /var/log/setup/tmp/xpackage_viewer 

#----------------------------------------
# run the new "viewscr2" 
# automatically from /var/log/setup/tmp/xpackage_viewer
#----------------------------------------
 
/var/log/setup/tmp/xpackage_viewer

Code: Select all


#!/bin/sh

# this allows you to run the official package tools without editing 
# any files used by it so its safe to use this New GUI at any time
# by Joe Arose 2-17-2010


#----------------------------------------
# generate /var/log/setup/tmp/new_installer_list
#----------------------------------------

cd /
find / -name '*.tgz' -exec echo  {} \; >/var/log/setup/tmp/new_installer_list

# filter out initrd
cat var/log/setup/tmp/new_installer_list|grep -v 'initrd' >/var/log/setup/tmp/new_installer_list
     
touch  /var/log/setup/tmp/new_installer_list
      


#----------------------------------------
# generate /var/log/setup/tmp/view_all_tgz
#----------------------------------------

cat << 'EOF' >/var/log/setup/tmp/view_all_tgz
#!/bin/sh

# then stick that in your Xdialog pipe and smoke it  :D

echo "`cat /var/log/setup/tmp/new_installer_list`" | Xdialog --title "    TGZ finder " \--backtitle " All  TGZ  list   "     \--textbox "-" 30 70 0
EOF

chmod a+x /var/log/setup/tmp/view_all_tgz

. /var/log/setup/tmp/view_all_tgz





amigo
Posts: 2629
Joined: Mon 02 Apr 2007, 06:52

#439 Post by amigo »

Well, that does look a lot cleaner! I was working yesterday on ramming some of your GUI code into the regular pkgtool, in a way that the same script could be used with or without Xdialog.

pkgtool would be lots easier to work with if the code was broken up more into functions. And the shallow indenting makes it hard to read... My hacked version is formatted better, but I haven't yet broken out much code into functions. I have added lots of code for handling the extra database files, but it is mostly in one spot so it isn't too hard to work with/around. I forked my version quite some time ago -before the official tools supported tbz/tlz/txz so I handled that a little differently than they did. Once forked, the best way to check/keep up with any fixes or features from upstream is to simply make diffs against the original versions. As I said before, I'm against some of the changes, so I have no desire to take new versions and re-convert them.

You mentioned drag-n-drop package handling... I have for a long time used a rox AppDir front-end to pkgtools which is great for quickly installing or upgrading packages just by dropping them on the icon. Plus, right-clicking brings up a menu with some functions for quickly listing all installed packages, searching for a file to find out what package installed it, listing the contents of package nicely and for searching in a MANIFEST to see what package supplies a certain uninstalled file.

You can get an older version here:
http://distro.ibiblio.org/pub/linux/dis ... ls-0.2.tbz
It uses a variety of GUI (gtk-1.2) helpers which you'll want to install to see how it works. But, you might want to replace those routines with pure Xdialog or gtkdialog code.
Xdialog -I know you have this :-) Did you know there's a GTK2 version?

greq
gtk-shell
gselect:
http://distro.ibiblio.org/pub/linux/dis ... MsgDialog/

afxmsg:
http://distro.ibiblio.org/pub/linux/dis ... ts/afxmsg/

gmas:
http://distro.ibiblio.org/pub/linux/dis ... mas-1.1.0/

It could probably have all been done with just Xdialog, but i was experimenting and some of the widget tools are more attractive and easier to use than even Xdialog
You are definitely on the right track if these can be used as simple frontends to the regular tools.

Say, I've been working on init/boot functionality for my new system and have gotten down to a 6 second bootime(from grub selection to CLI login)! I'm using a statically-linked dash for running the init scripts which brought times down from ~15 seconds to 6-7. Still room to cut a couple more seconds out there...

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#440 Post by big_bass »

pkgtoolsx
UPDATED 2-23-2010

*mostly cleaning up the code so its easier to diff and read
added back tbz tlz support
http://puppy2.org/slaxer/pkgtoolsx-13.0-noarch-9.tgz



Xdialog version of packagetools (pkgtools)

so now its an X environment tool !

you should have the my pkgtools-13.0-patched-10-i486-slxr.pet
already installed its safe to have both since no files get over written

one for console one for X

Tip:if you have your packages in another directory copy the
pkgtoolx script into that folder and run it from there the
default is root

note when asked to install packages select yes ,no ,or quit

Joe

Post Reply