2

I have been modifying an existing software (which was under the GPL licence). At my workplace, they needed to use the software, but needed some modifications (like new features, different structure, feature modification and removing unused functionalities).

I am about to finish this, but would not like to disrespect the original creator by not abiding the licence. I read several sources like the GPL licence official page, the software's official page and many others, to know what the licence asks from me.

However, I still have some unclear points, like:

  1. Should I inform the original creator of how I am using the program and of my modifications?
  2. In the licence included in the project, should I state the original source? Should I also make it visible so that any users know that this project was only modified by me?
  3. Should I leave all the original code (commented) so that it can be seen what I changed?
  4. I have to prepare a report stating what languages, libraries and frameworks were used and what does the project do. Should I acknowledge the creator here?

I really don't want to be dishonest, but one of my bosses asked me to modify an existing project to spare some time and to take advantage of professional coders with more experience than me. He asked me not to tell anybody about it. Another very important person in the company might be against it once he finds out. I do not want to lie and will clearly state the original owner for everyone to see, if that is required.

Also, whatever the case is, I do intend to credit the owner in the source code, so that at the very least, other programmers know the origin of the project. And if I am asked, I will not deny having modified an existing project. However, it would be really problematic acknowledging the owner for the public eye or in the reports handed to the project managers - especially since they did not even ask about it.

3

None of these things are necessary, but 1, 2 and maybe even 4 are probably good ideas. 3 probably not.


  1. Should I inform the original creator of how I am using the program and of my modifications?

There is definitely no obligation to do this, since the GPL does not allow such a requirement.

Whether or not you should is a more subjective thing, but unless your project is top secret military work I don't see any reason not to tell them. Creators usually benefit from knowing when their work was useful to someone, and knowing exactly which parts you felt the need to add, change or remove may be very useful information if and when they think about updating their program.


  1. In the licence included in the project, should I state the original source? Should I also make it visible so that any users know that this project was only modified by me?

Technically "the license" needs to be GPL (possibly alongside other licenses), and that means unmodified GPL, so definitely don't modify the license to state the original source.

You do need to state in a separate file (typically the readme) that all of this code is licensed under the GPL. There are also good reasons to state this in every single source file, even though that's not legally necessary.

I'm fairly sure you are not required to mention the original source of the code anywhere (see #1), but since you do have to state the code is GPL'd, you might as well mention the original source alongside that statement.


  1. Should I leave all the original code (commented) so that it can be seen what I changed?

I can't think of any reason this would be necessary, or desirable. Acknowledgement of the original source is sufficient for anyone who cares to work out what all the changes are. I'd suggest a few sentences in your readme summarizing the changes if you feel that's important information.

Leaving huge amounts of "dead code" around would also be a significant nuisance for anyone maintaining your modified version (including yourself), so I definitely wouldn't do this.


  1. I have to prepare a report stating what languages, libraries and frameworks were used and what does the project do. Should I acknowledge the creator here?

Again, there's no obligation to do this (see #1). Personally I'd include creators if it was a particularly long or detailed report, but normally I'd just name the libraries and link to their repos. Whether that information is appropriate for your report is something you'll have to decide (though I am curious why you think it would be "problematic" to do so).

1
  • 1
    Regarding #3: changes have to be visible in order to avoid end user confusion. However, a “prominent notice” is sufficient as explained in GPL v3.0 §5.a: “The work must carry prominent notices stating that you modified it, and giving a relevant date.
    – amon
    Feb 20 '16 at 14:22
0

I agree with everything that is said in Ixrec's answer. The point that I want to add is that commenting code out is almost always a bad idea. It makes the code less readable and neither the old, nor the new version is readily visible.

Instead, if you feel a need to make it crystal clear what you've changed, you can publish the original, unmodified, code alongside with a diff of your changes. The end user can then apply the patch (preferably via a Makefile you provide) . If a stable version of the original is readily available, you might even publish only the diff and ask your users to download the original sources. This might be of particular interest when your users will trust the original author more than you. They might want to review your diff (if it is relatively small) but not read all of the original code.

For example, if you're about to fix a really urgent issue in SQLite, you could publish just this.

sqlite3.diff

16918c16918
<   double r;
---
>   double r = NAN;  /* always initialize variables */
16923c16923
<   }else if( sqlite3StrICmp(zDate,"now")==0){
---
>   }else if( sqlite3StrICmp(zDate,"current")==0){

Makefile

sqlite3-new: sqlite3-new.c
    ${CC} -o $@ ${CPPFLAGS} ${CFLAGS} $< ${LIBS}

sqlite3-new.c: sqlite3.c sqlite3.diff
    patch -o $@ $^

sqlite3.c:
    wget 'https://www.sqlite.org/2016/sqlite-amalgamation-3110000.zip'
    unzip sqlite-amalgamation-3110000.zip
    cp sqlite-amalgamation-3110000/sqlite3.c $@

And make sqlite3-new will do the “right” thing.

(Please don't write build scripts that download random stuff from the internet without the user's consent and without even verifying the download in real life!)

1
  • "commenting code out is almost always a bad idea" is very, very true. There are a ridiculous number of tools you can use to help you find the differences, and the only thing it does is reduce the readability of the code.
    – Iker
    Feb 20 '16 at 18:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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