Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I would like to be able to generate a (dynamic) report automatically using TeX. My proposed solution is simple: A user clicks a button and

  1. The apropriate TeX code is generated (on runtime) and saved on disk.
  2. The program calls pdflatex.exe to compile the .tex file to PDF.

My question is regarding step 2. Is it legal to call pdflatex.exe from within my code while preserving the copy right of my code?

In my current solution, I have stripped a portable MiKTeX distribution to ~ 30 MB, which I would like to distribute along with my own code (of course mentioning MiKTeX and linking to the source code). Would this be okay?

If it all ends ups being profitable, I will of course donate a substantial amount to MiKTeX (or should I donate elsewhere?), but I guess this doesn't really make any difference.

Willie - You certainly have a good point. However, the solution has to be a "one-click-installation" and just specifying that a TeX distrubution is needed is not an option - unfortunately. Distributing an original MikTeX distrubutin isn't either, as the space limit is ~50 mb.

share|improve this question
You retain copyright of anything produced with LaTeX. I don't know what restrictions there would be on releasing your code that calls LaTeX, but the reports produced by the code would certainly still belong to you. –  Seamus Jun 15 '12 at 10:39
For which county or countries are you asking? –  Keks Dose Jun 15 '12 at 12:21
Welcome to TeX.sx! Usually, we don't put a greeting or a "thank you" in our posts. While this might seem strange at first, it is not a sign of lack of politeness, but rather part of our trying to keep everything very concise. Upvoting is the preferred way here to say "thank you" to users who helped you. –  doncherry Jun 15 '12 at 12:33
Rather than bundling and distributing some tex distribution, why not just specify to the potential users that s/he must also install a TeX distribution? Making a system call to an executable which may or may not be on a user's system is certainly not your problem; distributing a stripped down version of MikTeX is. –  Willie Wong Jun 15 '12 at 15:25
If you are in the US or Canada, there might be a fairly inexpensive method to get some basic info. Email me if that is the case (I have no financial interest in this). –  Peter Grill Jun 16 '12 at 20:37
add comment

2 Answers

Distributing a modified version of MiKTeX Portable might be a problem. Please check the MiKTeX Copying Conditions page or contact Christian Schenk as recommended on that page.

share|improve this answer
add comment

Too long to be a comment:

I am not a lawyer, but can't see how there would be any problem in your software calling another executable. Since it is your s/w that produces the .tex code, the copyright/ownership of that specific formatting of the .tex code would be subject to how you licensed your original software. Of course, I assume that the customer would retain copyright of the final output and you would have no ownership to that.

This also assumes that your .tex files have non-trivial content. So for instance, if the customer provided John Smith and your entire .tex file consisted of \textbf{John Smith} (with a minimal preamble to make it compilable), that would not mean that no on else can generate a file that also produces \textbf{}. I forget the legal term for this.

Think of a user using Word, they edit the file and Word saves it on disk. This format is copyright by Microsoft and you would probably need a license to generate the exact same format (unless Microsoft specifically stated otherwise). But that does not prevent other programs from reading the Word format. When the user goes to print it, Word invokes the printer's driver (not Microsoft's) in order to print it. This is similar to your s/w using pdflatex to generate the pdf file.

Note that this in no way addresses the issue of you distributing a modified version of MiKTeX as that is a totally separate issue.

share|improve this answer
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.