2

I want to use ptrace APIs in proprietary code. If I use them must I license my program as GPL? I could not find exact answer for this.

I searched for libraries and applications that use the ptrace APIs and found that they are GPL. But some libraries written in rust are MIT. This is confusing for me. I want to get a definitive answer.

1
  • 1
    Note that Linux, although GPL, also includes the so-called "syscall exception" in its license which explicitly says that using the system calls in user code does not produce a derivative work. See also: opensource.stackexchange.com/questions/10223/…
    – Brandin
    Commented Jan 17 at 13:54

1 Answer 1

3

APIs themselves are (probably) not copyrightable and thus copyright licenses do not apply to them. In the particular case of ptrace, it is a "generic" API shared between various OSes so it would be very hard for anybody to actually claim copyright on it.

User-space libraries which happen to make calls to the ptrace API can be under any license they want to be, and therefore if you are using them you must obey their licensing conditions.

So the answer to your question as written is "no, your program does not have to be under the GPL if all you are using are the OS-supplied ptrace APIs". However, it sounds like you may be trying to use libraries which wrap the ptrace APIs, which is a different question.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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