Makefile.am 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. csadir = $(includedir)/csa
  2. MAINTAINERCLEANFILES = Makefile.in
  3. lib_LTLIBRARIES = libcsa.la
  4. libcsa_la_CFLAGS = -DRFC_MIME -DLINE_COUNT -DV2 -DOW_I18N \
  5. $(CSA_INCDIR)
  6. libcsa_la_LIBADD = $(XTOOLLIB) $(TIRPCLIB)
  7. # in order to try to keep lib versions the same across platforms, (2.1.0)
  8. if BSD
  9. libcsa_la_LDFLAGS = -version-info 2:1:0
  10. else
  11. libcsa_la_LDFLAGS = -version-info 3:0:1
  12. endif
  13. if LINUX
  14. else
  15. libcsa_la_LIBADD += $(LIBSVC) $(XTOOLLIB)
  16. endif
  17. AM_YFLAGS = -d
  18. GENERATED_SRCS = agent_xdr.c cm_clnt.c reparser.c reparser.h \
  19. rtable2_clnt.c rtable2_xdr.c rtable3_clnt.c rtable3_xdr.c \
  20. rtable4_clnt.c rtable4_xdr.c agent.h
  21. BUILT_SOURCES = $(GENERATED_SRCS)
  22. CLEANFILES = $(GENERATED_SRCS) y.tab.c y.tab.h
  23. libcsa_la_SOURCES = agent.c agent_xdr.c api.c \
  24. appt4.c attr.c calendar.c \
  25. cm_clnt.c cmcbxdr.c cmsdata.c \
  26. cmxdr.c connection.c convert2-4.c \
  27. convert3-4.c convert4-2.c convert4-3.c \
  28. convert4-5.c convert5-4.c debug.c \
  29. entry.c free.c hash.c \
  30. iso8601.c laccess.c lutil.c \
  31. match.c nametbl.c refree.c \
  32. reparser.c rescan.c rpccalls.c \
  33. rtable2_clnt.c rtable2_xdr.c rtable3_clnt.c \
  34. rtable3_xdr.c rtable4_clnt.c rtable4_xdr.c \
  35. table.c updateattrs.c xtclient.c \
  36. ansi_c.c
  37. reparser.c reparser.h: reparser.y
  38. $(YACC) $(AM_YFLAGS) $<
  39. sed -e s/yyparse/_DtCm_rule_parser/g -e s/yy/_DtCm_yy/g y.tab.c > reparser.c
  40. sed s/yy/_DtCm_yy/g y.tab.h > reparser.h
  41. rtable2_clnt.c rtable3_clnt.c rtable4_clnt.c cm_clnt.c:
  42. $(RM) $@
  43. cat EUSinclude > $@
  44. rpcgen -l $(@:_clnt.c=.x) | sed -f namechange1.sed | sed -f namechange2.sed >> $@
  45. rtable2_xdr.c rtable3_xdr.c rtable4_xdr.c agent_xdr.c:
  46. $(RM) $@
  47. cat EUSinclude > $(@:.x=_xdr.c)
  48. rpcgen -c $(@:_xdr.c=.x) | sed -f namechange1.sed | sed -f namechange2.sed >> $(@:.x=_xdr.c)
  49. rtable4_clnt.c rtable4_xdr.c: rtable4.h namechange1.sed namechange2.sed
  50. rtable3_clnt.c rtable3_xdr.c: rtable3.h namechange1.sed namechange2.sed
  51. rtable2_clnt.c rtable2_xdr.c: rtable3.h namechange1.sed namechange2.sed
  52. agent_xdr.c agent.c: agent.h
  53. agent.h:
  54. $(RM) $@
  55. cat agent.wrapbegin > agent.h
  56. rpcgen -h agent.x | $(SED) -f namechange1.sed | $(SED) -f namechange2.sed >> agent.h
  57. cat agent.wrapend >> agent.h