hivex: Reimplement hivexget as a simple shell script.
[libguestfs.git] / hivex / Makefile.am
1 # libguestfs
2 # Copyright (C) 2009 Red Hat 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 of the License, or
7 # (at your option) 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, write to the Free Software
16 # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17
18 EXTRA_DIST = hivex.pod hivexml.pod hivexget.pod hivexsh.pod LICENSE
19
20 lib_LTLIBRARIES = libhivex.la
21
22 libhivex_la_SOURCES = \
23   hivex.c \
24   hivex.h
25
26 libhivex_la_LDFLAGS = -version-info 0:0:0
27 libhivex_la_CFLAGS = \
28   $(WARN_CFLAGS) $(WERROR_CFLAGS)
29
30 bin_PROGRAMS = hivexml hivexsh
31 bin_SCRIPTS = hivexget
32
33 hivexml_SOURCES = \
34   hivexml.c
35
36 hivexml_LDADD = libhivex.la $(LIBXML2_LIBS)
37 hivexml_CFLAGS = \
38   -I$(top_srcdir)/src \
39   -DLOCALEBASEDIR=\""$(datadir)/locale"\" \
40   $(LIBXML2_CFLAGS) \
41   $(WARN_CFLAGS) $(WERROR_CFLAGS)
42
43 hivexsh_SOURCES = \
44   hivexsh.c
45
46 hivexsh_LDADD = libhivex.la ../gnulib/lib/libgnu.la  $(LIBREADLINE)
47 hivexsh_CFLAGS = \
48   -I$(top_srcdir)/gnulib/lib \
49   -I$(top_srcdir)/src \
50   -DLOCALEBASEDIR=\""$(datadir)/locale"\" \
51   $(WARN_CFLAGS) $(WERROR_CFLAGS)
52
53 man_MANS = hivex.3 hivexml.1 hivexget.1 hivexsh.1
54
55 hivex.3: hivex.pod
56         $(POD2MAN) \
57           --section 3 \
58           -c "Windows Registry" \
59           --name "hivex" \
60           --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \
61           $< > $@-t; mv $@-t $@
62
63 hivexml.1: hivexml.pod
64         $(POD2MAN) \
65           --section 1 \
66           -c "Windows Registry" \
67           --name "hivexml" \
68           --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \
69           $< > $@-t; mv $@-t $@
70
71 hivexget.1: hivexget.pod
72         $(POD2MAN) \
73           --section 1 \
74           -c "Windows Registry" \
75           --name "hivexget" \
76           --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \
77           $< > $@-t; mv $@-t $@
78
79 hivexsh.1: hivexsh.pod
80         $(POD2MAN) \
81           --section 1 \
82           -c "Windows Registry" \
83           --name "hivexsh" \
84           --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \
85           $< > $@-t; mv $@-t $@
86
87 noinst_DATA = \
88         $(top_builddir)/html/hivex.3.html \
89         $(top_builddir)/html/hivexml.1.html \
90         $(top_builddir)/html/hivexget.1.html \
91         $(top_builddir)/html/hivexsh.1.html
92
93 $(top_builddir)/html/hivex.3.html: hivex.pod
94         mkdir -p $(top_builddir)/html
95         cd $(top_builddir) && pod2html \
96           --css 'pod.css' \
97           --htmldir html \
98           --outfile html/hivex.3.html \
99           hivex/hivex.pod
100
101 $(top_builddir)/html/hivexml.1.html: hivexml.pod
102         mkdir -p $(top_builddir)/html
103         cd $(top_builddir) && pod2html \
104           --css 'pod.css' \
105           --htmldir html \
106           --outfile html/hivexml.1.html \
107           hivex/hivexml.pod
108
109 $(top_builddir)/html/hivexget.1.html: hivexget.pod
110         mkdir -p $(top_builddir)/html
111         cd $(top_builddir) && pod2html \
112           --css 'pod.css' \
113           --htmldir html \
114           --outfile html/hivexget.1.html \
115           hivex/hivexget.pod
116
117 $(top_builddir)/html/hivexsh.1.html: hivexsh.pod
118         mkdir -p $(top_builddir)/html
119         cd $(top_builddir) && pod2html \
120           --css 'pod.css' \
121           --htmldir html \
122           --outfile html/hivexsh.1.html \
123           hivex/hivexsh.pod