Move Makefiles to Makefile.in
[openssl.git] / engines / ccgost / Makefile.in
1 DIR=ccgost
2 TOP=../..
3 CC=cc
4 INCLUDES= -I../../include
5 CFLAG=-g
6 MAKEFILE= Makefile
7 AR= ar r
8 CFLAGS= $(INCLUDES) $(CFLAG)
9 LIB=$(TOP)/libcrypto.a
10
11 LIBSRC= gost2001.c gost2001_keyx.c gost89.c gost_ameth.c gost_asn1.c gost_crypt.c gost_ctl.c gost_eng.c gosthash.c gost_keywrap.c gost_md.c gost_pmeth.c gost_params.c
12
13 LIBOBJ= e_gost_err.o gost2001_keyx.o gost2001.o gost89.o gost_ameth.o gost_asn1.o gost_crypt.o gost_ctl.o gost_eng.o gosthash.o gost_keywrap.o gost_md.o gost_pmeth.o gost_params.o
14
15 SRC=$(LIBSRC)
16
17 LIBNAME=gost
18
19 top: 
20         (cd $(TOP); $(MAKE) DIRS=engines sub_all)
21
22 all: lib
23
24 tags:
25         ctags $(SRC)
26
27 errors:
28         $(PERL) ../../util/mkerr.pl -conf gost.ec -nostatic -write $(SRC)
29
30 lib: $(LIBOBJ)
31         if [ -n "$(SHARED_LIBS)" ]; then \
32                 $(MAKE) -f $(TOP)/Makefile.shared -e \
33                         LIBNAME=$(LIBNAME) \
34                         LIBEXTRAS='$(LIBOBJ)' \
35                         LIBDEPS='-L$(TOP) -lcrypto' \
36                         link_o.$(SHLIB_TARGET); \
37         else \
38                 $(AR) $(LIB) $(LIBOBJ); \
39         fi
40         @touch lib
41
42 install:
43         [ -n "$(INSTALLTOP)" ] # should be set by top Makefile...
44         if [ -n "$(SHARED_LIBS)" ]; then \
45                 set -e; \
46                 echo installing $(LIBNAME); \
47                 pfx=lib; \
48                 if expr "$(PLATFORM)" : "Cygwin" >/dev/null; then \
49                         sfx=".so"; \
50                         cp cyg$(LIBNAME).dll $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/engines/$${pfx}$(LIBNAME)$$sfx.new; \
51                 else \
52                         case "$(CFLAGS)" in \
53                         *DSO_DLFCN*) sfx=`expr "$(SHLIB_EXT)" : '.*\(\.[a-z][a-z]*\)' \| ".so"`;; \
54                         *DSO_DL*) sfx=".sl";; \
55                         *DSO_WIN32*) sfx="eay32.dll"; pfx=;; \
56                         *) sfx=".bad";; \
57                         esac; \
58                         cp $${pfx}$(LIBNAME)$$sfx $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/engines/$${pfx}$(LIBNAME)$$sfx.new; \
59                 fi; \
60                 chmod 555 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/engines/$${pfx}$(LIBNAME)$$sfx.new; \
61                 mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/engines/$${pfx}$(LIBNAME)$$sfx.new $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/engines/$${pfx}$(LIBNAME)$$sfx; \
62         fi
63
64 tests:
65
66 update: local_depend
67         @if [ -z "$(THIS)" ]; then $(MAKE) -f $(TOP)/Makefile reflect THIS=$@; fi
68
69 depend: local_depend
70         @if [ -z "$(THIS)" ]; then $(MAKE) -f $(TOP)/Makefile reflect THIS=$@; fi
71 local_depend:
72         @[ -z "$(THIS)" ] || $(MAKEDEPEND) -- $(CFLAG) $(INCLUDES) $(DEPFLAG) -- $(PROGS) $(LIBSRC)
73
74 files:
75         $(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO
76
77 lint:
78         lint -DLINT $(INCLUDES) $(SRC)>fluff
79
80 dclean:
81         $(PERL) -pe 'if (/^# DO NOT DELETE THIS LINE/) {print; exit(0);}' $(MAKEFILE) >Makefile.new
82         mv -f Makefile.new $(MAKEFILE)
83
84 clean:
85         rm -f *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff *.so *.sl *.dll *.dylib
86
87 # DO NOT DELETE THIS LINE -- make depend depends on it.