[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: gnulib-tool --lgpl doesn't convert gplv3 to lgplv2.1
From: |
Bruno Haible |
Subject: |
Re: gnulib-tool --lgpl doesn't convert gplv3 to lgplv2.1 |
Date: |
Sun, 28 Oct 2007 23:25:47 +0100 |
User-agent: |
KMail/1.5.4 |
Simon Josefsson wrote:
> > The complexity of distributing a library under one license and the
> > corresponding tools under another license is very manageable. I do this
> > for libiconv and gettext. You distribute both COPYINGv2 and COPYINGv3, and
> > add a statement to the README, saying that the library is under GPLv2 and
> > the tools are under GPLv3.
>
> Ok. I think that would solve all of the problems.
> ...
> by using a COPYINGv2+COPYINGv3, I believe I don't need any
> gnulib modules under GPLv2.
Good. So let's handle only --lgpl at this point.
> > Yes, GPLv3 (at least until Brett and Paul have finished discussing the issue
> > that Brett has with it).
>
> Is there any point in patching files to say GPLv3 consistency until the
> discussion has finished?
Doing one thing at a time is often simpler.
I'm applying this:
2007-10-28 Bruno Haible <address@hidden>
* gnulib-tool: Allow specifying the LGPL version number through
--lgpl=2 or --lgpl=3.
(func_usage): Document --lgpl with argument.
Handle --lgpl=... arguments.
(func_import): Recognize also gl_LGPL calls with an argument. When
--lgpl=2 is used and the module's license is just LGPL, report an
error. Set sed_transform_lib_file according to the lgpl variable. In
the generated files, use --lgpl or gl_LGPL invocations with argument,
if necessary.
* doc/gnulib-intro.texi (Copyright): Explain how to get modules under
an LGPv2+ license.
* doc/gnulib-tool.texi (Modified imports): Update explanation of
gl_LGPL macro.
*** doc/gnulib-intro.texi.orig 2007-10-28 23:23:25.000000000 +0100
--- doc/gnulib-intro.texi 2007-10-28 23:17:59.000000000 +0100
***************
*** 262,268 ****
If you want to use some Gnulib modules under LGPL, you can do so by
passing the option @samp{--lgpl} to @code{gnulib-tool}. This will
replace the GPL header with an LGPL header while copying the source
! files to your package.
Keep in mind that when you submit patches to files in Gnulib, you should
license them under a compatible license. This means that sometimes the
--- 262,270 ----
If you want to use some Gnulib modules under LGPL, you can do so by
passing the option @samp{--lgpl} to @code{gnulib-tool}. This will
replace the GPL header with an LGPL header while copying the source
! files to your package. Similarly, if you want some Gnulib modules
! under LGPLv2+ (Lesser GPL version 2.1 or newer), you can do so by
! passing the option @samp{--lgpl=2} to @code{gnulib-tool}.
Keep in mind that when you submit patches to files in Gnulib, you should
license them under a compatible license. This means that sometimes the
*** doc/gnulib-tool.texi.orig 2007-10-28 23:23:25.000000000 +0100
--- doc/gnulib-tool.texi 2007-10-28 23:20:14.000000000 +0100
***************
*** 310,317 ****
@samp{--lib} command line argument.
@item gl_LGPL
! The presence of this macro corresponds to the @samp{--lgpl} command line
! argument. It takes no arguments.
@item gl_LIBTOOL
The presence of this macro corresponds to the @samp{--libtool} command line
--- 310,319 ----
@samp{--lib} command line argument.
@item gl_LGPL
! The presence of this macro without arguments corresponds to the @samp{--lgpl}
! command line argument. The presence of this macro with an argument (whose
! value must be 2 or 3) corresponds to the @address@hidden command line
! argument.
@item gl_LIBTOOL
The presence of this macro corresponds to the @samp{--libtool} command line
*** gnulib-tool.orig 2007-10-28 23:23:25.000000000 +0100
--- gnulib-tool 2007-10-28 23:05:22.000000000 +0100
***************
*** 169,176 ****
--avoid=MODULE Avoid including the given MODULE. Useful if you
have code that provides equivalent functionality.
This option can be repeated.
! --lgpl Abort if modules aren't available under the LGPL.
Also modify license template from GPL to LGPL.
--makefile-name=NAME Name of makefile in automake syntax in the
source-base and tests-base directories
(default \"Makefile.am\").
--- 169,178 ----
--avoid=MODULE Avoid including the given MODULE. Useful if you
have code that provides equivalent functionality.
This option can be repeated.
! --lgpl[=2|=3] Abort if modules aren't available under the LGPL.
Also modify license template from GPL to LGPL.
+ The version number of the LGPL can be specified;
+ the default is currently LGPLv3.
--makefile-name=NAME Name of makefile in automake syntax in the
source-base and tests-base directories
(default \"Makefile.am\").
***************
*** 594,600 ****
# - auxdir from --aux-dir
# - inctests true if --with-tests was given, blank otherwise
# - avoidlist list of modules to avoid, from --avoid
! # - lgpl true if --lgpl was given, blank otherwise
# - makefile_name from --makefile-name
# - libtool true if --libtool was given, false if --no-libtool was
# given, blank otherwise
--- 596,602 ----
# - auxdir from --aux-dir
# - inctests true if --with-tests was given, blank otherwise
# - avoidlist list of modules to avoid, from --avoid
! # - lgpl yes or a number if --lgpl was given, blank otherwise
# - makefile_name from --makefile-name
# - libtool true if --libtool was given, false if --no-libtool was
# given, blank otherwise
***************
*** 774,780 ****
func_append avoidlist " $arg"
shift ;;
--lgpl )
! lgpl=true
shift ;;
--makefile-name )
shift
--- 776,790 ----
func_append avoidlist " $arg"
shift ;;
--lgpl )
! lgpl=yes
! shift ;;
! --lgpl=* )
! arg=`echo "X$1" | sed -e 's/^X--lgpl=//'`
! case "$arg" in
! 2 | 3) ;;
! *) func_fatal_error "invalid LGPL version number for --lgpl" ;;
! esac
! lgpl=$arg
shift ;;
--makefile-name )
shift
***************
*** 1990,1996 ****
# - auxdir directory relative to destdir where to place build aux
files
# - inctests true if --with-tests was given, blank otherwise
# - avoidlist list of modules to avoid, from --avoid
! # - lgpl true if library's license shall be LGPL, blank otherwise
# - makefile_name from --makefile-name
# - libtool true if --libtool was given, false if --no-libtool was
# given, blank otherwise
--- 2000,2007 ----
# - auxdir directory relative to destdir where to place build aux
files
# - inctests true if --with-tests was given, blank otherwise
# - avoidlist list of modules to avoid, from --avoid
! # - lgpl yes or a number if library's license shall be LGPL,
! # blank otherwise
# - makefile_name from --makefile-name
# - libtool true if --libtool was given, false if --no-libtool was
# given, blank otherwise
***************
*** 2059,2066 ****
/gl_LIB(/ {
s,^.*gl_LIB([[ ]*\([^])]*\).*$,cached_libname="\1",p
}
/gl_LGPL/ {
! s,^.*$,cached_lgpl=true,p
}
/gl_MAKEFILE_NAME(/ {
s,^.*gl_MAKEFILE_NAME([[ ]*\([^])]*\).*$,cached_makefile_name="\1",p
--- 2070,2080 ----
/gl_LIB(/ {
s,^.*gl_LIB([[ ]*\([^])]*\).*$,cached_libname="\1",p
}
+ /gl_LGPL(/ {
+ s,^.*gl_LGPL([[ ]*\([^])]*\).*$,cached_lgpl="\1",p
+ }
/gl_LGPL/ {
! s,^.*$,cached_lgpl=yes,p
}
/gl_MAKEFILE_NAME(/ {
s,^.*gl_MAKEFILE_NAME([[ ]*\([^])]*\).*$,cached_makefile_name="\1",p
***************
*** 2211,2219 ****
for module in $modules; do
license=`func_get_license $module`
case $license in
! LGPL | LGPLv2+ | 'GPLed build tool') ;;
'public domain' | 'unlimited' | 'unmodifiable license text') ;;
! *) func_fatal_error "incompatible license on module $module:
$license" ;;
esac
done
fi
--- 2225,2249 ----
for module in $modules; do
license=`func_get_license $module`
case $license in
! 'GPLed build tool') ;;
'public domain' | 'unlimited' | 'unmodifiable license text') ;;
! *)
! case "$lgpl" in
! yes | 3)
! case $license in
! LGPL | LGPLv2+) ;;
! *) func_fatal_error "incompatible license on module $module:
$license" ;;
! esac
! ;;
! 2)
! case $license in
! LGPLv2+) ;;
! *) func_fatal_error "incompatible license on module $module:
$license" ;;
! esac
! ;;
! *) func_fatal_error "invalid value lgpl=$lgpl" ;;
! esac
! ;;
esac
done
fi
***************
*** 2235,2244 ****
if test -n "$do_copyrights"; then
if test -n "$lgpl"; then
# Update license.
! sed_transform_lib_file=$sed_transform_lib_file'
! s/GNU General/GNU Lesser General/g
! s/version 2\([ ,]\)/version 2.1\1/g
! '
fi
fi
--- 2265,2284 ----
if test -n "$do_copyrights"; then
if test -n "$lgpl"; then
# Update license.
! case "$lgpl" in
! yes | 3)
! sed_transform_lib_file=$sed_transform_lib_file'
! s/GNU General/GNU Lesser General/g
! '
! ;;
! 2)
! sed_transform_lib_file=$sed_transform_lib_file'
! s/GNU General/GNU Lesser General/g
! s/version [23]\([ ,]\)/version 2.1\1/g
! '
! ;;
! *) func_fatal_error "invalid value lgpl=$lgpl" ;;
! esac
fi
fi
***************
*** 2473,2479 ****
func_append actioncmd " --avoid=$module"
done
if test -n "$lgpl"; then
! func_append actioncmd " --lgpl"
fi
if test -n "$makefile_name"; then
func_append actioncmd " --makefile-name=$makefile_name"
--- 2513,2523 ----
func_append actioncmd " --avoid=$module"
done
if test -n "$lgpl"; then
! if test "$lgpl" = yes; then
! func_append actioncmd " --lgpl"
! else
! func_append actioncmd " --lgpl=$lgpl"
! fi
fi
if test -n "$makefile_name"; then
func_append actioncmd " --makefile-name=$makefile_name"
***************
*** 2695,2701 ****
echo "gl_TESTS_BASE([$testsbase])"
test -z "$inctests" || echo "gl_WITH_TESTS"
echo "gl_LIB([$libname])"
! test -z "$lgpl" || echo "gl_LGPL"
echo "gl_MAKEFILE_NAME([$makefile_name])"
if test "$libtool" = true; then
echo "gl_LIBTOOL"
--- 2739,2751 ----
echo "gl_TESTS_BASE([$testsbase])"
test -z "$inctests" || echo "gl_WITH_TESTS"
echo "gl_LIB([$libname])"
! if test -n "$lgpl"; then
! if test "$lgpl" = yes; then
! echo "gl_LGPL"
! else
! echo "gl_LGPL([$lgpl])"
! fi
! fi
echo "gl_MAKEFILE_NAME([$makefile_name])"
if test "$libtool" = true; then
echo "gl_LIBTOOL"
- gnulib-tool --lgpl doesn't convert gplv3 to lgplv2.1, Simon Josefsson, 2007/10/16
- Re: gnulib-tool --lgpl doesn't convert gplv3 to lgplv2.1, Bruno Haible, 2007/10/16
- Re: gnulib-tool --lgpl doesn't convert gplv3 to lgplv2.1, Simon Josefsson, 2007/10/19
- Re: gnulib-tool --lgpl doesn't convert gplv3 to lgplv2.1, Bruno Haible, 2007/10/21
- Re: gnulib-tool --lgpl doesn't convert gplv3 to lgplv2.1, Simon Josefsson, 2007/10/22
- Re: gnulib-tool --lgpl doesn't convert gplv3 to lgplv2.1,
Bruno Haible <=
- Re: gnulib-tool --lgpl doesn't convert gplv3 to lgplv2.1, Simon Josefsson, 2007/10/29
- Re: gnulib-tool --lgpl doesn't convert gplv3 to lgplv2.1, Bruno Haible, 2007/10/29
- Re: gnulib-tool --lgpl doesn't convert gplv3 to lgplv2.1, Simon Josefsson, 2007/10/29