You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@harmony.apache.org by Regis <xu...@gmail.com> on 2007/10/24 05:43:19 UTC

[OT] new tools for Harmony

Hi,

Recently I'm implementing LDAP filter and url parser, I use JavaCC[1] to 
generate parser's source code, the input
grammar files are written by myself. I'm not sure whether the generated 
source code could be included into Harmony
(only the source code, because it needn't JavaCC jars at compiling and 
runtime).

JavaCC is BSD licensed, it convert grammar file to java file, and 
according to it's FAQ[2], the java files produced by javacc
can be used in any way.

And javacc created java files with first line like this:
"/* Generated By:JavaCC: Do not edit this line. FilterParser.java */"

Is it acceptable?

[1] https://javacc.dev.java.net/
[2] http://www.engr.mun.ca/~theo/JavaCC-FAQ/javacc-faq-moz.htm#tth_sEc1.7

Best regards,
Regis.


Re: [OT] new tools for Harmony

Posted by Tim Ellison <t....@gmail.com>.
Alexei Zakharov wrote:
> Just FYI: we've already had a negative experience with parser
> generated by JavaCC - see [1]. However, in that case the problem was
> in the grammar itself since it was originally covered by LPGL.
> 
> As far as I understand in the current case Regis has created the
> grammar by himself so I don't see any problems.
> 
> [1] https://issues.apache.org/jira/browse/HARMONY-3898

Exactly.  The Java code is deemed to be a derivative of the grammar.  In
the case that Regis is proposing both will be ALv2.

Regards,
Tim


Re: [OT] new tools for Harmony

Posted by Alexei Zakharov <al...@gmail.com>.
Just FYI: we've already had a negative experience with parser
generated by JavaCC - see [1]. However, in that case the problem was
in the grammar itself since it was originally covered by LPGL.

As far as I understand in the current case Regis has created the
grammar by himself so I don't see any problems.

[1] https://issues.apache.org/jira/browse/HARMONY-3898

Thanks,
Alexei

2007/10/25, Spark Shen <sm...@gmail.com>:
> Thanks Alexei, for the information.
>
> I looked into the link, and noticed a paragraph:
> <cite>
> JavaCC is free. You can download it and use it in most situations at no
> cost. The files generated by JavaCC are yours which you use at your own
> risk. Sun and Metamata do not place any restrictions on what you can do with
> the generated files.
> </cite>
>
> According to these sentences, IMHO, whether to move or even remove the 'Do
> not move' instructions is at our choice. But if it is required for some
> technical reasons, for example, a tool will utilize that line, then it is
> better be kept.
>
> 2007/10/24, Alexei Fedotov <al...@gmail.com>:
> >
> > Hello,
> > I don't fully understand IP issues around javacc:
> >
> >    * The tool was initially developed by Sreeni while working for Sun.
> >    * Then Sreeni left the company and created Metamata, which worked
> > as caretaker for the tool and had a different license [2] than now.
> >
> > May be we should not be paranoid about it, but it worth to be mentioned.
> > [1] http://www.cs.purdue.edu/homes/hosking/352/javaccdocs/usage.html
> >
> >
> >
> > On 10/24/07, Tim Ellison <t....@gmail.com> wrote:
> > > Regis wrote:
> > > > Tim Ellison wrote:
> > > >> Regis wrote:
> > > >>> JavaCC is BSD licensed, it convert grammar file to java file, and
> > > >>> according to it's FAQ[2], the java files produced by javacc
> > > >>> can be used in any way.
> > > >>>
> > > >>> And javacc created java files with first line like this:
> > > >>> "/* Generated By:JavaCC: Do not edit this line. FilterParser.java*/"
> > > >>>
> > > >>> Is it acceptable?
> > > >>
> > > >> Yep.  Please ensure that you also contribute the grammar files that
> > you
> > > >> write as input to javacc.  Both the grammar files and the resulting
> > java
> > > >> files should have the ASF standard block comments at the top and be
> > > >> checked into SVN.  It's probably a good idea to also keep the 'Do not
> > > >> edit' instruction just so people know.
> > > >>
> > > > So we must move the 'Do not edit' instruction below the ASF standard
> > block
> > > > comments.
> > >
> > > It is not strictly necessary for the ASF comment to be the very first
> > > thing in the file, but given that it is first by convention I would say
> > > you should move the instruction below if it does not require a great
> > effort.
> > >
> > > > And I think we should add a additional 'README' file, give some
> > > > instruments about
> > > > how to use the grammar files and generated source files.
> > >
> > > Yes, instructions to make the process reproducible are important.
> > >
> > > Thanks,
> > > Tim
> > >

Re: [OT] new tools for Harmony

Posted by Spark Shen <sm...@gmail.com>.
Anyhow, I think we are assured that we can use the grammer file and the
generated parser contributed by rigis.

2007/10/25, Alexei Fedotov <al...@gmail.com>:
>
> Spark,
> I pay attention to things created by my imagination behind the words,
> and this is what I call paranoia. :-)
>
> The Sun is no longer mentioned as JavaCC author [1]. This means that
> people around JavaCC are very flexible when talk about copyright. They
> might be no less flexible when stated these "free" and "caretaker"
> rights on the web page.
>
> In other words, I don't know if Sun really thinks that this tool is
> free. The truth is that is written on some web page with is not
> affiliated with Sun.
>
> [1] https://javacc.dev.java.net/
>
>
> On 10/25/07, Spark Shen <sm...@gmail.com> wrote:
> > Thanks Alexei, for the information.
> >
> > I looked into the link, and noticed a paragraph:
> > <cite>
> > JavaCC is free. You can download it and use it in most situations at no
> > cost. The files generated by JavaCC are yours which you use at your own
> > risk. Sun and Metamata do not place any restrictions on what you can do
> with
> > the generated files.
> > </cite>
> >
> > According to these sentences, IMHO, whether to move or even remove the
> 'Do
> > not move' instructions is at our choice. But if it is required for some
> > technical reasons, for example, a tool will utilize that line, then it
> is
> > better be kept.
> >
> > 2007/10/24, Alexei Fedotov <al...@gmail.com>:
> > >
> > > Hello,
> > > I don't fully understand IP issues around javacc:
> > >
> > >    * The tool was initially developed by Sreeni while working for Sun.
> > >    * Then Sreeni left the company and created Metamata, which worked
> > > as caretaker for the tool and had a different license [2] than now.
> > >
> > > May be we should not be paranoid about it, but it worth to be
> mentioned.
> > > [1] http://www.cs.purdue.edu/homes/hosking/352/javaccdocs/usage.html
> > >
> > >
> > >
> > > On 10/24/07, Tim Ellison <t....@gmail.com> wrote:
> > > > Regis wrote:
> > > > > Tim Ellison wrote:
> > > > >> Regis wrote:
> > > > >>> JavaCC is BSD licensed, it convert grammar file to java file,
> and
> > > > >>> according to it's FAQ[2], the java files produced by javacc
> > > > >>> can be used in any way.
> > > > >>>
> > > > >>> And javacc created java files with first line like this:
> > > > >>> "/* Generated By:JavaCC: Do not edit this line.
> FilterParser.java*/"
> > > > >>>
> > > > >>> Is it acceptable?
> > > > >>
> > > > >> Yep.  Please ensure that you also contribute the grammar files
> that
> > > you
> > > > >> write as input to javacc.  Both the grammar files and the
> resulting
> > > java
> > > > >> files should have the ASF standard block comments at the top and
> be
> > > > >> checked into SVN.  It's probably a good idea to also keep the 'Do
> not
> > > > >> edit' instruction just so people know.
> > > > >>
> > > > > So we must move the 'Do not edit' instruction below the ASF
> standard
> > > block
> > > > > comments.
> > > >
> > > > It is not strictly necessary for the ASF comment to be the very
> first
> > > > thing in the file, but given that it is first by convention I would
> say
> > > > you should move the instruction below if it does not require a great
> > > effort.
> > > >
> > > > > And I think we should add a additional 'README' file, give some
> > > > > instruments about
> > > > > how to use the grammar files and generated source files.
> > > >
> > > > Yes, instructions to make the process reproducible are important.
> > > >
> > > > Thanks,
> > > > Tim
> > > >
> > >
> > >
> > > --
> > > With best regards,
> > > Alexei,
> > > ESSD, Intel
> > >
> >
> >
> >
> > --
> > Spark Shen
> > China Software Development Lab, IBM
> >
>
>
> --
> With best regards,
> Alexei,
> ESSD, Intel
>



-- 
Spark Shen
China Software Development Lab, IBM

Re: [OT] new tools for Harmony

Posted by Alexei Fedotov <al...@gmail.com>.
Spark,
I pay attention to things created by my imagination behind the words,
and this is what I call paranoia. :-)

The Sun is no longer mentioned as JavaCC author [1]. This means that
people around JavaCC are very flexible when talk about copyright. They
might be no less flexible when stated these "free" and "caretaker"
rights on the web page.

In other words, I don't know if Sun really thinks that this tool is
free. The truth is that is written on some web page with is not
affiliated with Sun.

[1] https://javacc.dev.java.net/


On 10/25/07, Spark Shen <sm...@gmail.com> wrote:
> Thanks Alexei, for the information.
>
> I looked into the link, and noticed a paragraph:
> <cite>
> JavaCC is free. You can download it and use it in most situations at no
> cost. The files generated by JavaCC are yours which you use at your own
> risk. Sun and Metamata do not place any restrictions on what you can do with
> the generated files.
> </cite>
>
> According to these sentences, IMHO, whether to move or even remove the 'Do
> not move' instructions is at our choice. But if it is required for some
> technical reasons, for example, a tool will utilize that line, then it is
> better be kept.
>
> 2007/10/24, Alexei Fedotov <al...@gmail.com>:
> >
> > Hello,
> > I don't fully understand IP issues around javacc:
> >
> >    * The tool was initially developed by Sreeni while working for Sun.
> >    * Then Sreeni left the company and created Metamata, which worked
> > as caretaker for the tool and had a different license [2] than now.
> >
> > May be we should not be paranoid about it, but it worth to be mentioned.
> > [1] http://www.cs.purdue.edu/homes/hosking/352/javaccdocs/usage.html
> >
> >
> >
> > On 10/24/07, Tim Ellison <t....@gmail.com> wrote:
> > > Regis wrote:
> > > > Tim Ellison wrote:
> > > >> Regis wrote:
> > > >>> JavaCC is BSD licensed, it convert grammar file to java file, and
> > > >>> according to it's FAQ[2], the java files produced by javacc
> > > >>> can be used in any way.
> > > >>>
> > > >>> And javacc created java files with first line like this:
> > > >>> "/* Generated By:JavaCC: Do not edit this line. FilterParser.java*/"
> > > >>>
> > > >>> Is it acceptable?
> > > >>
> > > >> Yep.  Please ensure that you also contribute the grammar files that
> > you
> > > >> write as input to javacc.  Both the grammar files and the resulting
> > java
> > > >> files should have the ASF standard block comments at the top and be
> > > >> checked into SVN.  It's probably a good idea to also keep the 'Do not
> > > >> edit' instruction just so people know.
> > > >>
> > > > So we must move the 'Do not edit' instruction below the ASF standard
> > block
> > > > comments.
> > >
> > > It is not strictly necessary for the ASF comment to be the very first
> > > thing in the file, but given that it is first by convention I would say
> > > you should move the instruction below if it does not require a great
> > effort.
> > >
> > > > And I think we should add a additional 'README' file, give some
> > > > instruments about
> > > > how to use the grammar files and generated source files.
> > >
> > > Yes, instructions to make the process reproducible are important.
> > >
> > > Thanks,
> > > Tim
> > >
> >
> >
> > --
> > With best regards,
> > Alexei,
> > ESSD, Intel
> >
>
>
>
> --
> Spark Shen
> China Software Development Lab, IBM
>


-- 
With best regards,
Alexei,
ESSD, Intel

Re: [OT] new tools for Harmony

Posted by Spark Shen <sm...@gmail.com>.
Thanks Alexei, for the information.

I looked into the link, and noticed a paragraph:
<cite>
JavaCC is free. You can download it and use it in most situations at no
cost. The files generated by JavaCC are yours which you use at your own
risk. Sun and Metamata do not place any restrictions on what you can do with
the generated files.
</cite>

According to these sentences, IMHO, whether to move or even remove the 'Do
not move' instructions is at our choice. But if it is required for some
technical reasons, for example, a tool will utilize that line, then it is
better be kept.

2007/10/24, Alexei Fedotov <al...@gmail.com>:
>
> Hello,
> I don't fully understand IP issues around javacc:
>
>    * The tool was initially developed by Sreeni while working for Sun.
>    * Then Sreeni left the company and created Metamata, which worked
> as caretaker for the tool and had a different license [2] than now.
>
> May be we should not be paranoid about it, but it worth to be mentioned.
> [1] http://www.cs.purdue.edu/homes/hosking/352/javaccdocs/usage.html
>
>
>
> On 10/24/07, Tim Ellison <t....@gmail.com> wrote:
> > Regis wrote:
> > > Tim Ellison wrote:
> > >> Regis wrote:
> > >>> JavaCC is BSD licensed, it convert grammar file to java file, and
> > >>> according to it's FAQ[2], the java files produced by javacc
> > >>> can be used in any way.
> > >>>
> > >>> And javacc created java files with first line like this:
> > >>> "/* Generated By:JavaCC: Do not edit this line. FilterParser.java*/"
> > >>>
> > >>> Is it acceptable?
> > >>
> > >> Yep.  Please ensure that you also contribute the grammar files that
> you
> > >> write as input to javacc.  Both the grammar files and the resulting
> java
> > >> files should have the ASF standard block comments at the top and be
> > >> checked into SVN.  It's probably a good idea to also keep the 'Do not
> > >> edit' instruction just so people know.
> > >>
> > > So we must move the 'Do not edit' instruction below the ASF standard
> block
> > > comments.
> >
> > It is not strictly necessary for the ASF comment to be the very first
> > thing in the file, but given that it is first by convention I would say
> > you should move the instruction below if it does not require a great
> effort.
> >
> > > And I think we should add a additional 'README' file, give some
> > > instruments about
> > > how to use the grammar files and generated source files.
> >
> > Yes, instructions to make the process reproducible are important.
> >
> > Thanks,
> > Tim
> >
>
>
> --
> With best regards,
> Alexei,
> ESSD, Intel
>



-- 
Spark Shen
China Software Development Lab, IBM

Re: [OT] new tools for Harmony

Posted by Alexei Fedotov <al...@gmail.com>.
Hello,
I don't fully understand IP issues around javacc:

   * The tool was initially developed by Sreeni while working for Sun.
   * Then Sreeni left the company and created Metamata, which worked
as caretaker for the tool and had a different license [2] than now.

May be we should not be paranoid about it, but it worth to be mentioned.
[1] http://www.cs.purdue.edu/homes/hosking/352/javaccdocs/usage.html



On 10/24/07, Tim Ellison <t....@gmail.com> wrote:
> Regis wrote:
> > Tim Ellison wrote:
> >> Regis wrote:
> >>> JavaCC is BSD licensed, it convert grammar file to java file, and
> >>> according to it's FAQ[2], the java files produced by javacc
> >>> can be used in any way.
> >>>
> >>> And javacc created java files with first line like this:
> >>> "/* Generated By:JavaCC: Do not edit this line. FilterParser.java */"
> >>>
> >>> Is it acceptable?
> >>
> >> Yep.  Please ensure that you also contribute the grammar files that you
> >> write as input to javacc.  Both the grammar files and the resulting java
> >> files should have the ASF standard block comments at the top and be
> >> checked into SVN.  It's probably a good idea to also keep the 'Do not
> >> edit' instruction just so people know.
> >>
> > So we must move the 'Do not edit' instruction below the ASF standard block
> > comments.
>
> It is not strictly necessary for the ASF comment to be the very first
> thing in the file, but given that it is first by convention I would say
> you should move the instruction below if it does not require a great effort.
>
> > And I think we should add a additional 'README' file, give some
> > instruments about
> > how to use the grammar files and generated source files.
>
> Yes, instructions to make the process reproducible are important.
>
> Thanks,
> Tim
>


-- 
With best regards,
Alexei,
ESSD, Intel

Re: [OT] new tools for Harmony

Posted by Tim Ellison <t....@gmail.com>.
Regis wrote:
> Tim Ellison wrote:
>> Regis wrote:
>>> JavaCC is BSD licensed, it convert grammar file to java file, and
>>> according to it's FAQ[2], the java files produced by javacc
>>> can be used in any way.
>>>
>>> And javacc created java files with first line like this:
>>> "/* Generated By:JavaCC: Do not edit this line. FilterParser.java */"
>>>
>>> Is it acceptable?
>>
>> Yep.  Please ensure that you also contribute the grammar files that you
>> write as input to javacc.  Both the grammar files and the resulting java
>> files should have the ASF standard block comments at the top and be
>> checked into SVN.  It's probably a good idea to also keep the 'Do not
>> edit' instruction just so people know.
>>
> So we must move the 'Do not edit' instruction below the ASF standard block
> comments.

It is not strictly necessary for the ASF comment to be the very first
thing in the file, but given that it is first by convention I would say
you should move the instruction below if it does not require a great effort.

> And I think we should add a additional 'README' file, give some
> instruments about
> how to use the grammar files and generated source files.

Yes, instructions to make the process reproducible are important.

Thanks,
Tim

Re: [OT] new tools for Harmony

Posted by Regis <xu...@gmail.com>.

Tim Ellison wrote:
> this is quite 'on topic' I would think...<shrug>
> 
> (more below)
> 
> Regis wrote:
>> Recently I'm implementing LDAP filter and url parser, I use JavaCC[1] to
>> generate parser's source code, the input
>> grammar files are written by myself. I'm not sure whether the generated
>> source code could be included into Harmony
>> (only the source code, because it needn't JavaCC jars at compiling and
>> runtime).
> 
> Yes it can.
Great!!
> 
>> JavaCC is BSD licensed, it convert grammar file to java file, and
>> according to it's FAQ[2], the java files produced by javacc
>> can be used in any way.
>>
>> And javacc created java files with first line like this:
>> "/* Generated By:JavaCC: Do not edit this line. FilterParser.java */"
>>
>> Is it acceptable?
> 
> Yep.  Please ensure that you also contribute the grammar files that you
> write as input to javacc.  Both the grammar files and the resulting java
> files should have the ASF standard block comments at the top and be
> checked into SVN.  It's probably a good idea to also keep the 'Do not
> edit' instruction just so people know.
> 
So we must move the 'Do not edit' instruction below the ASF standard block
comments.

And I think we should add a additional 'README' file, give some 
instruments about
how to use the grammar files and generated source files.

> Regards,
> Tim
> 
>> [1] https://javacc.dev.java.net/
>> [2] http://www.engr.mun.ca/~theo/JavaCC-FAQ/javacc-faq-moz.htm#tth_sEc1.7
>>
>> Best regards,
>> Regis.
>>
>>
> 

Re: [OT] new tools for Harmony

Posted by Tim Ellison <t....@gmail.com>.
this is quite 'on topic' I would think...<shrug>

(more below)

Regis wrote:
> Recently I'm implementing LDAP filter and url parser, I use JavaCC[1] to
> generate parser's source code, the input
> grammar files are written by myself. I'm not sure whether the generated
> source code could be included into Harmony
> (only the source code, because it needn't JavaCC jars at compiling and
> runtime).

Yes it can.

> JavaCC is BSD licensed, it convert grammar file to java file, and
> according to it's FAQ[2], the java files produced by javacc
> can be used in any way.
> 
> And javacc created java files with first line like this:
> "/* Generated By:JavaCC: Do not edit this line. FilterParser.java */"
> 
> Is it acceptable?

Yep.  Please ensure that you also contribute the grammar files that you
write as input to javacc.  Both the grammar files and the resulting java
files should have the ASF standard block comments at the top and be
checked into SVN.  It's probably a good idea to also keep the 'Do not
edit' instruction just so people know.

Regards,
Tim

> [1] https://javacc.dev.java.net/
> [2] http://www.engr.mun.ca/~theo/JavaCC-FAQ/javacc-faq-moz.htm#tth_sEc1.7
> 
> Best regards,
> Regis.
> 
>