Imported Upstream version 1.9.4
[deb_libnfs.git] / nfs / Makefile.am
CommitLineData
dabf4152
AM
1noinst_LTLIBRARIES = libnfs.la
2
ee872606
RRS
3nfs_SOURCES_GENERATED =
4nfs_HEADERS_GENERATED =
dabf4152
AM
5nfs_GENERATED = $(nfs_SOURCES_GENERATED) $(nfs_HEADERS_GENERATED)
6
7CLEANFILES = $(nfs_GENERATED) nfs-stamp
8
ee872606
RRS
9libnfs_la_CPPFLAGS = -I$(abs_top_srcdir)/include \
10 -I$(abs_top_srcdir)/include/nfsc
dabf4152
AM
11libnfs_la_SOURCES = \
12 $(nfs_SOURCES_GENERATED) \
ee872606 13 nfs.c nfsacl.c libnfs-raw-nfs.c libnfs-raw-nfs.h
dabf4152
AM
14
15$(nfs_GENERATED) : nfs-stamp
16nfs-stamp : nfs.x
17 rm -f $(nfs_GENERATED)
dabf4152 18 touch nfs-stamp
ee872606
RRS
19
20compile_rpc:
f1f22dbf
RRS
21 cat nfs.x | head -29 >libnfs-raw-nfs.h
22 rpcgen -h nfs.x | sed -e "s/#include <rpc\/rpc.h>//" -e "s/xdr/zdr/g" -e "s/XDR/ZDR/g" -e "s/#define _NFS_H_RPCGEN/#define _NFS_H_RPCGEN\n#include <nfsc\/libnfs-zdr.h>/g" -e "s/#define NFS3_COOKIEVERFSIZE 8/#define NFS3_COOKIEVERFSIZE 8\n\n#if defined(ANDROID)\ntypedef long long int quad_t;\ntypedef long long unsigned u_quad_t;\n#endif\n#if defined(WIN32)\ntypedef long long int quad_t;\ntypedef long long unsigned u_quad_t;\n#endif/g" >> libnfs-raw-nfs.h
23 cat nfs.x | head -29 >libnfs-raw-nfs.c
24 rpcgen -c nfs.x | sed -e "s/#include \".*nfs.h\"/#include \"libnfs-xdr.h\"\n#include \"libnfs-raw-nfs.h\"/" -e "s/xdr/zdr/g" -e "s/XDR/ZDR/g" -e "s/register int32_t \*buf;/register int32_t *buf;\n buf = NULL;/" >> libnfs-raw-nfs.c