Commit c8ba0064 authored by Marc-André Lureau's avatar Marc-André Lureau

build-sys: remove autotools

kthxbye
Signed-off-by: Marc-André Lureau's avatarMarc-André Lureau <marcandre.lureau@redhat.com>
parent 15f9b594
NULL =
EXTRA_DIST =
BUILT_SOURCES =
CONFIG_STATUS_DEPENDENCIES =
ACLOCAL_AMFLAGS = -I m4
makeflags_ = $(makeflags_$(AM_DEFAULT_VERBOSITY))
makeflags_0 = --no-print-directory -s
makeflags_1 =
AM_MAKEFLAGS = $(makeflags_$(V))
SUBDIRS = . po spice libphodav doc
lib_LTLIBRARIES = libphodav-2.0.la
bin_PROGRAMS = chezdav
sbin_PROGRAMS = spice-webdavd
AM_CPPFLAGS = \
-DLOCALEDIR=\""$(localedir)"\" \
-DG_LOG_DOMAIN=\"phodav\" \
$(WARN_CFLAGS) \
$(NULL)
libphodav_includedir = $(includedir)/libphodav-2.0/libphodav
libphodav_include_HEADERS = \
libphodav/phodav-server.h \
libphodav/phodav.h \
$(NULL)
libphodav_2_0_la_SOURCES = \
libphodav/phodav-priv.h \
libphodav/phodav-path.c \
libphodav/phodav-path.h \
libphodav/phodav-lock.c \
libphodav/phodav-lock.h \
libphodav/phodav-if.c \
libphodav/phodav-method-delete.c \
libphodav/phodav-method-get.c \
libphodav/phodav-method-lock.c \
libphodav/phodav-method-mkcol.c \
libphodav/phodav-method-movecopy.c \
libphodav/phodav-method-propfind.c \
libphodav/phodav-method-proppatch.c \
libphodav/phodav-method-unlock.c \
libphodav/phodav-method-put.c \
libphodav/phodav-multistatus.c \
libphodav/phodav-multistatus.h \
libphodav/phodav-server.c \
libphodav/phodav-server.h \
libphodav/phodav-utils.c \
libphodav/phodav-utils.h \
$(NULL)
if BUILD_GUUID
libphodav_2_0_la_SOURCES += \
libphodav/guuid.c \
libphodav/guuid.h \
$(NULL)
endif
libphodav_2_0_la_CFLAGS = \
$(GIO_CFLAGS) \
$(SOUP_CFLAGS) \
$(NULL)
libphodav_2_0_la_LIBADD = \
$(GIO_LIBS) \
$(SOUP_LIBS) \
$(NULL)
libphodav_2_0_la_LDFLAGS = \
-version-info 0:0:0 \
-Wl,--version-script=${srcdir}/libphodav/libphodav.syms \
-no-undefined \
$(NULL)
libphodav_2_0_la_DEPENDENCIES = libphodav/libphodav.syms
EXTRA_DIST += libphodav/libphodav.syms
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libphodav-2.0.pc
spice_webdavd_SOURCES = spice/spice-webdavd.c
spice_webdavd_CFLAGS = \
$(GIO_CFLAGS) \
$(AVAHI_CFLAGS) \
$(PIE_CFLAGS) \
$(NULL)
spice_webdavd_LDADD = \
$(GIO_LIBS) \
$(AVAHI_LIBS) \
$(PIE_LDFLAGS) \
$(NULL)
if OS_WIN32
spice_webdavd_LDADD += -lnetapi32 -lmpr
endif
deps.txt:
$(AM_V_GEN)rpm -qa | grep $(host_os) | sort | unix2dos > $@
MANUFACTURER = The Spice Project
EXTRA_DIST += chezdav.wxs.in
CONFIG_STATUS_DEPENDENCIES += chezdav.wxs.in
chezdav-$(WIXL_ARCH)-$(VERSION)$(BUILDID).msi: chezdav.wxs deps.txt all
$(AM_V_GEN)DESTDIR=`mktemp -d`&& \
make -C $(top_builddir) install DESTDIR=$$DESTDIR >/dev/null && \
MANUFACTURER="$(MANUFACTURER)" wixl -D SourceDir=$(prefix) \
-D DESTDIR=$$DESTDIR$(prefix) \
--arch $(WIXL_ARCH) -o $@ $<
MSI = chezdav-$(WIXL_ARCH)-$(VERSION)$(BUILDID).msi
EXTRA_DIST += spice-webdavd.wxs.in
CONFIG_STATUS_DEPENDENCIES += spice-webdavd.wxs.in
spice-webdavd-$(WIXL_ARCH)-$(VERSION)$(BUILDID).msi: spice-webdavd.wxs deps.txt all
$(AM_V_GEN)DESTDIR=`mktemp -d`&& \
make -C $(top_builddir) install DESTDIR=$$DESTDIR >/dev/null && \
MANUFACTURER="$(MANUFACTURER)" wixl -D SourceDir=$(prefix) \
-D DESTDIR=$$DESTDIR$(prefix) \
--arch $(WIXL_ARCH) -o $@ $<
MSI += spice-webdavd-$(WIXL_ARCH)-$(VERSION)$(BUILDID).msi
msi: $(MSI)
CLEANFILES = $(MSI)
.PHONY: msi
chezdav_SOURCES = libphodav/chezdav.c
chezdav_CFLAGS = \
-I. \
$(GIO_CFLAGS) \
$(SOUP_CFLAGS) \
$(AVAHI_CFLAGS) \
$(NULL)
chezdav_LDADD = \
libphodav-2.0.la \
$(GLIB_LIBS) \
$(GIO_LIBS) \
$(SOUP_LIBS) \
$(AVAHI_LIBS) \
$(NULL)
if HAVE_SYSTEMD
systemdunitdir = $(SYSTEMDSYSTEMUNITDIR)
dist_systemdunit_DATA = \
$(top_srcdir)/data/spice-webdavd.service \
$(NULL)
endif
if HAVE_UDEV
udevrulesdir = $(UDEVDIR)/rules.d
dist_udevrules_DATA = $(top_srcdir)/data/70-spice-webdavd.rules
endif
BUILT_SOURCES += $(top_srcdir)/.version
$(top_srcdir)/.version:
@echo $(VERSION) > $@-t && mv $@-t $@
dist-hook:
echo $(VERSION) > $(distdir)/.tarball-version
EXTRA_DIST += \
$(top_srcdir)/.version \
NEWS \
autogen.sh \
build-aux/git-version-gen \
phodav.doap \
$(NULL)
AM_DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc
DISTCLEANFILES = \
gtk-doc.make \
m4/gtk-doc.m4
MAINTAINERCLEANFILES = \
$(srcdir)/gtk-doc.make \
$(GITIGNORE_MAINTAINERCLEANFILES_TOPLEVEL) \
$(GITIGNORE_MAINTAINERCLEANFILES_MAKEFILE_IN) \
$(GITIGNORE_MAINTAINERCLEANFILES_M4_LIBTOOL)
DISTCHECK_CONFIGURE_FLAGS = \
--with-systemdsystemunitdir='$${libdir}/systemd/system-distcheck' \
--with-udevdir='$${libdir}/udev-distcheck'
-include $(top_srcdir)/git.mk
#!/bin/sh
# Run this to generate all the initial makefiles, etc.
test -n "$srcdir" || srcdir=$(dirname "$0")
test -n "$srcdir" || srcdir=.
olddir=$(pwd)
cd $srcdir
(test -f configure.ac) || {
echo "*** ERROR: Directory '$srcdir' does not look like the top-level project directory ***"
exit 1
}
# shellcheck disable=SC2016
PKG_NAME=$(autoconf --trace 'AC_INIT:$1' configure.ac)
if [ "$#" = 0 -a "x$NOCONFIGURE" = "x" ]; then
echo "*** WARNING: I am going to run 'configure' with no arguments." >&2
echo "*** If you wish to pass any to it, please specify them on the" >&2
echo "*** '$0' command line." >&2
echo "" >&2
fi
aclocal --install || exit 1
gtkdocize --copy || exit 1
autoreconf --verbose --force --install || exit 1
cd "$olddir"
if [ "$NOCONFIGURE" = "" ]; then
$srcdir/configure "$@" || exit 1
if [ "$1" = "--help" ]; then
exit 0
else
echo "Now type 'make' to compile $PKG_NAME" || exit 1
fi
else
echo "Skipping configure process."
fi
AC_PREREQ([2.59])
AC_INIT([phodav], [m4_esyscmd(build-aux/git-version-gen .tarball-version)],
[https://gitlab.gnome.org/GNOME/phodav/issues/new])
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_HEADERS([config.h])
AC_CONFIG_AUX_DIR([build-aux])
AC_CANONICAL_HOST
AC_PROG_CC
AC_USE_SYSTEM_EXTENSIONS
AC_CHECK_PROG([STOW], [stow], [yes], [no])
AS_IF([test "x$STOW" = "xyes" && test -d /usr/local/stow], [
AC_MSG_NOTICE([*** Found /usr/local/stow: default install prefix set to /usr/local/stow/${PACKAGE_NAME} ***])
ac_default_prefix="/usr/local/stow/${PACKAGE_NAME}"
])
AC_MSG_CHECKING([for native Win32])
case "$host_os" in
*mingw*|*cygwin*)
os_win32=yes
gio_os=gio-windows-2.0
;;
*)
os_win32=no
gio_os=gio-unix-2.0
;;
esac
AC_MSG_RESULT([$os_win32])
AM_CONDITIONAL([OS_WIN32],[test "$os_win32" = "yes"])
AM_INIT_AUTOMAKE([foreign -Wall -Wno-portability subdir-objects dist-xz])
m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])
AM_MAINTAINER_MODE([enable])
LT_INIT([win32-dll])
GTK_DOC_CHECK([1.14],[--flavour no-tmpl])
gl_MANYWARN_ALL_GCC([warnings])
nw=
nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
nw="$nw -Wundef" # All compiler preprocessors support #if UNDEF
nw="$nw -Wtraditional" # All compilers nowadays support ANSI C
nw="$nw -Wstrict-overflow" # yacc/bison generated code uses that..
nw="$nw -Wconversion" # These warnings usually don't point to mistakes.
nw="$nw -Wsign-conversion" # Likewise.
nw="$nw -Wunused-parameter" # Likewise.
nw="$nw -Wunused-local-typedefs" # Likewise.
nw="$nw -Wunused-macros" # Likewise.
nw="$nw -Wunsafe-loop-optimizations" # Likewise.
nw="$nw -Wbad-function-cast" # Likewise.
# Enable all GCC warnings not in this list.
gl_MANYWARN_COMPLEMENT([warnings], [$warnings], [$nw])
for w in $warnings; do
gl_WARN_ADD([$w])
done
gl_WARN_ADD([-Wno-sign-compare])
gl_WARN_ADD([-Wno-unused-parameter])
gl_WARN_ADD([-Wno-missing-field-initializers])
GETTEXT_PACKAGE=phodav-2.0
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, ["$GETTEXT_PACKAGE"], [Define to the Gettext package name])
AC_SUBST(GETTEXT_PACKAGE)
AM_GNU_GETTEXT_VERSION([0.19.7])
AM_GNU_GETTEXT([external])
AC_CHECK_HEADERS([attr/xattr.h])
PKG_CHECK_MODULES(GIO, [$gio_os])
PKG_CHECK_MODULES(SOUP, libsoup-2.4 >= 2.48.0 libxml-2.0)
# GLib's GUuid was introduce in GLib 2.51
# https://bugzilla.gnome.org/show_bug.cgi?id=639078
# do not build our version of it conditionally
PKG_CHECK_EXISTS([glib-2.0 > 2.51], [build_guuid=no], [build_guuid=yes])
AM_CONDITIONAL(BUILD_GUUID, [test "x$build_guuid" = "xyes"])
AC_ARG_WITH([avahi],
AS_HELP_STRING([--without-avahi], [Build without avahi/mdns]))
AS_IF([test "x$with_avahi" != "xno"],
[PKG_CHECK_MODULES([AVAHI], [avahi-gobject avahi-client],
[have_avahi=yes], [have_avahi=no])],
[have_avahi=no])
AS_IF([test "x$have_avahi" != "xyes"],
[AS_IF([test "x$with_avahi" = "xyes"],
[AC_MSG_ERROR([avahi requested but not found])])])
AS_IF([test "x$have_avahi" = "xyes"], [AC_DEFINE([WITH_AVAHI], [1], [With avahi])])
AC_ARG_ENABLE([pie],
AS_HELP_STRING([--enable-pie=@<:@auto/yes/no@:>@],
[Enable position-independent-executable support @<:@default=auto@:>@]),
[],
[enable_pie="auto"])
if test "x$enable_pie" != "xno"; then
save_CFLAGS="$CFLAGS"
save_LDFLAGS="$LDFLAGS"
CFLAGS="$CFLAGS -fPIE"
LDFLAGS="$LDFLAGS -pie -Wl,-z,relro -Wl,-z,now"
AC_MSG_CHECKING([for PIE support])
AC_LINK_IFELSE([AC_LANG_SOURCE([int main () { return 0; }])],
[have_pie=yes],
[have_pie=no])
AC_MSG_RESULT([$have_pie])
if test "x$have_pie" = "xno" && test "x$enable_pie" = "xyes"; then
AC_MSG_ERROR([pie support explicitly requested, but your toolchain does not support it])
fi
if test "x$have_pie" = "xyes"; then
PIE_CFLAGS="-fPIE"
PIE_LDFLAGS="-pie -Wl,-z,relro -Wl,-z,now"
AC_SUBST(PIE_CFLAGS)
AC_SUBST(PIE_LDFLAGS)
fi
CFLAGS="$save_CFLAGS"
LDFLAGS="$save_LDFLAGS"
else
have_pie=no
fi
AC_ARG_WITH([systemdsystemunitdir],
AS_HELP_STRING([--with-systemdsystemunitdir=DIR], [Directory for systemd service files]),
[], [with_systemdsystemunitdir=$prefix/lib/systemd/system])
AC_SUBST([SYSTEMDSYSTEMUNITDIR], [$with_systemdsystemunitdir])
AM_CONDITIONAL(HAVE_SYSTEMD, [test -n "$with_systemdsystemunitdir"])
AC_ARG_WITH([udevdir],
AS_HELP_STRING([--with-udevdir=DIR], [Directory for udev files]),
[], [with_udevdir=$prefix/lib/udev])
AC_SUBST([UDEVDIR], [$with_udevdir])
AM_CONDITIONAL(HAVE_UDEV, [test -n "$with_udevdir"])
AC_ARG_VAR([XMLTO], [Path to xmlto command])
AC_PATH_PROG([XMLTO], [xmlto])
AC_ARG_VAR([ASCIIDOC], [Path to asciidoc command])
AC_PATH_PROG([ASCIIDOC], [asciidoc])
AM_CONDITIONAL([HAVE_DOCTOOLS], [test "x$XMLTO" != "x" && test "x$ASCIIDOC" != "x"])
if test "x$XMLTO" = "x" || test "x$ASCIIDOC" = "x"; then
AC_MSG_WARN([xmlto or asciidoc not found - cannot create man pages without it])
fi
AC_ARG_WITH([buildid],
AS_HELP_STRING([--with-buildid=id], [Set additional build version details]))
AC_DEFINE_UNQUOTED([BUILDID], "$with_buildid", [Build version details])
if test "x$with_buildid" != x; then
AC_SUBST([BUILDID], "-$with_buildid")
fi
major=`echo $PACKAGE_VERSION | cut -d. -f1`
minor=`echo $PACKAGE_VERSION | cut -d. -f2`
micro=`echo $PACKAGE_VERSION | cut -d. -f3 | cut -d- -f1`
buildid=`echo $with_buildid | cut -d. -f1`
if test "x$buildid" = x; then
buildid=0
fi
build=`expr $micro \* 256 + $buildid`
WINDOWS_PRODUCTVERSION="$major.$minor.$build"
AC_SUBST([WINDOWS_PRODUCTVERSION])
case "$host" in
amd64*|x86_64*)
WIXL_ARCH="x64"
;;
*)
WIXL_ARCH="x86"
;;
esac
AC_SUBST(WIXL_ARCH)
AC_CONFIG_FILES([
Makefile
chezdav.wxs
libphodav-2.0.pc
doc/Makefile
doc/reference/Makefile
doc/reference/phodav-docs.sgml
libphodav/Makefile
po/Makefile.in
spice-webdavd.wxs
spice/Makefile
])
AC_OUTPUT
dnl ==========================================================================
AC_MSG_NOTICE([
$PACKAGE $VERSION
=================
prefix: $prefix
c compiler: $CC
Avahi: $have_avahi
])
SUBDIRS = reference
MAN1_TXT = chezdav.txt
if HAVE_DOCTOOLS
# Manual pages are generated from .txt via Docbook
man1_MANS = ${MAN1_TXT:%.txt=%.1}
SUFFIXES = .txt .xml .1
.xml.1:
$(XMLTO) man $< 2>&1
.txt.xml:
$(ASCIIDOC) --backend=docbook --doctype=manpage -o $@ $<
endif
EXTRA_DIST = $(MAN1_TXT)
CLEANFILES = $(man1_MANS)
-include $(top_srcdir)/git.mk
NULL =
AUTOMAKE_OPTIONS = 1.6
DOC_MODULE = phodav-2.0
DOC_MAIN_SGML_FILE = $(DOC_MODULE)-docs.sgml
DOC_SOURCE_DIR = $(top_srcdir)/libphodav
SCANGOBJ_OPTIONS =
SCAN_OPTIONS = --rebuild-types
MKDB_OPTIONS = --xml-mode --output-format=xml
MKTMPL_OPTIONS =
MKHTML_OPTIONS =
FIXXREF_OPTIONS =
# Used for dependencies. The docs will be rebuilt if any of these change.
HFILE_GLOB = $(top_srcdir)/libphodav/phodav-*.h
CFILE_GLOB = $(top_srcdir)/libphodav/phodav-*.c
EXTRA_HFILES =
IGNORE_HFILES = \
guuid.h \
glib-compat.h \
phodav-priv.h \
phodav-utils.h \
phodav-lock.h \
phodav-multistatus.h \
phodav-path.h \
$(NULL)
GTKDOC_CFLAGS = $(SOUP_CFLAGS)
GTKDOC_LIBS = $(top_builddir)/libphodav-2.0.la
include $(top_srcdir)/gtk-doc.make
EXTRA_DIST += phodav-docs.sgml.in
DISTCLEANFILES = $(DOC_MODULE).types
if ENABLE_GTK_DOC
TESTS_ENVIRONMENT = cd $(srcdir) && \
DOC_MODULE=$(DOC_MODULE) DOC_MAIN_SGML_FILE=$(DOC_MAIN_SGML_FILE) \
SRCDIR=$(abs_srcdir) BUILDDIR=$(abs_builddir)
#TESTS = $(GTKDOC_CHECK)
endif
-include $(top_srcdir)/git.mk
# git.mk, a small Makefile to autogenerate .gitignore files
# for autotools-based projects.
#
# Copyright 2009, Red Hat, Inc.
# Copyright 2010,2011,2012,2013 Behdad Esfahbod
# Written by Behdad Esfahbod
#
# Copying and distribution of this file, with or without modification,
# is permitted in any medium without royalty provided the copyright
# notice and this notice are preserved.
#
# The latest version of this file can be downloaded from:
GIT_MK_URL = https://raw.githubusercontent.com/behdad/git.mk/master/git.mk
#
# Bugs, etc, should be reported upstream at:
# https://github.com/behdad/git.mk
#
# To use in your project, import this file in your git repo's toplevel,
# then do "make -f git.mk". This modifies all Makefile.am files in
# your project to -include git.mk. Remember to add that line to new
# Makefile.am files you create in your project, or just rerun the
# "make -f git.mk".
#
# This enables automatic .gitignore generation. If you need to ignore
# more files, add them to the GITIGNOREFILES variable in your Makefile.am.
# But think twice before doing that. If a file has to be in .gitignore,
# chances are very high that it's a generated file and should be in one
# of MOSTLYCLEANFILES, CLEANFILES, DISTCLEANFILES, or MAINTAINERCLEANFILES.
#
# The only case that you need to manually add a file to GITIGNOREFILES is
# when remove files in one of mostlyclean-local, clean-local, distclean-local,
# or maintainer-clean-local make targets.
#
# Note that for files like editor backup, etc, there are better places to
# ignore them. See "man gitignore".
#
# If "make maintainer-clean" removes the files but they are not recognized
# by this script (that is, if "git status" shows untracked files still), send
# me the output of "git status" as well as your Makefile.am and Makefile for
# the directories involved and I'll diagnose.
#
# For a list of toplevel files that should be in MAINTAINERCLEANFILES, see
# Makefile.am.sample in the git.mk git repo.
#
# Don't EXTRA_DIST this file. It is supposed to only live in git clones,
# not tarballs. It serves no useful purpose in tarballs and clutters the
# build dir.
#
# This file knows how to handle autoconf, automake, libtool, gtk-doc,
# gnome-doc-utils, yelp.m4, mallard, intltool, gsettings, dejagnu, appdata,
# appstream, hotdoc.
#
# This makefile provides the following targets:
#
# - all: "make all" will build all gitignore files.
# - gitignore: makes all gitignore files in the current dir and subdirs.
# - .gitignore: make gitignore file for the current dir.
# - gitignore-recurse: makes all gitignore files in the subdirs.
#
# KNOWN ISSUES:
#
# - Recursive configure doesn't work as $(top_srcdir)/git.mk inside the
# submodule doesn't find us. If you have configure.{in,ac} files in
# subdirs, add a proxy git.mk file in those dirs that simply does:
# "include $(top_srcdir)/../git.mk". Add more ..'s to your taste.
# And add those files to git. See vte/gnome-pty-helper/git.mk for
# example.
#
###############################################################################
# Variables user modules may want to add to toplevel MAINTAINERCLEANFILES:
###############################################################################
#
# Most autotools-using modules should be fine including this variable in their
# toplevel MAINTAINERCLEANFILES:
GITIGNORE_MAINTAINERCLEANFILES_TOPLEVEL = \
$(srcdir)/aclocal.m4 \
$(srcdir)/autoscan.log \
$(srcdir)/configure.scan \
`AUX_DIR=$(srcdir)/$$(cd $(top_srcdir); $(AUTOCONF) --trace 'AC_CONFIG_AUX_DIR:$$1' ./configure.ac); \
test "x$$AUX_DIR" = "x$(srcdir)/" && AUX_DIR=$(srcdir); \
for x in \
ar-lib \
compile \
config.guess \
config.rpath \
config.sub \
depcomp \
install-sh \
ltmain.sh \
missing \
mkinstalldirs \
test-driver \
ylwrap \
; do echo "$$AUX_DIR/$$x"; done` \
`cd $(top_srcdir); $(AUTOCONF) --trace 'AC_CONFIG_HEADERS:$$1' ./configure.ac | \
head -n 1 | while read f; do echo "$(srcdir)/$$f.in"; done`
#
# All modules should also be fine including the following variable, which
# removes automake-generated Makefile.in files:
GITIGNORE_MAINTAINERCLEANFILES_MAKEFILE_IN = \
`cd $(top_srcdir); $(AUTOCONF) --trace 'AC_CONFIG_FILES:$$1' ./configure.ac | \
while read f; do \
case $$f in Makefile|*/Makefile) \
test -f "$(srcdir)/$$f.am" && echo "$(srcdir)/$$f.in";; esac; \
done`
#
# Modules that use libtool and use AC_CONFIG_MACRO_DIR() may also include this,
# though it's harmless to include regardless.
GITIGNORE_MAINTAINERCLEANFILES_M4_LIBTOOL = \
`MACRO_DIR=$(srcdir)/$$(cd $(top_srcdir); $(AUTOCONF) --trace 'AC_CONFIG_MACRO_DIR:$$1' ./configure.ac); \
if test "x$$MACRO_DIR" != "x$(srcdir)/"; then \
for x in \
libtool.m4 \
ltoptions.m4 \
ltsugar.m4 \
ltversion.m4 \
lt~obsolete.m4 \
; do echo "$$MACRO_DIR/$$x"; done; \
fi`
###############################################################################
# Default rule is to install ourselves in all Makefile.am files:
###############################################################################
git-all: git-mk-install
git-mk-install:
@echo "Installing git makefile"
@any_failed=; \
find "`test -z "$(top_srcdir)" && echo . || echo "$(top_srcdir)"`" -name Makefile.am | while read x; do \
if grep 'include .*/git.mk' $$x >/dev/null; then \
echo "$$x already includes git.mk"; \
else \
failed=; \
echo "Updating $$x"; \
{ cat $$x; \
echo ''; \
echo '-include $$(top_srcdir)/git.mk'; \
} > $$x.tmp || failed=1; \
if test x$$failed = x; then \
mv $$x.tmp $$x || failed=1; \
fi; \
if test x$$failed = x; then : else \
echo "Failed updating $$x"; >&2 \
any_failed=1; \
fi; \
fi; done; test -z "$$any_failed"
git-mk-update:
wget $(GIT_MK_URL) -O $(top_srcdir)/git.mk
.PHONY: git-all git-mk-install git-mk-update
###############################################################################
# Actual .gitignore generation:
###############################################################################
$(srcdir)/.gitignore: Makefile.am $(top_srcdir)/git.mk
@echo "git.mk: Generating $@"
@{ \
if test "x$(DOC_MODULE)" = x -o "x$(DOC_MAIN_SGML_FILE)" = x; then :; else \
for x in \
$(DOC_MODULE)-decl-list.txt \
$(DOC_MODULE)-decl.txt \
tmpl/$(DOC_MODULE)-unused.sgml \
"tmpl/*.bak" \
$(REPORT_FILES) \
$(DOC_MODULE).pdf \
xml html \
; do echo "/$$x"; done; \
FLAVOR=$$(cd $(top_srcdir); $(AUTOCONF) --trace 'GTK_DOC_CHECK:$$2' ./configure.ac); \