moddir=$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION) godir=$(libdir)/guile/$(GUILE_EFFECTIVE_VERSION)/site-ccache SOURCES = $(LIBRARY_DEFINITIONS:%.sld=%.scm) GOBJECTS = $(DEPENDENCIES:%.scm=%.go) $(SOURCES:%.scm=%.go) $(GUILE_SPECIFIC_SOURCES:%.scm=%.go) EXECUTABLE = lsp-server/guile-lsp-server nobase_dist_mod_DATA = $(SOURCES) $(GUILE_SPECIFIC_SOURCES) $(DEPENDENCIES) nobase_go_DATA = $(GOBJECTS) bin_SCRIPTS = $(EXECUTABLE) $(EXECUTABLE): lsp-server/main.scm echo '#!/usr/bin/env sh' > $(EXECUTABLE) echo 'exec guile -x ".sld" -e main -s "$$0" "$$@"' >> $(EXECUTABLE) echo '!#' >> $(EXECUTABLE) echo >> $(EXECUTABLE) cat lsp-server/main.scm >> $(EXECUTABLE) # Make sure source files are installed first, so that the mtime of # installed compiled files is greater than that of installed source # files. See # # for details. guile_install_go_files = install-nobase_goDATA $(guile_install_go_files): install-nobase_dist_modDATA uninstall-hook: rm -f $(DESTDIR)$(godir)/$(GOBJECTS) rm -f $(DESTDIR)$(bindir)/$(EXECUTABLE) CLEANFILES = $(GOBJECTS) $(EXECUTABLE) $(SOURCES) GUILE_WARNINGS = -Wunbound-variable -Warity-mismatch -Wformat SUFFIXES = .scm .sld .go PREFIX=$(AM_V_GEN)GUILE_LOAD_COMPILED_PATH="@abs_top_builddir@/:$(GUILE_LOAD_COMPILED_PATH)"; \ GUILE_LOAD_PATH="@abs_top_builddir@/:@abs_top_srcdir@/:$(GUILE_LOAD_PATH)" lsp-server.scm: lsp-server.sld lsp-server/file.scm lsp-server/server.scm cat $< > $@ echo "" >> $@ cat lsp-server/file.scm >> $@ echo "" >> $@ cat lsp-server/server.scm >> $@ lsp-server/private.scm: lsp-server/private.sld lsp-server/private-impl.scm cat $< > $@ echo "" >> $@ cat lsp-server/private-impl.scm >> $@ lsp-server/document.scm: lsp-server/document.sld lsp-server/document-impl.scm cat $< > $@ echo "" >> $@ cat lsp-server/document-impl.scm >> $@ lsp-server/trie.scm: lsp-server/trie.sld lsp-server/trie-impl.scm cat $< > $@ echo "" >> $@ cat lsp-server/trie-impl.scm >> $@ lsp-server/parse.scm: lsp-server/parse.sld lsp-server/parse-impl.scm cat $< > $@ echo "" >> $@ cat lsp-server/parse-impl.scm >> $@ lsp-server/adapter.scm: lsp-server/adapter.sld lsp-server/adapter-impl.scm cat $< > $@ echo "" >> $@ cat lsp-server/adapter-impl.scm >> $@ distclean-local: rm -Rf src/ geiser/ $(SOURCES) .scm.go: $(PREFIX) $(GUILE_TOOLS) compile $(GUILE_WARNINGS) -x ".sld" -O0 --r7rs -o "$@" "$<"