Closed Bug 692281 Opened 13 years ago Closed 12 years ago

Re-license the core source map lib to BSD

Categories

(DevTools :: General, defect)

x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: fitzgen, Unassigned)

References

Details

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:9.0a2) Gecko/20111003 Firefox/9.0a2
Build ID: 20111003042017
This core lib was written to be used within Firefox internals, but also by compressors (like UglifyJS) and X-to-JS compilers (like CoffeeScript). However, many of these projects are MIT/BSD licensed, and the MPL tri-license scares them off (makes it impossible?) from incorporating this code in to their projects.

See also https://github.com/jashkenas/coffee-script/issues/558#issuecomment-2180204
See Also: → 669999
Yes, it would make it a lot messier for those projects. For reference, the source map feature is useless in Firefox unless tools like UglifyJS and CoffeeScript generate the necessary files.
Can someone quickly lay out the technical aspects of this? I thought source map was a format for storing the "real" line numbers for compressed or 'compiled' JS, not a codebase (although there might be a reference implementation)... What actual code are we hoping that other people will use directly?

Gerv
(In reply to Gervase Markham [:gerv] from comment #3)
> Can someone quickly lay out the technical aspects of this? I thought source
> map was a format for storing the "real" line numbers for compressed or
> 'compiled' JS, not a codebase (although there might be a reference
> implementation)... What actual code are we hoping that other people will use
> directly?

This bug is about relicensing the library for parsing and consuming that format. Check out the referenced bug 669999 in the See Also link.
But aren't UglifyJS and CoffeeScript generating the format, rather than parsing and consuming it?

Perhaps we need to have a chat with the decision-makers in this case, and make sure they understand the situation fully. After all, they can take the code under the MPL terms (so no worries about LGPL or GPL requirements affecting their codebases), just as they might take a library under Apache or under a different-number-of-clause BSD licence. 

Gerv
> This bug is about relicensing the library for parsing and consuming that format.

Actually, this core library both consumes *and* generates source maps. There is a bit of code that is shared between both the generation and consumption of source maps, mostly the base 64 stuff.

> But aren't UglifyJS and CoffeeScript generating the format, rather than parsing and consuming it?

Yes, but they would still use this core library unless they reimplemented everything which would be a huge act of wasted effort/duplication, in my opinion.

> Perhaps we need to have a chat with the decision-makers in this case, and make sure they understand the situation fully. After all, they can take the code under the MPL terms (so no worries about LGPL or GPL requirements affecting their codebases), just as they might take a library under Apache or under a different-number-of-clause BSD licence. 

This is a good idea. I don't know too much about licensing, just saw that there were concerns being raised about the difficulty of including our lib because of the licensing. (https://github.com/jashkenas/coffee-script/issues/558#issuecomment-2180204) My motivation is simply to get source maps adopted and put to use :)

_Nick_
Chiming in here -- it would be great to get the source-mapping stuff released under an MIT license (ideally) or a BSD license (would be fine). Anything more restrictive will probably prevent it from being integrated directly integrated with the CoffeeScript compiler.
We're using BSD for new projects like Rust, dom.js, pdf.js. I see no problem using it here.

/be
dcamp, can I ask you to review and merge the pull request for this bug?

https://github.com/mozilla/source-map/pull/2
As that pull req has landed I think we can FIXED this badboy.
Thanks Paul.
Status: UNCONFIRMED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.