From 766cfeab9a081922313c6352c6b8a8418350c71c Mon Sep 17 00:00:00 2001 From: Jan Nieuwenhuizen Date: Mon, 12 Jun 2017 17:18:31 +0200 Subject: [PATCH] core: %moduledir ends with /. * make/install.make (MODULEDIR): Append /. (install): Remove /. * src/mes.c (load_env, bload_env): Update. --- make/install.make | 4 ++-- src/mes.c | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/make/install.make b/make/install.make index 9b608241..b40e96d2 100644 --- a/make/install.make +++ b/make/install.make @@ -34,7 +34,7 @@ LIBDIR:=$(PREFIX)/lib GODIR:=$(LIBDIR)/guile/$(GUILE_EFFECTIVE_VERSION)/site-ccache GUILEDIR:=$(PREFIX)/share/guile/site/$(GUILE_EFFECTIVE_VERSION) -MODULEDIR:=$(DATADIR)/module +MODULEDIR:=$(DATADIR)/module/ .tarball-version: tree-clean-p echo $(COMMIT) > $@ @@ -79,7 +79,7 @@ endif -e 's,@DOCDIR@,$(DOCDIR)/,g' \ -e 's,@GODIR@,$(GODIR)/,g' \ -e 's,@GUILEDIR@,$(GUILEDIR)/,g' \ - -e 's,@MODULEDIR@,$(MODULEDIR)/,g' \ + -e 's,@MODULEDIR@,$(MODULEDIR),g' \ -e 's,@PREFIX@,$(PREFIX)/,g' \ -e 's,@VERSION@,$(VERSION),g' \ $(DESTDIR)$(DATADIR)/module/mes/base-0.mes \ diff --git a/src/mes.c b/src/mes.c index bdac87be..1eb8a187 100644 --- a/src/mes.c +++ b/src/mes.c @@ -1240,7 +1240,7 @@ load_env (SCM a) ///((internal)) { r0 = a; g_stdin = open ("module/mes/read-0.mes", O_RDONLY); - g_stdin = g_stdin >= 0 ? g_stdin : open (MODULEDIR "/mes/read-0.mes", O_RDONLY); + g_stdin = g_stdin >= 0 ? g_stdin : open (MODULEDIR "mes/read-0.mes", O_RDONLY); if (!g_function) r0 = mes_builtins (r0); r2 = read_input_file_env (r0); g_stdin = STDIN; @@ -1253,11 +1253,11 @@ bload_env (SCM a) ///((internal)) #if __MESC__ char *mo = "mes/read-0-32.mo"; g_stdin = open ("module/mes/read-0-32.mo", O_RDONLY); - g_stdin = g_stdin >= 0 ? g_stdin : open (MODULEDIR "/mes/read-0-32.mo", O_RDONLY); + g_stdin = g_stdin >= 0 ? g_stdin : open (MODULEDIR "mes/read-0-32.mo", O_RDONLY); #else char *mo ="mes/read-0.mo"; g_stdin = open ("module/mes/read-0.mo", O_RDONLY); - g_stdin = g_stdin >= 0 ? g_stdin : open (MODULEDIR "/mes/read-0.mo", O_RDONLY); + g_stdin = g_stdin >= 0 ? g_stdin : open (MODULEDIR "mes/read-0.mo", O_RDONLY); #endif if (g_stdin < 0) {eputs ("no such file: ");eputs (mo);eputs ("\n");return 1;}