]> git.saurik.com Git - apple/security.git/blob - SecuritySNACCRuntime/tcl-asn/makefile
Security-54.1.tar.gz
[apple/security.git] / SecuritySNACCRuntime / tcl-asn / makefile
1 #
2 # Makefile for the asnwish
3 #
4 # $Header: /cvs/Darwin/Security/SecuritySNACCRuntime/tcl-asn/makefile,v 1.1.1.1 2001/05/18 23:14:10 mb Exp $
5 # $Log: makefile,v $
6 # Revision 1.1.1.1 2001/05/18 23:14:10 mb
7 # Move from private repository to open source repository
8 #
9 # Revision 1.1.1.1 1999/03/16 18:06:54 aram
10 # Originals from SMIME Free Library.
11 #
12 # Revision 1.3 1997/10/10 13:43:18 wan
13 # Corrected bug in generic table decoder wrt. indefinite length elements
14 # Corrected compiler access to freed memory (bug reported by Markku Savela)
15 # Broke asnwish.c into two pieces so that one can build ones on wish
16 # Added beredit tool (based on asnwish, allowes to edit BER messages)
17 #
18 # Revision 1.2 1997/09/03 12:13:13 wan
19 # Reworked asnwish to neither strip nor encapsulate; instead,
20 # buffer reads during decoding incrementally Tcl_Read the channel.
21 #
22 # Revision 1.1 1997/08/27 15:55:51 wan
23 # Added generic table decoding, debug routines, berdecode, and asnwish.
24 #
25 #
26
27 include ../makehead
28
29 TOP = ..
30
31 SNACC = $(TOP)/compiler/snacc
32
33 ASN1_SRC_DIR = $(TOP)/asn1specs
34 C_LIB = $(TOP)/c-lib
35 ASN1INC = $(C_LIB)/inc
36 ASN1LIB = $(C_LIB)/libasn1ctbl.a
37
38 CPPFLAGS += -I$(TOP) -I$(ASN1INC) $(CPPFLAGS.TCL) $(CPPFLAGS.X11)
39
40 OFILES = tclasn.o asnwish.o
41
42 DISTFILES = makefile tclasn.c asnwish.c README beredit
43
44 LDFLAGS += $(LDFLAGS.X11)
45 LDLIBS += $(ASN1LIB) $(TCLLIBS) $(LDLIBS.X11pre) -lX11 $(LDLIBS.X11extra) $(LIBS)
46
47 WISH = asnwish
48
49 #-------------------------------------------------------------------------------
50
51 all:: $(WISH)
52
53 $(WISH): $(OFILES) $(ASN1LIB)
54 $(REASON)
55 $(CC) $(LDFLAGS) -o $(WISH) $(OFILES) $(LDLIBS)
56
57 $(ASN1LIB)::
58 cd $(@D) && $(MAKE) tbl-lib
59
60 # if $(ASN1INC)/asn_useful.h doesn't exist, someone probably called `make clean` in $(C++_LIB).
61 $(ASN1INC)/asn-useful.h:
62 $(MAKE) $(ASN1LIB)
63
64 $(SNACC)::
65 cd $(@D) && $(MAKE) $(@F)
66
67 clean::
68 $(RM) $(ASN1HFILES) $(ASN1CFILES)
69 $(RM) $(OFILES)
70
71 clobber::
72 $(RM) $(WISH)
73
74 install-sh:
75 ln $(TOP)/install-sh $@
76
77 $(bindir):
78 $(TOP)/mkinstalldirs $@
79
80 install:: $(WISH) install-sh $(bindir)
81
82 init-depend::
83 test -f dependencies || touch dependencies
84
85 install::
86 $(INSTALL_PROGRAM) $(WISH) $(bindir)/
87 $(INSTALL_PROGRAM) beredit $(bindir)/
88 $(INSTALL_PROGRAM) tclasn.o $(libdir)/
89
90 include ../maketail