Makefile.am 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. ## Process this file with Automake to create Makefile.in
  2. ##
  3. ## Copyright (C) 1998, 1999, 2000, 2001, 2004, 2006, 2007, 2008,
  4. ## 2009, 2010, 2012, 2013 Free Software Foundation, Inc.
  5. ##
  6. ## This file is part of guile-readline.
  7. ##
  8. ## guile-readline is free software; you can redistribute it and/or
  9. ## modify it under the terms of the GNU General Public License as
  10. ## published by the Free Software Foundation; either version 3, or
  11. ## (at your option) any later version.
  12. ##
  13. ## guile-readline is distributed in the hope that it will be useful,
  14. ## but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  16. ## General Public License for more details.
  17. ##
  18. ## You should have received a copy of the GNU General Public License
  19. ## along with guile-readline; see the file COPYING. If not, write
  20. ## to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
  21. ## Floor, Boston, MA 02110-1301 USA
  22. include $(top_srcdir)/am/snarf
  23. include $(top_srcdir)/am/guilec
  24. ## Prevent automake from adding extra -I options
  25. DEFS = @DEFS@ @EXTRA_DEFS@
  26. # We're at the root of the module hierarchy.
  27. modpath =
  28. SOURCES =
  29. if HAVE_READLINE
  30. SOURCES += ice-9/readline.scm
  31. ## Check for headers in $(srcdir)/.., so that #include
  32. ## <libguile/MUMBLE.h> will find MUMBLE.h in this dir when we're
  33. ## building. Also look for Gnulib headers in `lib'.
  34. AM_CPPFLAGS = -I. -I.. -I$(srcdir)/.. \
  35. -I$(top_srcdir)/lib -I$(top_builddir)/lib
  36. AM_CFLAGS = $(GCC_CFLAGS)
  37. extensionsdir=$(pkglibdir)/$(GUILE_EFFECTIVE_VERSION)/extensions
  38. extensions_LTLIBRARIES = guile-readline.la
  39. guile_readline_la_SOURCES = readline.c
  40. guile_readline_la_LIBADD = \
  41. $(READLINE_LIBS) \
  42. ../libguile/libguile-@GUILE_EFFECTIVE_VERSION@.la ../lib/libgnu.la
  43. guile_readline_la_LDFLAGS = -export-dynamic -no-undefined -module
  44. BUILT_SOURCES = readline.x
  45. modincludedir = $(pkgincludedir)/$(GUILE_EFFECTIVE_VERSION)
  46. modinclude_HEADERS = readline.h
  47. snarfcppopts = $(DEFS) $(AM_CPPFLAGS) $(CPPFLAGS) $(CFLAGS)
  48. SUFFIXES += .x
  49. .c.x:
  50. $(AM_V_SNARF)$(GUILE_SNARF) -o $@ $< $(snarfcppopts)
  51. EXTRA_DIST += ChangeLog-2008
  52. ETAGS_ARGS += $(guile_readline_la_SOURCES)
  53. CLEANFILES += *.x *.go
  54. endif HAVE_READLINE
  55. dist-hook:
  56. (temp="/tmp/mangle-deps.$$$$"; \
  57. trap "rm -f $$temp" 0 1 2 15; \
  58. sed -e 's|\([ ]\)\(\.\./\(\|libguile/\|guile-readline/\)[a-z_-]*\.h\)|\1$$(srcdir)/\2|g' $(distdir)/Makefile.in \
  59. | sed -e 's|\$$(srcdir)/\(\.\./libguile/\(libpath\|scmconfig\|versiondat\)\)|\1|g' \
  60. | sed -e 's|\.\./guile-readline/\([a-z_-]*\.x\)|\1|g' > $$temp \
  61. && chmod u+w $(distdir)/Makefile.in && cp -p $$temp $(distdir)/Makefile.in)