Collection of DPF-based plugins for packaging
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

71 lines
2.7KB

  1. # ===========================================================================
  2. # https://www.gnu.org/software/autoconf-archive/ax_subdir_files.html
  3. # ===========================================================================
  4. #
  5. # SYNOPSIS
  6. #
  7. # AX_SUBDIR_FILES [(SUBDIRS [, CASEPATTERN])]
  8. #
  9. # DESCRIPTION
  10. #
  11. # Look into subdirs and copy the (real) files that match pattern into the
  12. # local directory. Preferably we use a symbolic link of course. existing
  13. # local files are not overwritten.
  14. #
  15. # The default casepattern is "*.?|*.cc|*.cpp", the default subdir-list
  16. # contains all subdirs available.
  17. #
  18. # LICENSE
  19. #
  20. # Copyright (c) 2008 Guido U. Draheim <guidod@gmx.de>
  21. #
  22. # This program is free software; you can redistribute it and/or modify it
  23. # under the terms of the GNU General Public License as published by the
  24. # Free Software Foundation; either version 3 of the License, or (at your
  25. # option) any later version.
  26. #
  27. # This program is distributed in the hope that it will be useful, but
  28. # WITHOUT ANY WARRANTY; without even the implied warranty of
  29. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
  30. # Public License for more details.
  31. #
  32. # You should have received a copy of the GNU General Public License along
  33. # with this program. If not, see <https://www.gnu.org/licenses/>.
  34. #
  35. # As a special exception, the respective Autoconf Macro's copyright owner
  36. # gives unlimited permission to copy, distribute and modify the configure
  37. # scripts that are the output of Autoconf when processing the Macro. You
  38. # need not follow the terms of the GNU General Public License when using
  39. # or distributing such scripts, even though portions of the text of the
  40. # Macro appear in them. The GNU General Public License (GPL) does govern
  41. # all other use of the material that constitutes the Autoconf Macro.
  42. #
  43. # This special exception to the GPL applies to versions of the Autoconf
  44. # Macro released by the Autoconf Archive. When you make and distribute a
  45. # modified version of the Autoconf Macro, you may extend this special
  46. # exception to the GPL to apply to your modified version as well.
  47. #serial 7
  48. AU_ALIAS([AC_SUBDIR_FILES], [AX_SUBDIR_FILES])
  49. AC_DEFUN([AX_SUBDIR_FILES],
  50. [AC_BEFORE($0,[AX_PROG_CP_S])
  51. for ac_subdir in ifelse([$1], , *, $1) ; do
  52. if test -d $ac_subdir ; then
  53. AC_MSG_CHECKING(subdir $ac_subdir)
  54. for ac_file in $ac_subdir/* ; do
  55. if test -f $ac_file ; then
  56. if test ! -e `basename $ac_file` ; then
  57. case `basename $ac_file` in
  58. ifelse([$2], , *.?|*.cc|*.cpp,[$1]))
  59. echo ${ECHO_N} "$ac_file," ;
  60. $CP_S $ac_file . ;;
  61. esac
  62. fi
  63. fi
  64. done
  65. AC_MSG_RESULT(;)
  66. fi
  67. done
  68. ])