Page 18 of 20

Posted: Sat 20 Apr 2013, 21:05
by PANZERKOPF
goingnuts wrote: I was wondering if we should create a list of all those gtk1 apps (or other useful old-timers)...
This is a good idea.
There are many old, discontinued but still useful opensource apps scattered in world web.
I Will inform You about each finding.

sfm small file manager

Posted: Sun 21 Apr 2013, 20:23
by Keef
I found this gtk 1.2 file manager:
http://prigaux.chez.com/sfm.html

Dependencies:

Code: Select all

linux-gate.so.1 => 
	libgtk-1.2.so.0 => /root/my-applications/lib/libgtk-1.2.so.0
	libgdk-1.2.so.0 => /root/my-applications/lib/libgdk-1.2.so.0
	libgmodule-1.2.so.0 => /root/my-applications/lib/libgmodule-1.2.so.0
	libglib-1.2.so.0 => /root/my-applications/lib/libglib-1.2.so.0
	libdl.so.2 => /lib/libdl.so.2
	libXi.so.6 => /usr/X11R7/lib/libXi.so.6
	libXext.so.6 => /usr/X11R7/lib/libXext.so.6
	libX11.so.6 => /usr/X11R7/lib/libX11.so.6
	libm.so.6 => /lib/libm.so.6
	libc.so.6 => /lib/libc.so.6
	/lib/ld-linux.so.2
	libXau.so.6 => /usr/X11R7/lib/libXau.so.6
	libXdmcp.so.6 => /usr/X11R7/lib/libXdmcp.so.6
From the README
This program is a simple file manager. It's meant to be small and fast and have a lot of shortcuts. You can associate actions with files (using its extension or its type given by file(1)). A popup menu gives you the available commands and shortcuts. You can have multiple views talking between each others. The filenames are colored using the LS_COLORS variable. You can also use it as a directory traveller. It uses the gtk+ library.

You have the ability to not use the mouse at all, using mnemonics and shortcuts. I really think something like kfm and xfm is too slow and not enough shortcut driven. This program is meant to minimize memory consumption and to be very fast.
This is running on 412. Got the gtk /glib stuff from rpms.
(I downloaded the binary. - It dates from 1999)

Posted: Sun 28 Apr 2013, 14:23
by goingnuts
Keef: Thats a nice finding!
Xpdf versions below 2 can be build without motif. The last version of those seems to be 1.01.
Edit 20130430: pdf supports an annoying feature that prevents copy text+images out of the document if owner password set. I can see the text content and manually type the text to another document or screen capture images and paste them as well. Applied a simple patch to bypass the check for owner password. So new upload here 1.4Mb and included all the non-GUI programs (pdffonts pdfimages pdfinfo pdftopbm pdftops pdftotext) as well as man pages etc. Would have liked to turn all the bins into a multicall binary but sort of lost when it comes to doing that with c++ code.
Still pdf files protected with user passwords needs the password set via command line so if you try opening a pdf-file via GUI and nothing happens it might be pswd-protected (xpdf gives no indications of this in GUI-mode).

Although this old version is targeted pdf-1.4 it seems to load newer versions as well.

Posted: Wed 15 May 2013, 01:30
by technosaurus
I've been playing with coldplugging and hotplugging via shell scripts here:
http://www.murga-linux.com/puppy/viewtopic.php?t=86125
I know this is the "old-fashioned" way but after looking at the old hotplug scripts, the concept was fine, but the implementation was not designed for speed.

I'm designing it for use with busybox built with prefer applets, standalone shell and run NOFORK applets directly (this typically more than doubles the speed even compared to itself without those features)

Posted: Wed 15 May 2013, 02:42
by Ted Dog
Cloud you include an underdog method? with pupngo13.

Posted: Wed 15 May 2013, 07:57
by PANZERKOPF
goingnuts wrote:Keef: Thats a nice finding!
Xpdf versions below 2 can be build without motif. The last version of those seems to be 1.01.
It seems Your image shows Motif-based XPDF...... :)
Correct image is attached here:

"Northern Captain" - two-panel filemanager

Posted: Wed 15 May 2013, 08:12
by PANZERKOPF
Two-panel filemanager, uses Xlibs only.
http://freecode.com/projects/XNorthernCaptain

Posted: Wed 15 May 2013, 15:06
by goingnuts
technosaurus: Looks great!
Ted Dog: I haven't looked at it - if it does not need to be in initrd I think I prefer to have it as an option/package to add...and the pupngo13 might be sort of delayed as there are no release scheduled :)
PANZERKOPF: Are you sure about the motif? I am getting old and eyes are getting weaker but after rechecking I do believe no motif/openmotif is involved in my xpdf-1.01 build and the image of it running...Could it be some of your X-app-defaults settings which influence the view? Well again - I might be old and wrong...at least today...
The XNC is very nice - attached an image of it running:

Posted: Wed 15 May 2013, 15:40
by PANZERKOPF
goingnuts wrote: Could it be some of your X-app-defaults settings which influence the view?
Yes, maybe my X settings are different... Sorry! :)

Posted: Thu 16 May 2013, 05:39
by Ibidem
Tested the xpdf with ubuntu...looks like goingnuts' screenshot, and like stock motif xpdf.
I'm guessing though that PANZERKOPFF has no .Xdefaults, or uses .Xresources but has none for xpdf or *?

t1lib, which xpdf bundles, has a history of security bugs--disabling will be safer and smaller, but uglier text.

Posted: Thu 16 May 2013, 14:44
by goingnuts
t1lib, which xpdf bundles, has a history of security bugs--disabling will be safer and smaller, but uglier text.
Do you know if applying debian security patches for t1lib removes the security threat (CVE-2010-2642.patch, CVE-2011-0764.diff, CVE-2011-1552_1553_1554.patch & format-security.diff)?
Without t1 its seems too ugly and I haven't found a way to get the freetype/freetype2 working (seems to ignore configure settings and never get included...).
Maybe its hard to find a pdf-file that actually triggers the security thread...I guess main target for hackers wont be xpdf-1.01...but would be nice to avoid the risk.

Changing of Xdefaults:
Try adding this to your /root/.Xresources:

Code: Select all

xpdf*foreground:        dark green
xpdf*background:        steelblue
xpdf*geometry:          80x25
and run:

Code: Select all

 xrdb -merge ~/.Xresources
and then launch xpdf...
I guess the "motif"-look is present when nothing is defined for xpdf.

Posted: Fri 17 May 2013, 05:00
by Ibidem
goingnuts wrote:
t1lib, which xpdf bundles, has a history of security bugs--disabling will be safer and smaller, but uglier text.
Do you know if applying debian security patches for t1lib removes the security threat (CVE-2010-2642.patch, CVE-2011-0764.diff, CVE-2011-1552_1553_1554.patch & format-security.diff)?
Without t1 its seems too ugly and I haven't found a way to get the freetype/freetype2 working (seems to ignore configure settings and never get included...).
Maybe its hard to find a pdf-file that actually triggers the security thread...I guess main target for hackers wont be xpdf-1.01...but would be nice to avoid the risk.
Are you using Debian's t1lib? If so, the patches should be enough.
Some xpdf versions bundled t1lib, though.

It looks like there's a little mucking around with configure and a (small?) patch to get freetype2 working. Mainly that the headers are different.

...
Of course, xpdf has had several vulnerabilities since 2002.

Posted: Thu 30 May 2013, 04:49
by starhawk
Sorry I haven't been doing much with The Infernal Dell as of late... I kinda lost interest for a while. However...

goingnuts, technosaurus, look at this...

http://murga-linux.com/puppy/viewtopic. ... 101#639101

Could this "minitube" program be made to work (or rebuilt/replicated in compatible fashion) with pUPnGO2012? That would be a lot of what the doctor ordered for the CPi -- Flash video playback without Flash video CPU overhead.

Posted: Sun 02 Jun 2013, 09:25
by goingnuts
Ibidem: Thanks for the info. I was not using the debian source but an external t1lib. I have tested the debian source as well and have no problems compiling.
starhawk: I don't think I can do the minitube as it is c+ and qt...
But maybe another solution can be found. There seems to exist various scripts that could be used with a gtk-dialog front end and mplayer - to construct a poor mans minitube. Might be done already...

Posted: Sun 02 Jun 2013, 16:11
by starhawk
@goingnuts -- go for it! Anything that can substitute for Flash Player (more or less) and work on the CPi meets my needs ;)

Posted: Sun 02 Jun 2013, 18:05
by sc0ttman
starhawk wrote:@goingnuts -- go for it! Anything that can substitute for Flash Player (more or less) and work on the CPi meets my needs ;)
VLC with no gui is only about 2.5mb, and can play youtube stuff, if it's compiled with lua support (lua doesnt need to be installed once its compiled as far as i can tell..) ... and old VLC, like 0.8.6, compiled with lua and without qt gui might be a solution too... (and there's vlc-gtk as a frontend for it too)...

Posted: Sun 02 Jun 2013, 18:28
by starhawk
Anyone know how that'll perform on a P2 300MHz with 128mb RAM and 384mb swap?

Posted: Tue 04 Jun 2013, 16:05
by goingnuts
I could not get VLC running, nor gnash and although flasm decompress the swf ffplay/mplayer wont play...

Some scripts out there for mplayer but that seems to be based on youtube serving flv-format in the past.

I followed technosaurus idea here and got a working draft based on ffplay and a gtkdialog1 script. Video is working (some gives "Protocol not supported" though...) but I cant get sound out of the thing. Guess its a ffplay compile thing - maybe.
I do not use youtube enough to spend days fine tunning the thing so just drop the draft here for better minds or times...

Code: Select all

#!/bin/ash
#pmtube-0.1.
#demo script for gtkdialog1 sort of poor mans youtube viewer.
#June2013 goingnuts
#draft!

[[ -x ../../src/gtkdialog1 ]] && PATH=../../src:$PATH

rm -f tablelist test.html test2.html

#ash function file
echo '

get_me () {
	rm -f test.html
	if [ ! "${ENTRY}" = "" ]; then
		#need formating the query
		query=$(echo "${ENTRY}" | sed "s/ /+/g")
		busybox wget -O test.html -U firefox "http://m.youtube.com/results?gl=US&client=mv-google&hl=en&q="${query}"&submit=Search"
	else
		return
	fi
	#construct list of findings
	grep "<a accesskey=" test.html | grep -v "#" | cut -d " " -f3- | tr -d ">" > tablelist
}

list_me () {
	if [ -f tablelist ]; then
		cat tablelist | cut -d " " -f3-
	fi	
}

play_me () {
	#check status - are we playing?
	if [ ! "$(pgrep ffplay)" = "" ]; then 
		kill -CONT $(cat mypid)
		return	
	else
		rm -f mypid
		#do not play empty list...
		if [ ! "${LIST}" = "" ]; then	
			#first find link to the selection
			link=$(grep "${LIST}" tablelist | cut -d " " -f1 | cut -d ";" -f4 | tr -d "\"")

			#get the link
			busybox wget -O test2.html -U firefox "http://m.youtube.com/watch?gl=US&client=mv-google&hl=en&"${link}""
			wait

			play_url=$(grep -m1 "rtsp" test2.html | cut -d "\"" -f2)
		
			#now play it
			./ffplay -x 200 -y 200 -autoexit -window_title "${LIST}" "${play_url}" &
			echo $! > mypid
		fi
	fi
}

pause_me () {
if [ -f mypid ]; then
   	speakPID=$(cat mypid)
	kill -STOP $speakPID
fi
}	

stop_me () {
if [ -f mypid ]; then
    ffplayPID=$(cat mypid)
	kill -CONT $ffplayPID
	kill $ffplayPID
	killall ffplay
	rm -f mypid
fi
}	


' > /tmp/pmtube_ash


export MAIN_DIALOG='
<wtitle>pmtube 0.1</wtitle>
<vbox>
	<hbox>
		<entry>
			<variable>ENTRY</variable>
		</entry>
		<button>
			<label>Search</label>
			<action>get_me</action>
			<action clear>LIST</action>
			<action refresh>LIST</action>
		</button>
		<button>
			<label>Play selected</label>
			<action>play_me</action>
		</button>
		<button>
			<label>Pause</label>
			<tooltip>Pause</tooltip>
			<action>pause_me</action>
		</button>
		<button>
			<label>Stop</label>	
			<action>stop_me</action>
		</button>
		<button>
			<label>Quit</label>
			<action>exit</action>
		</button>
	</hbox>
	<hbox>
		<list>
			<input>list_me</input>
			<variable>LIST</variable>
		</list>
	</hbox>
</vbox>
'

gtkdialog1 -d --center --wmclass pmtube --program=MAIN_DIALOG -i /tmp/pmtube_ash

rm -f /tmp/pmtube_ash  tablelist test.html test2.html mypid
killall ffplay

exit

Posted: Thu 06 Jun 2013, 21:42
by Ibidem
goingnuts wrote:I could not get VLC running, nor gnash and although flasm decompress the swf ffplay/mplayer wont play...

Some scripts out there for mplayer but that seems to be based on youtube serving flv-format in the past.

I followed technosaurus idea here and got a working draft based on ffplay and a gtkdialog1 script. Video is working (some gives "Protocol not supported" though...) but I cant get sound out of the thing. Guess its a ffplay compile thing - maybe.
Re: "Protocol not supported": try youtube-dl, make sure you have librtmp/rtmpdump compiled with an SSL library...

Re: no sound:
strace ffplay <somefile.wav> 2>&1 >/dev/null |grep /dev
If it plays, try with an mp3/mp4 file you know has audio.

Note the order of redirection in the example above! Reverse it, and it's silent. But this way, stdout is silenced and stderr becomes stdout.

Posted: Fri 07 Jun 2013, 14:22
by goingnuts
Ibidem: thx...
I did look at "youtube-dl" but seems to be python-based and I could not get it running in P412.
My ffplay plays wav & mp3 files ok from disk...
Output of the suggested command:

Code: Select all

strace ./ffplay test.wav 2>&1 >/dev/null |grep /dev 
stat("/dev/sound", 0xbfb1e4e0)          = -1 ENOENT (No such file or directory)
open("/dev/dsp", O_WRONLY|O_NONBLOCK)   = 7
Maybe another app could take care of the sound - although this adds to the complexity - any youtube audio-only players out there?