Discussion:
Documentation update for relocatable-lib{,-lgpl}
(too old to reply)
Reuben Thomas
2017-04-04 00:07:58 UTC
Permalink
Raw Message
[Ben: Ccing you on Bruno Haible's advice]

Having gone through the changes I needed to make to my sources to use the
relocatable-lib-lgpl module, here's a list of things I think should be
documented in doc/relocatable-maint.texi. If they're agreed to be correct,
I'll prepare a documentation patch.

Makefile.am: the relevant CPPFLAGS should contain:
-DENABLE_COSTLY_RELOCATABLE (if desired) and -DIN_LIBRARY.
Makefile.am: the relevant LIBADD variable, or equivalent, should contain
$([LT]LIBOBJS)

configure.ac: A suitable invocation of AC_CONFIG_LIBOBJ_DIR([lib]) should
be added.

​Source: #include "relocatable.h"
​
Should automatic advice be also added to the module files to mention these
when running gnulib-tool? (relocatable.h is already mentioned
automatically).

Call ​set_relocation_prefix if desired​. Not totally necessary (automatic
initialisation code works on some platforms).

Additionally,​configmake is useful​ to get a range of paths that it may be
desired to relocate.


That's all I can see that I did; anything obvious that I've overlooked?


Additionally, I wonder about making -DENABLE_COSTLY_RELOCATABLE the default
behaviour (the comments in relocatable.c say that the support is pretty
cheap on most platforms).

Finally, how about making --enable-relocatable the default? The package I'm
working on requires it, and again, if you've added relocation support, you
might as well give it to users unless they want to turn it off.
--
http://rrt.sc3d.org
Ben Pfaff
2017-04-05 03:28:46 UTC
Permalink
Raw Message
Post by Reuben Thomas
[Ben: Ccing you on Bruno Haible's advice]
Having gone through the changes I needed to make to my sources to use the
relocatable-lib-lgpl module, here's a list of things I think should be
documented in doc/relocatable-maint.texi. If they're agreed to be correct,
I'll prepare a documentation patch.
I think that Bruno is really the expert here. I helped out with
"relocatable" to a significant degree, but I don't have any expertise
with libraries. If Bruno approves, then I second it.
Reuben Thomas
2017-04-07 13:20:41 UTC
Permalink
Raw Message
Post by Reuben Thomas
Post by Reuben Thomas
[Ben: Ccing you on Bruno Haible's advice]
Having gone through the changes I needed to make to my sources to use the
relocatable-lib-lgpl module, here's a list of things I think should be
documented in doc/relocatable-maint.texi. If they're agreed to be
correct,
Post by Reuben Thomas
I'll prepare a documentation patch.
I think that Bruno is really the expert here. I helped out with
"relocatable" to a significant degree, but I don't have any expertise
with libraries. If Bruno approves, then I second it.
​Thanks, Ben.

Bruno (& Ben if you're still listening!), I would like to suggest a
simplification:

1. We should drop the --enable-relocatable flag, unless there's some
problem which is unrelated to performance (which at least without
ENABLE_COSTLY_RELOCATABLE takes a negligible hit on all platforms).

2. We should go further, and remove the ENABLE_COSTLY_RELOCATABLE define.
As far as I can see, this only applies to Cygwin, and these days there are
plenty of alternatives for building free software on Windows. If you want
maximum fidelity to a POSIX system, and can't or won't use Microsoft's
latest "built-in GNU/Linux", then fine, use Cygwin, but since it translates
a lot of mechanisms on the fly between Windows and POSIX, you can expect
some slowdown. In any case, it's a one-off for us, on program start-up.

If you're happy with that suggestion, my documentation task will be
simpler, and I'll also of course provide suitable patches to remove the
configure flag and define, plus their documentation.

For backwards compatibility, ENABLE_RELOCATABLE would still be defined.
--
http://rrt.sc3d.org
Loading...