Makefile.am 1.21 KB
Newer Older
Thomas Leonard's avatar
Thomas Leonard committed
1
2
3
4
## Process this file with automake to produce Makefile.in

AUTOMAKE_OPTIONS = foreign

5
packagesdir = $(mimedir)/packages
6
packages_DATA = freedesktop.org.xml
Thomas Leonard's avatar
Thomas Leonard committed
7

8
9
10
bin_PROGRAMS = update-mime-database
update_mime_database_SOURCES = update-mime-database.c

Thomas Leonard's avatar
Thomas Leonard committed
11
12
man_MANS = update-mime-database.1

13
EXTRA_DIST = config.rpath  shared-mime-info-spec.xml $(packages_DATA) README $(man_MANS)
14
15
16

CFLAGS = @CFLAGS@ `@PKG_CONFIG@ --cflags libxml-2.0 glib-2.0`
LDFLAGS = @LDFLAGS@ `@PKG_CONFIG@ --libs libxml-2.0 glib-2.0`
17

18
19
20
@INTLTOOL_XML_RULE@
@INTLTOOL_DESKTOP_RULE@

21
install-data-hook:
Thomas Leonard's avatar
Thomas Leonard committed
22
23
24
	"${bindir}/update-mime-database" "${mimedir}"

uninstall-hook:
25
26
27
	for media in text application image audio inode video message model multipart; do rm -f "${mimedir}/$${media}/"*.xml; done
	rm -f "${mimedir}/globs"
	rm -f "${mimedir}/magic"
28
29
30

check:
	xmllint --noout --valid $(srcdir)/freedesktop.org.xml
31
32
33
34
35
36
37
38
39
40

SUBDIRS = m4

ACLOCAL_AMFLAGS = -I m4

all-local:
	if locale | grep -q UTF; then echo "intltool doesn't like UTF-8 locales.  Try rerunning with eg: LANG=en_US"; /bin/rm -f freedesktop.org.xml; exit 1; fi

dist-hook:
	if locale | grep -q UTF; then echo "intltool doesn't like UTF-8 locales.  Try rerunning with eg: LANG=en_US"; /bin/rm -f freedesktop.org.xml; exit 1; fi