Build environment set up for libguestfs.
[libguestfs.git] / nfs-utils-1.1.4-build.patch
1 This patch fixes nfs-utils to support nested builds in subdirectories
2 properly.
3
4  - Richard W.M. Jones (rjones@redhat.com)
5
6 diff -ur nfs-utils-1.1.4/support/export/Makefile.am nfs-utils-1.1.4.buildfix/support/export/Makefile.am
7 --- nfs-utils-1.1.4/support/export/Makefile.am  2008-10-17 15:20:09.000000000 +0100
8 +++ nfs-utils-1.1.4.buildfix/support/export/Makefile.am 2009-03-02 18:46:59.000000000 +0000
9 @@ -40,9 +40,9 @@
10  $(GENFILES_H): %.h: %.x $(RPCGEN)
11         test -f $@ && rm -rf $@ || true
12         $(RPCGEN) -h -o $@ $<
13 -       rm -f $(top_builddir)/support/include/mount.h
14 -       $(LN_S) ../export/mount.h $(top_builddir)/support/include/mount.h
15 +       rm -f $(top_srcdir)/support/export/mount.h
16 +       $(LN_S) $(abs_top_builddir)/support/export/mount.h $(top_srcdir)/support/export/mount.h
17  
18  MAINTAINERCLEANFILES = Makefile.in
19  
20 -CLEANFILES = $(GENFILES) $(top_builddir)/support/include/mount.h
21 +CLEANFILES = $(GENFILES) $(top_srcdir)/support/export/mount.h
22 diff -ur nfs-utils-1.1.4/utils/mount/Makefile.am nfs-utils-1.1.4.buildfix/utils/mount/Makefile.am
23 --- nfs-utils-1.1.4/utils/mount/Makefile.am     2008-10-17 15:20:09.000000000 +0100
24 +++ nfs-utils-1.1.4.buildfix/utils/mount/Makefile.am    2009-03-03 08:50:30.000000000 +0000
25 @@ -17,6 +17,8 @@
26                     parse_opt.h parse_dev.h \
27                     nfs4_mount.h nfs_mount4.h stropts.h version.h
28  
29 +mount_nfs_CFLAGS = -I$(top_builddir)/support/export
30 +
31  mount_nfs_LDADD = ../../support/nfs/libnfs.a \
32                   ../../support/export/libexport.a
33  
34 diff -ur nfs-utils-1.1.4/utils/statd/Makefile.am nfs-utils-1.1.4.buildfix/utils/statd/Makefile.am
35 --- nfs-utils-1.1.4/utils/statd/Makefile.am     2008-10-17 15:20:09.000000000 +0100
36 +++ nfs-utils-1.1.4.buildfix/utils/statd/Makefile.am    2009-03-02 18:49:10.000000000 +0000
37 @@ -51,10 +51,12 @@
38  $(GENFILES_H): %.h: %.x $(RPCGEN)
39         test -f $@ && rm -rf $@ || true
40         $(RPCGEN) -h -o $@ $<
41 +       rm -f $(top_srcdir)/utils/statd/sm_inter.h
42 +       $(LN_S) $(abs_top_builddir)/utils/statd/sm_inter.h $(top_srcdir)/utils/statd/sm_inter.h
43  
44  MAINTAINERCLEANFILES = Makefile.in
45  
46 -CLEANFILES = $(GENFILES)
47 +CLEANFILES = $(GENFILES) $(top_srcdir)/utils/statd/sm_inter.h
48  
49  #######################################################################
50  # The following allows the current practice of having