2016-01-30 14:14:58 +08:00
|
|
|
{- use File::Spec::Functions qw/catdir catfile/; -}
|
2016-01-30 06:33:10 +08:00
|
|
|
LIBS=../libcrypto
|
|
|
|
SOURCE[../libcrypto]=\
|
|
|
|
cryptlib.c mem.c mem_dbg.c cversion.c ex_data.c cpt_err.c \
|
2016-02-01 02:08:23 +08:00
|
|
|
ebcdic.c uid.c o_time.c o_str.c o_dir.c thr_id.c lock.c \
|
2016-02-09 19:09:10 +08:00
|
|
|
o_init.c o_fips.c mem_sec.c init.c {- $target{cpuid_asm_src} -}
|
2016-01-30 06:33:10 +08:00
|
|
|
EXTRA= ../ms/uplink-x86.pl ../ms/uplink.c ../ms/applink.c \
|
|
|
|
x86cpuid.pl x86_64cpuid.pl ia64cpuid.S \
|
|
|
|
ppccpuid.pl pariscid.pl alphacpuid.pl arm64cpuid.pl armv4cpuid.pl
|
|
|
|
|
|
|
|
DEPEND[cversion.o]=buildinf.h
|
2016-01-30 10:25:40 +08:00
|
|
|
|
2016-01-30 14:14:58 +08:00
|
|
|
BEGINRAW[descrip.mms]
|
|
|
|
[.crypto]buildinf.h : descrip.mms
|
|
|
|
$(PERL) {- catfile(catdir($sourcedir, "[-]"), "util", "mkbuildinf.pl") -} "$(CC) $(CFLAGS)" "$(PLATFORM)" > [.crypto]buildinf.h
|
|
|
|
ENDRAW[descrip.mms]
|
|
|
|
|
2016-01-30 10:25:40 +08:00
|
|
|
BEGINRAW[Makefile]
|
|
|
|
crypto/buildinf.h : Makefile
|
|
|
|
$(PERL) $(SRCDIR)/util/mkbuildinf.pl "$(CC) $(CFLAGS)" "$(PLATFORM)" > crypto/buildinf.h
|
|
|
|
|
|
|
|
##### APPLINK, UPLINK and CPUID assembler implementations
|
|
|
|
|
|
|
|
{- $builddir -}/applink.o: $(SRCDIR)/ms/applink.c
|
|
|
|
$(CC) $(CFLAGS) -c -o $@ $(TOP)/ms/applink.c
|
|
|
|
|
|
|
|
{- $builddir -}/uplink.o: $(SRCDIR)/ms/uplink.c {- $builddir -}/applink.o
|
|
|
|
$(CC) $(CFLAGS) -c -o $@ $(TOP)/ms/uplink.c
|
|
|
|
|
|
|
|
{- $builddir -}/uplink-x86.s: $(SRCDIR)/ms/uplink-x86.pl
|
|
|
|
$(PERL) $(TOP)/ms/uplink-x86.pl $(PERLASM_SCHEME) > $@
|
|
|
|
|
|
|
|
{- $builddir -}/x86cpuid.s: {- $sourcedir -}/x86cpuid.pl {- $sourcedir -}/perlasm/x86asm.pl
|
|
|
|
$(PERL) {- $sourcedir -}/x86cpuid.pl $(PERLASM_SCHEME) $(CFLAGS) $(PROCESSOR) > $@
|
|
|
|
|
|
|
|
{- $builddir -}/x86_64cpuid.s: {- $sourcedir -}/x86_64cpuid.pl
|
|
|
|
$(PERL) {- $sourcedir -}/x86_64cpuid.pl $(PERLASM_SCHEME) > $@
|
|
|
|
{- $builddir -}/ia64cpuid.s: {- $sourcedir -}/ia64cpuid.S
|
|
|
|
$(CC) $(CFLAGS) -E {- $sourcedir -}/ia64cpuid.S > $@
|
|
|
|
{- $builddir -}/ppccpuid.s: {- $sourcedir -}/ppccpuid.pl
|
|
|
|
$(PERL) {- $sourcedir -}/ppccpuid.pl $(PERLASM_SCHEME) $@
|
|
|
|
{- $builddir -}/pariscid.s: {- $sourcedir -}/pariscid.pl
|
|
|
|
$(PERL) {- $sourcedir -}/pariscid.pl $(PERLASM_SCHEME) $@
|
|
|
|
{- $builddir -}/alphacpuid.s: {- $sourcedir -}/alphacpuid.pl
|
|
|
|
(preproc=$$$$.$@.S; trap "rm $$preproc" INT; \
|
|
|
|
$(PERL) {- $sourcedir -}/alphacpuid.pl > $$preproc && \
|
|
|
|
$(CC) -E -P $$preproc > $@ && rm $$preproc)
|
|
|
|
{- $builddir -}/arm64cpuid.S: {- $sourcedir -}/arm64cpuid.pl
|
|
|
|
$(PERL) {- $sourcedir -}/arm64cpuid.pl $(PERLASM_SCHEME) > $@
|
|
|
|
{- $builddir -}/armv4cpuid.S: {- $sourcedir -}/armv4cpuid.pl
|
|
|
|
$(PERL) {- $sourcedir -}/armv4cpuid.pl $(PERLASM_SCHEME) > $@
|
|
|
|
ENDRAW[Makefile]
|