1## Process this file with automake to produce Makefile.in 2include $(top_srcdir)/include.mk 3 4FLEX ?= $(LEX) 5 6# This Makefile builds the IDL compiler 7 8# configure/automake adds the dcethread library to everything that is built in 9# this package. Most things need it, but the idl compiler doesn't, so we 10# remove the dcethread library from LIBS here. You might not expect 11# -ldcethread to stick during linking, but it does because it includes 12# implementations of some io functions. 13#LIBS=$(subst -ldcethread,,$(LIBS)) 14 15AM_CFLAGS+=-DMIA -DDEFAULT_IDIR=\"$(includedir)\" -DCATALOG_DIR=\"$(pkgdatadir)\" -DYYERROR_VERBOSE=1 -DYYDEBUG=1 16 17bin_PROGRAMS=dceidl 18 19pkgdata_DATA=idl.cat 20 21dceidl_SOURCES = acf_y.c acf_l.c nidl_y.c nidl_l.c astp_com.c astp_cpx.c \ 22 astp_gbl.c astp_sim.c astp_dmp.c checker.c chkichar.c command.c \ 23 driver.c errors.c files.c frontend.c getflags.c keywds.c main.c \ 24 message.c nametbl.c namdump.c propagat.c sysdep.c mtsbacke.c \ 25 ddbe.c ddspell.c cspeldcl.c cspell.c cstubmts.c hdgen.c clihamts.c \ 26 mtspipes.c irepgen.c irepscp.c ifspemts.c sstubmts.c comstmts.c \ 27 user_exc.c icharsup.c astp_exp.c \ 28 $(top_srcdir)/dcelib/strlcat.c \ 29 $(top_srcdir)/dcelib/strlcpy.c 30 31dceidl_LDFLAGS = @LTLDFLAGS@ 32 33noinst_HEADERS= ast.h astp.h astp_dmp.h backend.h be_pvt.h bedeck.h \ 34 checker.h chkichar.h clihamts.h clihandl.h command.h commstat.h cspeldcl.h \ 35 cspell.h cstubgen.h cstubmts.h ddbe.h default_msg.h driver.h dutils.h \ 36 errors.h fe_pvt.h files.h frontend.h genpipes.h \ 37 getflags.h hdgen.h icharsup.h ifspec.h ir_pvt.h irep.h marshall.h \ 38 message.h mtsbacke.h mtspipes.h nametbl.h namtbpvt.h nidl.h nidlmsg.h \ 39 propagat.h sstubmts.h sysdep.h user_exc.h 40 41BUILT_SOURCES=acf_y.c acf_l.c nidl_y.c nidl_l.c idl.cat 42 43# Override the standard YACC/LEX rules so we can build two scanners into 44# the idl compiler. 45 46acf_y.c acf_y.h: acf_y.y 47 $(BISON) -v $(AM_YFLAGS) $(YFLAGS) -p acf_yy -o acf_y.c -d $< 48 49acf_l.c acf_l.h: acf_l.l 50 $(FLEX) $(AM_LFLAGS) $(LFLAGS) -Pacf_yy -o$@ $< 51 52nidl_y.c nidl_y.h: nidl_y.y 53 $(BISON) -v $(AM_YFLAGS) $(YFLAGS) -p nidl_yy -o nidl_y.c -d $< 54 55nidl_l.c nidl_l.h: nidl_l.l 56 $(FLEX) $(AM_LFLAGS) $(LFLAGS) -Pnidl_yy -o$@ $< 57 58# Generate error message catalog for IDL compiler 59idl.cat default_msg.h: nidlmsg.m 60 $(RM) $(RMFLAGS) default_msg.h idl.cat 61 $(SED) -e '/^\$$/d;/^$$/d;s/^[^ ]* /"/;s/$$/",/;' $(srcdir)/nidlmsg.m > default_msg.h 62 $(GENCAT) -o idl.cat $(srcdir)/nidlmsg.m 63 64# Keep the generated parsers in the tarball 65EXTRA_DIST=nidlmsg.m acf_y.c acf_y.h acf_l.c nidl_y.c nidl_y.h nidl_l.c 66 67# Ensure that YACC/LEX generated files go away during clean 68CLEANFILES=acf_y.c acf_l.c acf_y.h nidl_y.c nidl_l.c nidl_y.h 69 70# TODO-dalmeida-2008/01/22-This DESTDIR/install-exec-local stuff looks suspicious 71DESTDIR = / 72 73install-exec-hook: 74 test -f $(DESTDIR)/$(bindir)/idl || $(LN_S) dceidl $(DESTDIR)/$(bindir)/idl 75 76