64

I used VerbTeX app in my Android phone. But this app does not support XeLaTeX and requires an internet connection to be used.

Is there any distribution of TeX for Android?
How I can install TeX on my Android phone?

0

7 Answers 7

21

Just have a look here: TexPortal. This is an App for Android which runs fine on my Nexus 7 without the need for rooting my device (this was important for me). If you download all the packages you don't need an internet connection to compile the documents. Most of the time I use it just for short letters, but for testing I compiled my diploma and my master thesis with this App without any trouble.

3
  • From what I understand TeXPortal does not support XeLaTeX. Is this correct? Commented Dec 26, 2012 at 18:20
  • 3
    I just replaced the link does not work and the additional information that texportal is no longer free.
    – Edy Jo
    Commented Jan 9, 2014 at 21:52
  • 2
    I'd classify writing LaTeX on a phone straight under "extremely cruel and unusual punishment"... and if you add a Bluetooth keyboard to make it halfway practical, a mini-notebook (or even an by now outdated netbook) looks much more alluring.
    – vonbrand
    Commented Oct 19, 2015 at 1:10
46

I am the author of TeXLive for Android. I have provided an .apk file for Android, but I have not added XeTeX to my app, due to the large size of the xetex binary. You can get XeTeX from here: http://texlive-for-android.googlecode.com/files/tl4a-2013-06-18.tar.xz. I am now testing my GUI of tlmgr, which is written completely in Java.

The next version of my App will add biber and Vim 7.4 in 2014. A TeX editor for my App is now under development.

6
  • Does anyone have a working /sdcard/texlive/texmf.cnf they could share? Also what part exactly of the texlive distribution should be copied into /sdcard/texlive? Perhaps someone could share the output of ls /sdcard/texlive from a working installation? Commented Jun 29, 2013 at 12:48
  • 2
    @flamingpenguin You can modify a texmf.cnf which have already installed in your computer. And then move this texmf.cnf to /sdcard/texlive. On my computer, this texmf.cnf file can be found in C:\texlive\2013\texmf-dist\web2c\texmf.cnf. What you should do is changing the value of TEXMFROOT. Please read the comments in the texmf.cnf carefully.
    – Clerk Ma
    Commented Jun 29, 2013 at 15:29
  • 2
    OK, that worked great. I just did a portable installation of texlive into /usr/local/texlive/2013 on my linux machine. (I left out the source and docs for diskspace). Then I "rsync" the whole /usr/local/texlive/2013 into /sdcard/texlive on my asus tf700 (using the terminal IDE app from app store) and copied the texmf.cnf you mention into /sdcard/texlive and change the TEXMFROOT to /sdcard/texlive and then everything worked (although no arm biber bins are available so I have to use bibtex). Builds my complicated beamer pdfs perfectly. Awesome, thanks. Commented Jun 29, 2013 at 16:12
  • @flamingpenguin It's my pleasure. I found that the biber program in TUG's SVN is existed in binary file. I have not get sources in the SVN. I need have a look at biber, then port it to Android.
    – Clerk Ma
    Commented Jun 29, 2013 at 16:23
  • 1
    @clerk-ma TeX Live for Android does not work on Android 5. It produces an error: error: only position independent executables (PIE) are supported. If you have some time, please, recompile the app with PIE support. This way it will work on Android 5. Commented Dec 19, 2014 at 17:39
40

There is work to implement TeXLive 2012 for Android. The development site provides information on progress as well as access to downloads. The code is still experimental but might be worth a try. Otherwise the existing solutons are similar to VerbTeX and may involve web-based LaTeX processing.

1
  • Ooh must try that... Commented Dec 18, 2012 at 16:21
10

Just providing a little more detailed howto for this... I just installed texlive 2013 on my Asus TF201 and I am now able to generate PDF using beamer, tikz, pgfplots, bibtex, etc. on my tablet :)

In a few steps:

  1. Download and make a "portable" installation of texlive on another computer.
  2. Zip the created folder (2.1Gb for full LaTeX) and transfer to your android device.
  3. Unzip folder to /sdcard/texlive
  4. Copy the texmf.cnf from /sdcard/texlive/texmf-dist/web2c to /sdcard/texlive
  5. Change in this file TEXMFROOT to /sdcard/texlive
  6. Install TeXLive for Android and click "Install TexLive" (generates binaries, e.g. latex, pdflatex, bibtex, etc.)
  7. Enjoy :)
2
  • Just for information: it didn't work on my machines (slackware 12.2 - i386, android 4.3 on galaxy note II); step 6. was unsuccessful. Even tried multi.
    – user43115
    Commented Dec 23, 2013 at 4:29
  • I had some trouble getting this to work as well but managed after quite lot of experimenting. I was missing valid formats (i.e. "pdflatex.fmt") and had to generete these in my tablet. To generate a format file, use: pdflatex -ini -output-directory=/sdcard/texlive -jobname=pdflatex latex.ltx (latex.ltx is situated in the folder texlive/texmf-dist/tex/latex/base, with a texmf.cnf file as above, TL4A finds it). You can then generate pdfs with pdflatex -fmt=/sdcard/texlive/pdflatex.fmt -output-format=pdf -output-directory=/sdcard/some_path /sdcard/path_to_texfile
    – user49901
    Commented Jun 26, 2016 at 15:09
6

It's also possible to install texlive through the Linux terminal emulator app Termux. The app is available for Android 5.0 and newer on both Google Play and F-Droid.

Writing .tex files and compiling them works just as on a normal linux distribution, editors such as vim and emacs are available.

It's open source as well, check out the github repos.

3

The geek solution is to install Jack Palevich's Android terminal emulator and then Kevin Boone's Kbox2, then you can install a LaTeX distribution, I personally made my own by extracting only essential packages from TeXLive archives on ctan.org and picking the pdftex binary that comes with texportal. I don't know if TeXLive for android is based on the same trick. It works great for me but only in urgency case because I have no computer at home, only a cheap tablet (mpman mp888)... and of course no root needed to all this. Maybe vim can make the workflow better than editing with droidedit and switch to the terminal to compile (it is what i'm doing)

0
1

I spent some time figuring this out...

My approach:

  • VerbTeX Pro for editing latex documents, which gives a nice android-friendly UI.
  • GNURoot Debian with openbox and tightvncserver as a UI which can be viewed in VNC reader for automatic compilation and preview. Briefly, I installed texlive-full in here and I'm using latexmk to automatically recompile my pdf when I save changes in VertTeX Pro. The resulting pdf will be automatically updated if your previewing it in evince.

The end result is that every time I press save in VerbTeX Pro, I can just Alt Tab to VNCViewer which will already be showing a preview of the latest changes I made. I'm not sure how nice this is on a phone, but on a tablet with keyboard, its quite convenient.

The guide on how to do this is a bit long for an answer here... so you can check my blog here if you want all the details on how to set this up.

With some options in latexmk, I'm sure you can compile with XeLaTeX.

Not the answer you're looking for? Browse other questions tagged .