primary-prefix-couples-documented-valid.sh 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. #! /bin/sh
  2. # Copyright (C) 2011-2017 Free Software Foundation, Inc.
  3. #
  4. # This program is free software; you can redistribute it and/or modify
  5. # it under the terms of the GNU General Public License as published by
  6. # the Free Software Foundation; either version 2, or (at your option)
  7. # any later version.
  8. #
  9. # This program is distributed in the hope that it will be useful,
  10. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. # GNU General Public License for more details.
  13. #
  14. # You should have received a copy of the GNU General Public License
  15. # along with this program. If not, see <http://www.gnu.org/licenses/>.
  16. # Check that the "uncommon" prefix/primary combinations used in
  17. # examples in the Automake manual do not cause obvious errors.
  18. # Please keep this test in sync with the automake manual.
  19. . test-init.sh
  20. cat >> configure.ac <<'END'
  21. AC_PROG_CC
  22. AM_PROG_AR
  23. AC_PROG_RANLIB
  24. AC_PROG_LIBTOOL
  25. AM_PROG_GCJ
  26. AM_PATH_PYTHON
  27. END
  28. # Fake libtool availability.
  29. : > ltmain.sh
  30. cat > acinclude.m4 <<'END'
  31. AC_DEFUN([AC_PROG_LIBTOOL],
  32. [AC_SUBST([LIBTOOL], [:])])
  33. END
  34. cat > Makefile.am <<'END'
  35. xmldir = $(datadir)/xml
  36. xml_DATA = file.xml
  37. data_DATA = file1 file2 file3
  38. data2dir = $(datadir)
  39. data2_DATA = file4 file5 file6
  40. aclocaldir = $(datadir)/aclocal
  41. aclocal_DATA = mymacro.m4 myothermacro.m4
  42. imagesdir = $(pkgdatadir)/images
  43. soundsdir = $(pkgdatadir)/sounds
  44. dist_images_DATA = images/vortex.pgm
  45. dist_sounds_DATA = sounds/whirl.ogg
  46. lisp_DATA = file1.el file2.el
  47. javadir = $(datadir)/java
  48. dist_java_JAVA = a.java b.java c.java
  49. pkgpython_PYTHON = foo.py
  50. pyexec_LTLIBRARIES = quaternion.la
  51. quaternion_la_SOURCES = quaternion.c support.c support.h
  52. quaternion_la_LDFLAGS = -avoid-version -module
  53. myexecbindir = /exec
  54. myexecbin_PROGRAMS = zardoz
  55. foodir = $(prefix)/foo
  56. barexecdir = $(prefix)/bar/binaries
  57. foo_SCRIPTS = foo.sh
  58. barexec_SCRIPTS = quux.pl
  59. my_execbindir = $(pkglibdir)
  60. my_doclibdir = $(docdir)
  61. my_execbin_PROGRAMS = foo
  62. my_doclib_LIBRARIES = libquux.a
  63. END
  64. $ACLOCAL
  65. # Both these two invocations are meant.
  66. # They exercise both code paths concerning auxiliary files.
  67. $AUTOMAKE -a
  68. $AUTOMAKE
  69. :