I know that according to GPLv2 if my non-GPL program links and calls internal functions of a GPL program, my own proprietary program must then be open-sourced (if it's distributed).
But suppose that there's an interpreted script program (e.g. in Python) that is a self-contained, non-binary executable, so I can execute the program like so:
./gplprogram.py --arg 4
That returns some output. Suppose that I want my non-GPL commercial program to use an internal function (i.e. it's not publically exposed) make_calc(value)
of gplprogram.py
without having to release my proprietary non-GPL program's source code.
What I do is modify gplprogram.py
to take a parameter --make_calc VALUE
that interfaces with the internal make_calc()
function.
The result is in my non-GPL program I can call the GPL program like so, and it will return value of make_calc()
:
./gplprogram.py --make_calc 99
This is not calling an internal routine. It's just calling the program and getting it's output, just like calling echo '2+2' | bc -l
in a non-GPL program and using the output wouldn't infect your program with the GPL.
Now I bundle my non-GPL program with the modified gplprogram.py
and distribute this to customers. Obviously I release the modified source code of gplprogram.py
under the GPL, but am I legally bound to release my proprietary program's source code? If I'm not bound, isn't this a kind of loop-hole?