Hello Matt, Matt Wette <matt.we...@gmail.com> skribis:
> From configure.ac: > > guile_build_prefix=`$GUILE -c "(display (assq-ref %guile-build-info > 'prefix))"` > > if test "$guile_build_prefix" == "$prefix"; then > echo "using paths for installed guile" > GUILE_SITE_DIR > GUILE_SITE_GO_DIR > GUILE_DATA_DIR > else > echo "using default paths for guile" > GUILE_SITE=$prefix/share/guile/site/$GUILE_EFFECTIVE_VERSION > GUILE_SITE_GO=$prefix/lib/guile/$GUILE_EFFECTIVE_VERSION/site-ccache > GUILE_DATA=$prefix/share > AC_SUBST([GUILE_SITE]) > AC_SUBST([GUILE_SITE_GO]) > AC_SUBST([GUILE_DATA]) > fi I would recommend not even bothering with the first part of the ‘if’, and instead always default to install files under $prefix (more precisely: under $datadir and $libdir). The bits I’ve been using are: configure.ac: dnl We require guile.m4, from Guile. Make sure it's available. m4_pattern_forbid([^GUILE_P]) m4_pattern_allow([^GUILE_PKG_ERRORS]) GUILE_PKG([3.0 2.2 2.0]) GUILE_PROGS Makefile.am: moddir = $(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION) godir = $(libdir)/guile/$(GUILE_EFFECTIVE_VERSION)/site-ccache SOURCES = a.scm b.scm c.scm GOBJECTS = $(SOURCES:%.scm=%.go) nobase_mod_DATA = $(SOURCES) nobase_go_DATA = $(GOBJECTS) I believe Hall¹ does the right thing, making it easier to get started with all this! Thanks, Ludo’. ¹ https://gitlab.com/a-sassmannshausen/guile-hall