I am asking mainly to be sure.

To describe it better, I want to use some external functionality that is available through a proprietary library. Since the library IS NOT compatible with GPL Programs, obviously I can't use it directly on the GPL Program.

I created a GPL-compatible license (MIT license) library that uses the proprietary library.

The GPL Program is having a version of this library WITHOUT the use of the proprietary library, the GPL Program can dynamically load a binary version of this library (.dll , .so through dlopen, LoadLibrary) and use it's implementation instead of the one that is included in the program.

Will I violate GPL if I distribute the binary library?

  • So, you created your own library (MIT licensed) that you are using instead of the proprietary library?
    – Brandin
    Jan 30, 2019 at 19:58
  • @Brandin Yeah, if the program fails to load any binary version of it then it will load it's own version of the library (that DOES NOT USES any proprietary library)
    – Mr. GK
    Jan 30, 2019 at 20:26
  • What are you planning to distribute - Are you going to distribute only your proprietary library (which does not contain any GPL code), or are you also distributing a GPL program with that?
    – Brandin
    Jan 31, 2019 at 7:31
  • @Brandin I'm already distributing the GPL program. And yes I am planning to distribute the binary library which is using a proprietary library (possibly as an optional plug-in)
    – Mr. GK
    Jan 31, 2019 at 9:51
  • Anyone ????????
    – Mr. GK
    Feb 7, 2019 at 15:17

1 Answer 1


IANAL/IANYL. That said, it seems to me that what you're doing is writing a proprietary plugin for a GPL program. It's a piece of proprietary code designed to slot into a GPL program, that may or may not get loaded at run-time. We can ignore the bit about the shim library being MIT-licensed on its own, because it's part of the work as distributed so must come under the GPL that covers the main work.

The FSF have already given their opinion on this practice. They say that

If the main program and the plugins are a single combined program then this means you must license the plug-in under the GPL or a GPL-compatible free software license and distribute it with source code in a GPL-compliant way.

Whether your plugin and the main program would form a single combined program depends, they say, on how tightly they communicate; that is, on the nature of the interface between main program and plugin. If you

establish intimate communication by sharing complex data structures, or shipping complex data structures back and forth, that can make them one single combined program

You haven't shown us your code, and in any case I'm not qualified to analyse it. But you should take a long, hard look at your plugin library, and be honest with yourself about how tightly it couples to the main program. Unless communication across the interface is "arm's-length", what you propose to do may well violate the GPL.

  • How it works: The Program is getting an object from the library and using it's functions which all of them are using standard types. The program doesn't share any complex data to the library (except the parameters for the functions). And the library is designed to work as a generic library (no dependence on the program that is loading it).
    – Mr. GK
    Feb 8, 2019 at 11:13
  • That isn't even close to enough detail for anyone else to make a call, and as I said, I'm not qualified to do it. The FSF's rule of thumb seems to be "if your library could do its job if called as a standalone binary, by fork-and-exec, then it's not tightly-coupled", in case that's any help.
    – MadHatter
    Feb 8, 2019 at 16:41
  • Thanks for the info. I marked your answer as valid??? (I'm quite new here)
    – Mr. GK
    Feb 8, 2019 at 20:53
  • @Mr.GK if you're happy with my answer, that is the right thing to do in terms of local etiquette, and thanks for doing it.
    – MadHatter
    Feb 8, 2019 at 20:58
  • That's interesting. The standalone binary scenario covers things like proprietary frontends for GPL CLI tools. But what if the other library doesn't offer a CLI at all? It could offer one, but it doesn't. If the proprietary library offered a CLI, it'd be easy to write a "frontend" library for it. Even the definition of "complex data structures" is up for grabs - one could argue that means anything more complex than a simple scalar value. Licensing can definitely be a hamster wheel of thought experiments sometimes.
    – fdmillion
    May 3, 2022 at 22:15

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.