OESF Portables Forum

Model Specific Forums => Sharp Zaurus => Zaurus - pdaXrom => Topic started by: Zazz on May 01, 2004, 11:33:09 pm

Title: latex
Post by: Zazz on May 01, 2004, 11:33:09 pm
I got latex up and running on my Z. It is a minimal installation, consisting only of latex, xdvi and dvips. I also got ghostscript so that pdfs can be distilled and xdvi does preview embedded graphics (which looks gorgeous on the little screen). Everything runs at very usable speed and does not consume too much space (3.5MB for latex with a full set of cm/ams fonts and 2.1MB for ghostscript v8.14 without fonts, all sizes compressed), so keeping it on the internal flash of the Z poses no problems. The setup works completely without pk fonts, they would eat up too much space and wear down the internal flash by their random recreation. The present installation only contains the base system, so carefully pick and install those additional style files you need (they compress well). You would need about another 1.5MB compressed for a full set of base35 type1 files (urw or adobe, not provided), shared by dvips and ghostscript. Due to the minimalistic nature of the present setup, it is recommeded to have a desktop with a complete texmf tree to fill in the needed style files. I realize I may need to add few selected binaries like bibtex or makeindex and will do so in due course. I don\'t use lyx, so don\'t ask for it. The binaries can downloaded from here (http://zaurus.zapto.org/zazz/tex/).
Title: latex
Post by: jandr on January 10, 2005, 12:33:43 pm
Hi everyone,
this post made me happy, as pdaXrom does everything I need (really well too) except for displaying the DVI files that my tex installation produces.  The TeX installation I got from <http://www.linguistics.ucla.edu/people/Kracht/zaurus/zaurus.html> is happy, but the dvipdfm isn't.  And xpdf itself seems horribly broken in any case, and all other ROMs that have a dvi viewer seem to require libs that are incompatible with pdaXrom.

But the site Zazz listed seems to be permanently down!  Does anyone out there know where to get Zazz's, or any other, DVI viewer that'll work on pdaXrom?  A working dvi->ps + ghostscript toolchain would be a fine mechanism too.

thanks, and thanks for pdaXrom, it's great!
jg

p.s. silly side question: how does one get a backquote character from the keyboard in pdaXrom?


[I've got a new-to-me SL-C760 + 256MB Viking SD & AmbiCom 802.11b CF cards.]
Title: latex
Post by: Zazz on January 10, 2005, 01:02:38 pm
Yes, my site is permanently down (hardware died), sorry for that. ScottYelich was kind enough to host a copy on his site (http://zaurus.spy.org/feeds/cacko/pdaXrom/misc/zazz/ztex/). Note that this LaTeX setup has not been modified since May 2004 and has only been tested under pdaxrom 1.0.5. Good luck.
Title: latex
Post by: jandr on January 10, 2005, 01:44:19 pm
Wow, that's fast service... thanks Zazz, and Scott.  I'll let the forum know how it all works in Kathrin RC8.
Title: latex
Post by: jandr on January 10, 2005, 08:30:02 pm
Well, no surprise I had limited success: zazz' TeX runs fine (once I remembered to unsetenv TEXINPUTS) and produces DVI files that look fine on my desktop machine.  But on the Z the included xdvi bombs with "illegal exception" and the included dvips gives bad postscript (GNU, ESP and Alladin gs all say "Error: /limitcheck in -file-").

So is anyone with a Kathrin SDK willing to give packaging up xdvi (or xdvik or advi) a shot?  You'd be helping out a poor Fortran coder who knows nothing of GUIs.   And if t helps, I'm about to send off a little donation to the pdaXrom guys.

thanks
jg

p.s. For kicks I tried zazz's gs too, but it bombs with "Unrecoverable error: rangecheck in setscreen" even when given a known-good file.  I imagine this is either a kathrin-library-mismatch or a missing-font issue, but in any case I'm not even at a place to have .ps files to give it.
Title: latex
Post by: Zazz on January 10, 2005, 09:00:13 pm
Yes, most likely an incompatibility due to the changes in fp-emulation. If recompiling is not an option, a quick and dirty solution would be to put the old libs from v1.0.5 (libc, libm, maybe libX*, etc) into a separate directory and make LD_LIBRARY_PATH wrappers (tiny shell scripts setting LD_LIBRARY_PATH to this dir and then exec'ing the true binaries) for the misbehaving apps.
Title: latex
Post by: jandr on January 10, 2005, 10:25:42 pm
Sir. I thank you!  Not knowing how to extract 1.0.5's lib[cm] from the ROM image, I simply grabbed the libc6 deb for woody, unpacked it, set LD_LIBRARY_PATH and voila!  xdvi works beautifully.

gs still has issues but that's of no concern for me... I've now got a full LaTeX authoring environment on my Z!  (It's one of the main uses I wanted it for.)  Thanks so much!  
Title: latex
Post by: jamesannan on January 11, 2005, 01:38:16 am
I'm using the image file from

http://www.snowelm.com/~t/doc/tips/20031120.en.html (http://www.snowelm.com/~t/doc/tips/20031120.en.html)

It is 60MB but with a 512MB SD card who cares. I have written a few papers and presentations on the Z (mine is an 860 with Sharp Rom) - not always to completion, but significant parts. I plan to use the Z with cfxga card to give a few presentations in a couple of months, to save carrying a laptop around..

James
Title: latex
Post by: jandr on January 11, 2005, 10:35:13 am
Well, I can finally contribute something concrete to this thread: imagine my amazement to find that gcc in kathrin comes complete with X libraries and headers, including Xaw and Motif.  So I was able to compile a 1.1.0-happy xdvi straight from the original sources.  You can get the binaries from
here. (http://interstel.net/~girash/zaurus/)

Thanks Zazz for doing all the hard work!
jg
Title: latex
Post by: MarcusKracht on January 13, 2005, 07:16:19 pm
I have just read the emails concerning latex. Having put up my
own solution I would be curious to see what caused the hickup
with dvipdfm. Maybe I forgot to say something on my website
(www.linguistics.ucla.edu/people/Kracht/zaurus/zaurus.html), so
that if you follow the given instructions you might not succeed.
My own installation (for pdaXrom version 1.0.5) works without
any trouble, recently I even managed to include txfonts. xpdf needs
some attention with the fonts. You need to provide some of them
(as I explained with the dingbats). Just pay attention to the log
of pdflatex when you run it on a big machine. It tells you what
fonts it uses at the end. I included them all, because my latex
resides on the SD card (no worry, it runs very fast!).

I have updated my page, so take a look. Zazz, thanks for providing
xdvi-awk.bin. I had a version of xdvi that kept looking for xdvi.bin.
I gave it xdvi-awk.bin under the name xdvi.bin and that seems to
work. I shall experiment with dvips and ghostview to see how they
work and then wrap up my installation for public use.

I do not know about version 1.1.0, so maybe things are different
there. Since my 1.0.5 works mostly fine, I have no incentive to
change yet.

Keep me posted,

                     Marcus

PS Maybe someone can create an ipk at some point? I do not know
how to do these things but am happy to help with whatever I
know about latex on the zaurus.

PPS Someone asked about the backquote. It's <Fn> plus the
key right next to it, which has Japanese characters on it.
Title: latex
Post by: alan on February 09, 2005, 02:51:55 am
Quote
I don't use lyx, so don't ask for it.

I'm sorry to ask for this, but any luck Lyx might be cross compiled for the Z ? It's so much easier to create latex files with it...

The exportation module is of course very important in this prog; but maybe (i even don't know if it's possible) we could deal without it, at least at first time. Procucing .lyx files on the Z and then exporting them to pdf on a PC would be not that bad...

But of course, a fully fonctionnal lyx installation would be the best !

I'm so sorry i'm not able to cross compile anything, but is there any volunteer ?
Title: latex
Post by: MarcusKracht on February 10, 2005, 01:14:58 pm
Okay, Zazz and Jandr, I am back in the business. After Installing RC9 and doing the
dirty work, I have managed to also use the ztex and xdvi. See my report on
http://kracht.humnet.ucla.edu/marcus/zaurus/zaurusrc9.html (http://kracht.humnet.ucla.edu/marcus/zaurus/zaurusrc9.html)

I am stuck with ghostview. I get a screen for a second then it stop and, among mnay other
stuff, it gives the following error:

(...)
Error: /undefinedresult in --div--
Operand stack:
          Fa 136 --nostringval-- w 46000.0 -0.0
(...)

It seems to be doing fine for a while and then a hickup. I have had this problem for
a while and cannot get it to disappear.

dvipdfm claims to need fonts.map but I cannot see anywhere in my configs that
I told it to look for these fonts. kpsewhich does not find anything ... But latex works,
xdvi, dvips work perfectly.

Any suggestions?  

-- Marcus
Title: latex
Post by: jandr on February 14, 2005, 11:28:58 pm
Quote
I am stuck with ghostview. I get a screen for a second then it stop and, among mnay other
stuff, it gives the following error:

(...)
Error: /undefinedresult in --div--
Operand stack:
          Fa 136 --nostringval-- w 46000.0 -0.0
(...)

It seems to be doing fine for a while and then a hickup. I have had this problem for
a while and cannot get it to disappear.

dvipdfm claims to need fonts.map but I cannot see anywhere in my configs that
[div align=\"right\"][{POST_SNAPBACK}][/a][/div] (http://index.php?act=findpost&pid=66467\")

Hi Marcus,
It sounds like you're still having library issues with gs... try following my instructions [a href=\"http://interstel.net/~girash/zaurus/#oldlibs]here[/url] to get gs going.  (I see on your page that you give similar instructions as on mine, but you say export LD_PRELOAD=/lib/glibcc_s.so instead of export LD_PRELOAD=/lib/libgcc_s.so.  Is the extra g intentional?  If not that may be the problem.)

For dvipdf, I wasn't able to get dvipdfm to work at all, but using the same technique as for gs (but replacing 'gs' with 'dvipdf' everywhere in the script file & its filename of course) I got the dvipdf from Zazz' gs distribution working great.  I may also have had to copy a bunch of files from my desktop's latex tree over in order to avoid the same fonts.map problem you had; I'm sorry but I honestly can't remember.  Then again, your page says that you've got dvipdfm to work on "simple files", so it's possible that all my files are simple and I've just never come across the bug that yours trigger.  

j

p.s. I'm glad to hear that the OCAML was useful for you.

[C760 / Ambicom Wifi CF / various SD cards, none of which I'm happy with]
Title: latex
Post by: MarcusKracht on February 15, 2005, 03:32:47 pm
Hi Jandr,

here is an update. I use dvipdfm, as provided in the earlier package which I got from
somewhere (and mirrored on my site). Maybe the stuff in the gs package will work
as well. But the devipdfm, after being wrapped, now seems to work. I do not know
what caused the hickup. I noticed though that initially the rc9 would often forget the
paths and I had to issue a friendly reminder that it should include /usr/bin/latex in its
search path. Also, occasionally kpsewhich would not give any meaningful results. I
was puzzled. But now, apparently, things work. Except for ghostview ... And the
error was only on the website (now corrected), not in my files. So, I am afraid, I still
don't know what the problem is. I keep searching.

-- Marcus
Title: latex
Post by: jandr on May 23, 2005, 08:15:44 pm
Quote
Error: /undefinedresult in --div--

Hi again Marcus,
I just upgraded to rc10 and encountered the same problem as you... I think the solution is to populate /usr/share/ghostscript/fonts/ with whatever your desktop machine has on it.  According to the gs.README file, you might have to "update Fontmap if necessary".  (I didn't have to.)

Of course, you may have already figured this out.    

jg
Title: latex
Post by: MarcusKracht on May 25, 2005, 08:00:49 pm
Quote
Quote
Error: /undefinedresult in --div--

Hi again Marcus,
I just upgraded to rc10 and encountered the same problem as you... I think the solution is to populate /usr/share/ghostscript/fonts/ with whatever your desktop machine has on it.  According to the gs.README file, you might have to "update Fontmap if necessary".  (I didn't have to.)

Of course, you may have already figured this out.    

jg
[div align=\"right\"][a href=\"index.php?act=findpost&pid=81150\"][{POST_SNAPBACK}][/a][/div]

Dear Jandr,

in fact, I have not. So I'd like to be updated about the development. So far, I use xdvi and xpdf,
both of which do excellent service. I am not sure how it works if I update to rc10. Is it worth it?
I remember rc9 having issues with cross compiling and that kpathsea had to be trimmed a little.
I vaguely remember that there was a plan that updates should not be a matter of reflashing
(is loosing the data and the installation that I have made to work). So any hints are welcome.

-- Marcus
Title: latex
Post by: jandr on May 26, 2005, 01:13:07 pm
Quote
I'd like to be updated about the development. So far, I use xdvi and xpdf,
both of which do excellent service. I am not sure how it works if I update to rc10. Is it worth it?
I remember rc9 having issues with cross compiling and that kpathsea had to be trimmed a little.
I vaguely remember that there was a plan that updates should not be a matter of reflashing
(is loosing the data and the installation that I have made to work). So any hints are welcome.

-- Marcus
[div align=\"right\"][{POST_SNAPBACK}][/a][/div] (http://index.php?act=findpost&pid=81532\")

I only left rc8 because I'd hosed my installation (which I later determined to be from using some fonts that  X didn't like).  I skipped rc9 after also having some difficulties with compiling on it, and have found rc10 to have two major improvements, one relevent to this topic & one not:

- xpdf now works out-of-the-box, with no funny library requirements;

- in rc8 some system apps (e.g. packagemanager) would silently fail if I had an SD card in the slot; that seems to be fixed.

Everything I installed under rc8, whether compiled by me or grabbed already built, seems to work fine. So for me rc10 is a minor improvement overall, but probably not worth moving to from rc8 unless you need to reinstall anyway.

I do have one issue with my new installation which is probably more due to my lack of understanding of latex than anything: whenever I use xdvi or dvips on my own latex files, I get an warning message about fonts "cmex8" and "msam8" not being found, and using cmr10 in their place.  I don't remember getting that error before but I can't figure out how to tell xdvi or dvips where those fonts are located (I do have them on the Z, copied over from my desktop tetex installation).  latex itself doesn't complain about the "missing" fonts.

cheers
jg

EDIT: I solved the missing dvi fonts problem: latex was happy with the .tfm versions but xdvi wanted .pfb files, which I downloaded from [a href=\"ftp://ftp.rge.com/pub/tex/fonts/cm/ps-type1/bakoma/pfb]here.[/url]  (Note this is different from the missing-gv fonts problem described a couple posts back.)
Title: latex
Post by: MarcusKracht on February 01, 2006, 03:54:17 pm
I have recently acquired a Zaurus C3100 and installed the new rom (beta 1).
My old latex installation I cannot get to work now. On the other hand, given
the space that I have on the harddisk, it would be no problem to compile it
onto the zaurus using the sources. I tried that and it gave me errors (there
was a problem with type compatibility). Since compiling otherwise works (I
was successful with OCaML), I am somewhat helpless to understand what
exactly is the problem (I am not a software developer). Can someone help
me? I can provide the full log if you need.  

-- Marcus
Title: latex
Post by: develd on February 01, 2006, 07:03:06 pm
Hi Marcus,

on my C3100 I have compiled tetex-3.0 nearly 6 month ago. So I can't remember the dependencies which were needed. But I have compiled it to an extra directory /usr/local/teTeX with bin-dir and texmf-dir. Maybe it's competely there.

For me it works perfectly. I'm using vi, pdflatex and xpdf. I just started xdvi to check if it works too and it started up and is quite fast. It's faster as xpdf and has no screen problems while scrolling like xpdf. Maybe I switch over to work with xdvi in the future   .

Tell me if your interested in my teTeX directory. It's 260MB because I haven't stripped any of the texmf directory. I could tgz it and make it downloadable for you anywhere.

On the other hand with your working compiler you shoul be able to compile tetex-3.0 yourself after checking out all the options from the configure script.

  Greetings,
  Oliver
Title: latex
Post by: iamphet on February 02, 2006, 01:01:02 am
Also there is another approach: you can use Pocketworkstation and install debian TeX packages
Title: latex
Post by: MarcusKracht on February 02, 2006, 12:13:10 pm
Quote
Hi Marcus,

on my C3100 I have compiled tetex-3.0 nearly 6 month ago. So I can't remember the dependencies which were needed. But I have compiled it to an extra directory /usr/local/teTeX with bin-dir and texmf-dir. Maybe it's competely there.

For me it works perfectly. I'm using vi, pdflatex and xpdf. I just started xdvi to check if it works too and it started up and is quite fast. It's faster as xpdf and has no screen problems while scrolling like xpdf. Maybe I switch over to work with xdvi in the future   .

Tell me if your interested in my teTeX directory. It's 260MB because I haven't stripped any of the texmf directory. I could tgz it and make it downloadable for you anywhere.

On the other hand with your working compiler you shoul be able to compile tetex-3.0 yourself after checking out all the options from the configure script.

  Greetings,
  Oliver
[div align=\"right\"][a href=\"index.php?act=findpost&pid=113323\"][{POST_SNAPBACK}][/a][/div]

Yes please. Indeed: xdvi is much faster than xpdf! I'd like to have the whole tree, 260MB
is not a problem. It is too bad you do not remember what you did, because I tried to com-
pile but got an error. I tried to change settings but no result so far. Maybe I have to learn
more about compiling ...

-- Marcus
Title: latex
Post by: MarcusKracht on February 03, 2006, 12:08:29 pm
HELP please!

I made some progress with compiling. But I am still not through.

(1) There is a type conflict indeed between types defined in texk/kpathsea/c-std.h
where "realloc" and others are declared as ALLOC_RETURN_TYPE, which as far as I
could make out is declared to be "void". This however created a type mismatch, so
I changed their type to "void" thus bypassing ALLOC_RETURN_TYPE. This worked.
Keep fingers crossed.

(2) Twice it complained that it could no open sedscript. I made an empty file with that
name and that worked.

(3) It is missing the command "ed". There is a file is /bin/ed on my main PC, but is
missing on the Zaurus. Can someone please provide this file or tell me where to
find it? (I am using beta 1 for C3100).

-- Marcus
Title: latex
Post by: develd on February 03, 2006, 12:08:30 pm
I have made and tar zip from the whole dir. You should place it to /usr/local and untar it. I saw no soft links to other places and my ld.so.conf does not show any entries for this package.

You can download it from http://doshome.edvings.de/tetex_C31k.tgz (http://doshome.edvings.de/tetex_C31k.tgz)
It will be there for a week or two since webspace is limited but needed.

Hopefully I haven't any private tex things in this tree  

-- Oliver
Title: latex
Post by: MarcusKracht on February 03, 2006, 01:03:48 pm
Quote
I have made and tar zip from the whole dir. You should place it to /usr/local and untar it. I saw no soft links to other places and my ld.so.conf does not show any entries for this package.

You can download it from http://doshome.edvings.de/tetex_C31k.tgz (http://doshome.edvings.de/tetex_C31k.tgz)
It will be there for a week or two since webspace is limited but needed.

Hopefully I haven't any private tex things in this tree   

-- Oliver
[div align=\"right\"][a href=\"index.php?act=findpost&pid=113544\"][{POST_SNAPBACK}][/a][/div]

Vielen Dank!

I have meanwhile found ed (stupid me, I didn't see it), but meanwhile had another
complaint from gsftopk.c. I reckon that this is going to take forever. It does not
seem trivial at all. Some changes must have been made that upset the compiler.

-- Marcus
Title: latex
Post by: MarcusKracht on February 03, 2006, 02:39:12 pm
This seems to work! I tried latex and xdvi and they worked. I have the tgz, if
things go wrong I can retry. You may dismount them at your end. If you do not
mind, I shall make the files available on my server together with installation
instructions (see http://kracht.humnet.ucla.edu/marcus/zaurus/zaurus-3100.html (http://kracht.humnet.ucla.edu/marcus/zaurus/zaurus-3100.html)
for the progress so far).

-- Marcus
Title: latex
Post by: pgas on February 03, 2006, 03:27:42 pm
I mirrored it there:

http://mail.pdaxrom.org/contrib/misc/teTeX_C3k1.tgz (http://mail.pdaxrom.org/contrib/misc/teTeX_C3k1.tgz)
Title: latex
Post by: develd on February 03, 2006, 07:48:46 pm
Nice to hear that it's working. There is just one own cls file in texmf-var but nothing spectacular. Just an extension to the g-brief.cls to write proper bills for according the german fiscal authorities.

Remember I haven't deleted any of the huge texmf directory so it could be shrinked by removing the ./doc and some other directories.

Working mirrors of the tgz are out there, so I will freeup my webspace.

Nice to see there are still many people out there, who like and enjoy LaTeX.

  Happy TeXing,
  Oliver
Title: latex
Post by: radiochickenwax on January 21, 2007, 03:04:26 am
First off, I really appreciate that there are other TeX users out there who also enjoy the zaurus platform.

However,   tetex-3.0   (http://www.tug.org/tetex/)  seems to be missing a ipkg that works for my SL6000.  I do appreciate that the tar file in this thread exists at all, but as of right now, it's not currently available through the pdaxrom server migration.

There is another version I've noticed located  here: (Jan Poland's version) (http://www-alg.ist.hokudai.ac.jp/~jan/zaurus.html) but I've got the usual problems with getting xdvi and dvipdf to work out of the box.  

So I actually went as far as compiling the source, which took a long time, and a lot of trial and error, beginning with the problems noted on Marcus Kracht's page  (http://kracht.humnet.ucla.edu/marcus/zaurus/zaurus-3100.html#latex), but eventually this worked. My main problem ended up in getting xdvi to notice the xaw toolkit in the native compiler, which was solved with the following configuration option:

Code: [Select]
(./configure --with-xdvi-x-toolkit=xaw)

 I'd like to know if anyone is interested in an ipkg of this, and what suggestions there might be to go about doing it, since it's still roughly 250MB+ before compression, and this isn't quite the standard linux application.

Also, a lot of the programs included in tetex are quite out of date since Thomas Esser stopped updating it..  Maybe it might be best to try TeX Live, although that's probably even larger?
Title: latex
Post by: Ling on January 21, 2007, 09:55:29 am
Not sure who had tetex, but all of the feeds have been copied to ibiblio. If you know who had compiled it, you should be able to find it.

http://distro.ibiblio.org/pub/linux/distri...wnload/contrib/ (http://distro.ibiblio.org/pub/linux/distributions/pdaxrom/download/contrib/)
Title: latex
Post by: radiochickenwax on January 21, 2007, 02:20:09 pm
Fprgive me if I'm wrong, but I don't think tetex is on the ibiblio server yet.  It wasn't packaged as an ipkg, but as a tar file.  What I'm interested in is packaging a working and more up to date TeX distribution.  AFAIK, tetex is much easier to build for unix than TeX live, and also much smaller.  

There is a version mentioned in my post above available from Jan Poland's page (http://www-alg.ist.hokudai.ac.jp/~jan/zaurus.html) that can be used as an ipkg or as a mountable image, but this doesn't completely work for me, since all of the DVI utilities seem to be broken.  Perhaps I'm doing something wrong.

I compiled the source, and this works, but it's still out of date,  since the original maintainer stopped contributing to this distribution of TeX.  What I'm interested in is trying to maintain more current versions of these programs.