Board index

PCGen


IT IS ALIVE!!!

Question on usage of PCGen code

Where new users can post questions about PCGen, or report possible issues (bug tracking is by Jira - jira.pcgen.org)

Question on usage of PCGen code

Postby MaxEd » Sun Dec 31, 2017 2:31 pm

Hello. I'm developing an app for tabletop RPG players on mobile devices. I would like the users of my app to be able to export their characters to other tools, and also I'd like to provide the ability to create and level up characters within the app (using available content like SRD).

I'm considering several options to make it all work, but one idea I like is to use PCGen format for storing both characters and system data. A lot of other tools can import characters from PCGen, which would allow one- or two-step import from my app (worst case: load up character in PCGen, export to XML, import to other tool, best case: just import character file directly). As for the system data, I just would like to use PCGen LST files to avoid coming up with my own way to store it and re-digitising all of the content.

However, PCGen file format is quite complex, especially for LST files. That got me thinking that maybe I could reuse some part of PCGen code for handling them, as well as for actual level-up operations. There are some technical problems to overcome, as my app is written in C++, and PCGen in Java, but I think I might be able to handle them. However, I'm interested in the legal aspect.

First, PCGen source code is licensed under LGPL. It seems a bit strange to me, because LGPL is designed to be applied to libraries, while PCGen is a complete application. I'd like to clarify this point: why was LGPL chosen, and could it really apply here?

Second, I see that PCGen Wiki lists (http://wiki.pcgen.org/Compatible_3rd_Parties) several apps that "rely directly on or use converted forms of PCGen code and/or data and/or outputsheets and/or character files" which "have our full blessing and are Officially PCGen compatible". What are the requirements to get onto this list? Does the app have to be open-source/GPL licensed? Is there anything else my app would have to comply with?

One big question is the usage of LGPL-licensed code on iOS. I'm planning on exploring a possibility to run PCGen Java code on it using one of the 3rd-party Java machines, like Intel Multi-Os Engine or Avian, or the free fork of RoboVM and interact with the Java code using JNI. It's not clear to me whether this usage would satisfy "dynamic linking" option of LGPL for closed-source apps (probably not, because one cannot replace the compiled jar file inside the IPA archive), or even requirements for open-source apps.

So anyway, I'm looking for clarifications/suggestions here. Or maybe I should abandon this idea altogether?
User avatar
MaxEd
 
Posts: 3
Joined: Sun Dec 31, 2017 2:10 pm

Re: Question on usage of PCGen code

Postby LegacyKing » Sun Dec 31, 2017 8:12 pm

Hi,

Most of the folks who can answer the more technical questions are not active with the project, so I will do my best to answer:

1) I don't know why they used the more restricted License, I think it had to do with the libraries we were relying on.
2) As long as you attribute the work to the volunteers of pcgen (i.e. give credit where credit is due) then you are given the blessings to re-use the code as you desire (As per the Open Source guidelines)

Question: Why C++ and not C#? Some of the team were discussing the possibility of having to redo pcgen in a C# program (Since most of our experienced Java veterans have departed), and C# seems to be an upcoming equivalent cross-platform language.

3) Legally - Open Source allows for code re-use and attribution, it doesn't bind you to be free if that is your concern. I'm not sure about the rest, as I am not a license expert.


Andrew Maitland
PCGen Content SB
- Data Chimp
- Quicksilver Tracker Monkey
User avatar
LegacyKing
Site Admin
 
Posts: 762
Joined: Fri Oct 11, 2013 12:35 pm
Location: California, US

Re: Question on usage of PCGen code

Postby MaxEd » Sun Dec 31, 2017 9:30 pm

1) I don't know why they used the more restricted License, I think it had to do with the libraries we were relying on.


Actually, LGPL is less restricted than GPL, but I'm not sure how is it possible to apply it to a non-library. But I guess that'll have to remain a mystery for now :)

Question: Why C++ and not C#? Some of the team were discussing the possibility of having to redo pcgen in a C# program (Since most of our experienced Java veterans have departed), and C# seems to be an upcoming equivalent cross-platform language.


I have 11 years of experience with C++ in game development, a ready-made cross-platform OpenGL engine and UI library and a number of other helper classes and libraries from my day work that I'm allowed to use in pet projects. C# is an OK choice, but personally, I'd go with C++ and cross-platform UI library like Qt. My reasoning is that C++ code, ultimately, can be compiled for any platform with some effort, while C# requires a .Net runtime (official or Mono) on the platform, which is not always possible (for example on iOS: even Unity compiles C# code to C++ using Il2Cpp on this platform).Then again, with C# it would be easier to find new programmers: with Unity engine ascendant, there is no shortage of them.

3) Legally - Open Source allows for code re-use and attribution, it doesn't bind you to be free if that is your concern. I'm not sure about the rest, as I am not a license expert.


Things are not that simple. GPL license requires any derivative work (i.e. work that uses GPL'ed code) to be also licensed under GLP, which means it should be open-source. LGPL is less restrictive: it allows some exceptions, where open-source code can be used along with the closed-source, but those exceptions are limited (the license is written mostly with native code in mind, and therefore makes exception for "dynamic linking" LGPL'ed library to closed-source code in such way that open-source library could later be replaced by user; in this light, JAR with Java bytecode could possible be viewed as such "dynamic library" (though it's not, strictly speaking)).

But I understand that licensing status of PCGen is questionable, with old developers missing, so I will proceed, but with caution. I'll speak to the other member of my team, and we will decide if we can make our app open-source, in which case we should be able to use PCGen without troubles.
User avatar
MaxEd
 
Posts: 3
Joined: Sun Dec 31, 2017 2:10 pm
Top

Re: Question on usage of PCGen code

Postby LegacyKing » Sun Dec 31, 2017 9:52 pm

Interesting. That's why I use the disclaimer that I'm not the expert.

So.... :) Wanna help improve PCGen?

If you have some free time, join me over on hipchat and we can discuss further.

There are multiple points of PCGen that could use a fresh pair of eyes and refactoring - https://www.hipchat.com/gmddByrFS


Andrew Maitland
PCGen Content SB
- Data Chimp
- Quicksilver Tracker Monkey
User avatar
LegacyKing
Site Admin
 
Posts: 762
Joined: Fri Oct 11, 2013 12:35 pm
Location: California, US
Top

Re: Question on usage of PCGen code

Postby MaxEd » Sun Dec 31, 2017 10:09 pm

Sorry, we're celebrating the New Year over here right now :) And I probably won't be of much use to PCGen in it's current state: I don't much about Java beside the fact that I dislike it a lot (due to my work with Android apps). But if I try to use PCGen code in my app, I'll probably have to dig into the code, and then maybe I'll have some ideas or suggestions, or even patches. But it will come later.
User avatar
MaxEd
 
Posts: 3
Joined: Sun Dec 31, 2017 2:10 pm
Top


Return to Questions & Issues

Who is online

Users browsing this forum: No registered users and 2 guests