# Why can't TeX Live's size be reduced?

I understand that the following question has been answered

Why is the MacTeX distribution so large? Is there anything smaller for OS X?

but my question differs from it. I just installed MacTeX and it used over 4 gigabytes of space on my computer. I understand the full LaTeX uses many, many libraries, but this is as big or bigger than an operating system. So my question is:

Why can't the developers of TeX Live create it so it has very low overhead?

Details would be really appreciated.

I can only imagine the possibilities such as including it in web browsers and other applications/plugins (keynote, powerpoint, etc.).

-
Then install TeXLive manually. The advanced installer include various schemes which vary in size. –  daleif Jun 18 '13 at 14:33
I guess, since the price of 1GB of internal (non-SSD) hard disk storage is currently in the order of 5 cent (US), none of the developers really cares enough. –  Caramdir Jun 18 '13 at 23:13
@Caramdir I understand why it is that size, but if you see the last point I made, I care more about reducing the size so that maybe in the near future LaTeX becomes a more widespread standard. It would make no sense to install a browser that needed 4GB space just for a TeX library. –  lababidi Jun 19 '13 at 17:56
@daleif can this advanced installation be done on windows and mac? –  lababidi Jun 19 '13 at 17:56
@lababid: If you take just the `lualatex` executable (and necessary supporting programs), a minimal amount of packages and use system fonts you'll probably only need a couple of megabytes. But that won't be "TeX Live" anymore. Also your TeX-in-browser idea will very likely need a special implementation anyway. The standard TeX engine can't just be plugged into a browser rendering engine. –  Caramdir Jun 20 '13 at 2:06

As you can see from

``````\$ du -sch /usr/local/texlive/2012/texmf-dist/*
16M     /usr/local/texlive/2012/texmf-dist/bibtex
1008K   /usr/local/texlive/2012/texmf-dist/context
1,5G    /usr/local/texlive/2012/texmf-dist/doc
6,6M    /usr/local/texlive/2012/texmf-dist/dvips
1,4G    /usr/local/texlive/2012/texmf-dist/fonts
1,9M    /usr/local/texlive/2012/texmf-dist/ls-R
308K    /usr/local/texlive/2012/texmf-dist/makeindex
444K    /usr/local/texlive/2012/texmf-dist/metafont
3,9M    /usr/local/texlive/2012/texmf-dist/metapost
36K     /usr/local/texlive/2012/texmf-dist/mft
2,1M    /usr/local/texlive/2012/texmf-dist/omega
256K    /usr/local/texlive/2012/texmf-dist/pbibtex
11M     /usr/local/texlive/2012/texmf-dist/scripts
726M    /usr/local/texlive/2012/texmf-dist/source
218M    /usr/local/texlive/2012/texmf-dist/tex
22M     /usr/local/texlive/2012/texmf-dist/tex4ht
20K     /usr/local/texlive/2012/texmf-dist/texdoc
48K     /usr/local/texlive/2012/texmf-dist/texdoctk
12K     /usr/local/texlive/2012/texmf-dist/web2c
3,8G    insgesamt
``````

the major part is documentation and fonts. If you are satisfied with a single font and without documentation, the distribution can be much smaller. There were several attempts to create such a minimalistic distribution, but I'm not sure if they are still available.

And as daleif stated in his comment, you can install a much smaller TeX Live as well.

As real overhead, maybe the `source` directory counts, which is also quite large. It consists of sources of most of the stuff in the other directories such as LaTeX packages etc. But this is rather a political than a technical question, therefore I leave it to the TeX Live people to answer it (IIRC they already answered it, maybe on the TeX Live mailing list).

-
Would it really be without documentation, though? Isn't there a way to keep all of the `dtx` sources? (Thinking out loud; I'm not even sure the sources are distributed.) –  Sean Allred Jun 18 '13 at 20:59
@SeanAllred: The sources are distributed (in `/source`), but the PDF versions are probably more useful to most people. –  Caramdir Jun 18 '13 at 23:06
@Caramdir True -- I'm still struggling with how to compile one of those `dtx`-fangled things (although it may have something to do with not having `doc` or `docstrip`?). It's plain to see though that `source/`, while sizable, is significantly smaller than `doc/`. Your documentation can be generated ad-hoc if need be. –  Sean Allred Jun 18 '13 at 23:12
@SeanAllred but who other than extremists would generate documentation when needed? If I have a problem and need to look in the manual, I don't want to have to compile the manual first, that is a waste of my time. –  daleif Jun 21 '13 at 8:24
@daleif It's not a waste of your time if you need the manual. (And are we really talking about how long it (doesn't) take to compile a document?) –  Sean Allred Jun 21 '13 at 12:35

You can install a much more minimalistic texlive using profiles. Have a look at this install script I use in my github repo. I have this install just the packages I need to build the PDFs using travis-ci:

https://github.com/BPA-CSIRO-Workshops/handout-template/blob/master/developers/texlive_install.sh

The profile file is in the same directory.

-