summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans Ulrich Niedermann <hun@n-dimensional.de>2011-03-04 13:19:49 +0100
committerHans Ulrich Niedermann <hun@n-dimensional.de>2011-03-07 20:42:59 +0100
commit540df925e9236755ac4812d5e94ca5997bd2dbe9 (patch)
tree90e84dd7da91440cd9956aff1b659a76a174d62f
parent59ad8b31be5bc63a5286571a99d5ab2d41f3c9c5 (diff)
downloadrasdaman-upstream-540df925e9236755ac4812d5e94ca5997bd2dbe9.tar.gz
rasdaman-upstream-540df925e9236755ac4812d5e94ca5997bd2dbe9.tar.xz
rasdaman-upstream-540df925e9236755ac4812d5e94ca5997bd2dbe9.zip
source/build: Fix rpcgen generated .h file #ifndef
The C preprocessor cannot properly handle the dot in the "#define _RPCIF.H_H_RPCGEN" macro rpcgen creates, so we change that to "#define _RPCIF_H_H_RPCGEN" instead.
-rw-r--r--clientcomm/Makefile.am9
1 files changed, 5 insertions, 4 deletions
diff --git a/clientcomm/Makefile.am b/clientcomm/Makefile.am
index dee8745..4aa5356 100644
--- a/clientcomm/Makefile.am
+++ b/clientcomm/Makefile.am
@@ -51,13 +51,14 @@ libclientcomm_a_CPPFLAGS=-I../rnprotocol
EXTRA_libclientcomm_a_SOURCES = rpcif.x
BUILT_SOURCES= rpcif_clnt.cc rpcif_xdr.c rpcif.h rpcif_svc.cc
-CLEANFILES=rpcif_clnt.cc rpcif_xdr.c rpcif.h rpcif.h.tmp rpcif_clnt.c.tmp \
- rpcif_svc.cc.tmp rpcif_svc.cc
+CLEANFILES=rpcif_clnt.cc rpcif_xdr.c rpcif.h rpcif.h.tmp rpcif.h.tmp2 \
+ rpcif_clnt.c.tmp rpcif_svc.cc.tmp rpcif_svc.cc
rpcif.h: rpcif.x
$(RPCGEN) -h -o rpcif.h.tmp rpcif.x
- $(AWK) -f rpcif.h.awk rpcif.h.tmp > rpcif.h
- rm rpcif.h.tmp
+ $(AWK) -f rpcif.h.awk rpcif.h.tmp > rpcif.h.tmp2
+ $(SED) 's,_RPCIF\.H_H_RPCGEN,_RPCIF_H_H_RPCGEN,g' rpcif.h.tmp2 > rpcif.h
+ rm rpcif.h.tmp rpcif.h.tmp2
rpcif_clnt.cc: rpcif.x
$(RPCGEN) -l -o rpcif_clnt.cc.tmp rpcif.x