* source and compiled file installtion locations
@ 2018-05-03 5:15 David Pirotte
2018-05-06 0:03 ` David Pirotte
0 siblings, 1 reply; 4+ messages in thread
From: David Pirotte @ 2018-05-03 5:15 UTC (permalink / raw)
To: guile-devel
[-- Attachment #1: Type: text/plain, Size: 2025 bytes --]
Hello Guilers,
I'm still in doubt wrt guile-lib (as a matter of fact, could be any project) source
and compiled file location, and would like to hear what people think.
Most of us (if not all, copying each other I guess) install our project files either
in:
GUILE_SITE [ source files
GUILE_SITE_CCACHE [ compiled files
or
$(datarootdir)/guile/site/GUILE_EFFECTIVE_VERSION [ source
$(libdir)/guile/GUILE_EFFECTIVE_VERSION/site-ccache [ compiled
[ for those of us who have a proper implementation and follow a --prefix
[ given by the user ...
[ other files (doc, libs if C coe...) follow GNU standards and honor
[ --prefix if given ...
In my opinion, unless the project defines a user option, --use-guile-site [1], all
these locations are incorrect (except 'other files..], let me explain:
1- no --use-guile-site
in this case, imo, locations should be
$(datarootdir)/<project-name> [ source
$(libdir)/<project-name>/guile-GUILE_EFFECTIVE_VERSION/site-ccache
[ compiled
2- --use-guile-site
in this case, imo, location should be
GUILE_GLOBAL_SITE [2] [ source files
GUILE_SITE_CCACHE [ compiled files
Wrt the former, it is because I think, unless the s/w source is not 2.0 and 2.2
compatible, there is no reason it should land in a GUILE_EFFECTIVE_VERSION
subdir. If indeed the s/w is guile version dependent, then the former would be
GUILE_SITE ...
WDYT?
Thanks,
David
[1] I see some uses --with-guilesitedir
I have two remarks (quiz) wrt this: (a) in the doc (autoconf), you see that
--with-foo, defined using AC_ARG_WITH is related to enable the 'foo' external
lbrary, which is not our case; (b) --with-guilesitedir refers to GUILE_SITE_DIR,
which actually is the name of the m4 macro, the variable this macro defines is
GUILE_SITE, so I opted for --use-guile-site
[2] see %global-site-dir in the manual
I defined a few guile-ext.m4 ('extensions '), here
http://git.savannah.gnu.org/cgit/guile-cv.git/tree/m4/guile-ext.m4
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: source and compiled file installtion locations
2018-05-03 5:15 source and compiled file installtion locations David Pirotte
@ 2018-05-06 0:03 ` David Pirotte
2018-05-06 8:56 ` Chris Vine
0 siblings, 1 reply; 4+ messages in thread
From: David Pirotte @ 2018-05-06 0:03 UTC (permalink / raw)
To: guile-devel
[-- Attachment #1: Type: text/plain, Size: 847 bytes --]
Hello Guilers,
> 1- no --use-guile-site
>
> in this case, imo, locations should be
>
> $(datarootdir)/<project-name> [ source
FWIW,
This is what guile-gnome does, and it also does it in $(libdir), $(includedir) ...,
It does it using guile-gnome API version, not guile effective version, which I also
think 'projects' should do, so currently, guile-gnome pure scheme modules land
in:
$(datarootdir)/guile-gnome-2
[ except for the doc, installed in
[ $(docdor)/guile-gnome-platform/
The only module that guile-gnome installs in $(datarootdir)/guile/site (and not
$(datarootdir)/guile/site/GUILE_EFFECTIVE_VERSION as I also claim we should not do
this) is gnome-2, a module that users import to 'inform' guile of source, lib
locations (which they also can do sing the guile-gnome-2 script ...)
Cheers,
David
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: source and compiled file installtion locations
2018-05-06 0:03 ` David Pirotte
@ 2018-05-06 8:56 ` Chris Vine
2018-05-06 22:17 ` David Pirotte
0 siblings, 1 reply; 4+ messages in thread
From: Chris Vine @ 2018-05-06 8:56 UTC (permalink / raw)
To: guile-devel
On Sat, 5 May 2018 21:03:14 -0300
David Pirotte <david@altosw.be> wrote:
> Hello Guilers,
>
> > 1- no --use-guile-site
> >
> > in this case, imo, locations should be
> >
> > $(datarootdir)/<project-name> [ source
>
> FWIW,
>
> This is what guile-gnome does, and it also does it in $(libdir), $(includedir) ...,
>
> It does it using guile-gnome API version, not guile effective version, which I also
> think 'projects' should do, so currently, guile-gnome pure scheme modules land
> in:
>
> $(datarootdir)/guile-gnome-2
>
> [ except for the doc, installed in
> [ $(docdor)/guile-gnome-platform/
>
> The only module that guile-gnome installs in $(datarootdir)/guile/site (and not
> $(datarootdir)/guile/site/GUILE_EFFECTIVE_VERSION as I also claim we should not do
> this) is gnome-2, a module that users import to 'inform' guile of source, lib
> locations (which they also can do sing the guile-gnome-2 script ...)
Instead of using the project's $(libdir), $(datarootdir), and so forth,
I use pkgconfig to interogate guile-2.2.pc or guile-2.0.pc, and install
source (.scm) files in its revealed 'sitedir' and compiled (.go) files
in its revealed 'siteccachedir', with the base project module name
added to the path in each case. That way, even if the project
(including any of its shared library files) are installed in, say,
the /usr/local prefix, the scheme files are installed in the correct
prefix for guile.
That is presumably why 'sitedir' and 'siteccachedir' are exposed by
pkgconfig.
Chris
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: source and compiled file installtion locations
2018-05-06 8:56 ` Chris Vine
@ 2018-05-06 22:17 ` David Pirotte
0 siblings, 0 replies; 4+ messages in thread
From: David Pirotte @ 2018-05-06 22:17 UTC (permalink / raw)
To: Chris Vine; +Cc: guile-devel
[-- Attachment #1: Type: text/plain, Size: 2829 bytes --]
Hi Chris,
> On Sat, 5 May 2018 21:03:14 -0300
> David Pirotte <david@altosw.be> wrote:
> > Hello Guilers,
> >
> > > 1- no --use-guile-site
> > >
> > > in this case, imo, locations should be
> > >
> > > $(datarootdir)/<project-name> [ source
> >
> > FWIW,
> >
> > This is what guile-gnome does, and it also does it in $(libdir),
> > $(includedir) ...,
> >
> > It does it using guile-gnome API version, not guile effective version, which I
> > also think 'projects' should do, so currently, guile-gnome pure scheme modules
> > land in:
> >
> > $(datarootdir)/guile-gnome-2
> >
> > [ except for the doc, installed in
> > [ $(docdor)/guile-gnome-platform/
> >
> > The only module that guile-gnome installs in $(datarootdir)/guile/site (and not
> > $(datarootdir)/guile/site/GUILE_EFFECTIVE_VERSION as I also claim we should not
> > do this) is gnome-2, a module that users import to 'inform' guile of source, lib
> > locations (which they also can do sing the guile-gnome-2 script ...)
> Instead of using the project's $(libdir), $(datarootdir), and so forth,
> I use pkgconfig to interogate guile-2.2.pc or guile-2.0.pc, and install
> source (.scm) files in its revealed 'sitedir' and compiled (.go) files
> in its revealed 'siteccachedir', with the base project module name
> added to the path in each case. That way, even if the project
> (including any of its shared library files) are installed in, say,
> the /usr/local prefix, the scheme files are installed in the correct
> prefix for guile.
Yes, we all do this, as said in my first email, though we generally use variables
defined by the guile m4 macros instead, GUILE_SITE .... for those who would not
know, the complete set of these variables is also in %guile-build-info ...
But as I wrote in the first email as well, I believe this not the right thing to do:
(1) it does not respect GNU standards (without the user consent, to me this is
wrong) and (2) because, and that is a real problem, it disrespect --prefix if given
(it is very often given), and Daniel Llorens recently complained about this (wrt
guile-lib), and I agree with him ...
So I started to think a bit more about this :), and came to the conclusion that
unless the user explicitly ask to 'disrespect' the GNU standards (filesystem),
through an option, --with-guile-site or --use-guile-site [1], all projects should
respect it, which is what guile-gnome does ... This way, both --prefix and/or
--use-guile-site would work ... This approach actually correctly honors all demands.
David
[1] I asked on #autotools, and they answered that although the manual implies
--with-* is for enabling external libraries, they actually use this prefix
for 'what ever...' :)
I still thnk --use-guile-site is better though
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-05-06 22:17 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-05-03 5:15 source and compiled file installtion locations David Pirotte
2018-05-06 0:03 ` David Pirotte
2018-05-06 8:56 ` Chris Vine
2018-05-06 22:17 ` David Pirotte
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).