提交 1e3d16b0 编写于 作者: R Richard Levitte

Don't make a difference between building test programs and other programs

This adds a new target 'build_programs' and makes 'build_apps' and
'build_tests' aliases for it, for backward compatibility.
Reviewed-by: NRich Salz <rsalz@openssl.org>
上级 7218ae51
......@@ -44,8 +44,6 @@
# we store them in arrays for reuse
our @shlibs = map { $unified_info{sharednames}->{$_} || () } @{$unified_info{libraries}};
our @install_shlibs = map { $unified_info{sharednames}->{$_} || () } @{$unified_info{install}->{libraries}};
our @programs = grep { !m|^\[\.test\]| } @{$unified_info{programs}};
our @testprogs = grep { m|^\[\.test\]| } @{$unified_info{programs}};
our @generated = ( ( map { (my $x = $_) =~ s|\.S$|\.s|; $x }
grep { defined $unified_info{generate}->{$_} }
map { @{$unified_info{sources}->{$_}} }
......@@ -119,8 +117,7 @@ DEP_EXT=.D
LIBS={- join(", ", map { "-\n\t".$_.".OLB" } @{$unified_info{libraries}}) -}
SHLIBS={- join(", ", map { "-\n\t".$_.".EXE" } @shlibs) -}
ENGINES={- join(", ", map { "-\n\t".$_.".EXE" } @{$unified_info{engines}}) -}
PROGRAMS={- join(", ", map { "-\n\t".$_.".EXE" } @programs) -}
TESTPROGS={- join(", ", map { "-\n\t".$_.".EXE" } @testprogs) -}
PROGRAMS={- join(", ", map { "-\n\t".$_.".EXE" } @{$unified_info{programs}}) -}
SCRIPTS={- join(", ", map { "-\n\t".$_ } @{$unified_info{scripts}}) -}
{- output_off() if $disabled{makedepend}; "" -}
DEPS={- our @deps = map { (my $x = $_) =~ s|\.o$|\$(DEP_EXT)|; $x; }
......@@ -245,22 +242,22 @@ NODEBUG=@
# The main targets ###################################################
all : build_generated, -
build_libs_nodep, build_engines_nodep, build_apps_nodep, -
build_libs_nodep, build_engines_nodep, build_programs_nodep, -
depend
build_libs : build_generated, build_libs_nodep, depend
build_libs_nodep : $(LIBS), $(SHLIBS)
build_engines : build_generated, build_engines_nodep, depend
build_engines_nodep : $(ENGINES)
build_apps : build_generated, build_apps_nodep, depend
build_apps_nodep : $(PROGRAMS), $(SCRIPTS)
build_tests : build_generated, build_tests_nodep, depend
build_tests_nodep : $(TESTPROGS)
build_programs : build_generated, build_programs_nodep, depend
build_programs_nodep : $(PROGRAMS), $(SCRIPTS)
build_generated : $(GENERATED_MANDATORY)
test tests : build_generated, -
build_apps_nodep, build_engines_nodep, build_tests_nodep, -
# Kept around for backward compatibility
build_apps build_tests : build_programs
test tests : build_generated, build_programs_nodep, build_engines_nodep, -
depend
@ ! {- output_off() if $disabled{tests}; "" -}
SET DEFAULT [.test]{- move("test") -}
......@@ -317,14 +314,13 @@ check_install :
uninstall : uninstall_docs uninstall_sw
# Because VMS wants the generation number (or *) to delete files, we can't
# use $(LIBS), $(PROGRAMS), $(GENERATED), $(ENGINES) and $(TESTPROGS) directly.
# use $(LIBS), $(PROGRAMS), $(GENERATED) and $(ENGINES)directly.
libclean :
{- join("\n\t", map { "- DELETE $_.OLB;*" } @{$unified_info{libraries}}) || "@ !" -}
{- join("\n\t", map { "- DELETE $_.EXE;*,$_.MAP;*,$_.OPT;*" } @shlibs) || "@ !" -}
clean : libclean
{- join("\n\t", map { "- DELETE $_.EXE;*,$_.OPT;*" } @programs) || "@ !" -}
{- join("\n\t", map { "- DELETE $_.EXE;*,$_.OPT;*" } @testprogs) || "@ !" -}
{- join("\n\t", map { "- DELETE $_.EXE;*,$_.OPT;*" } @{$unified_info{programs}}) || "@ !" -}
{- join("\n\t", map { "- DELETE $_.EXE;*,$_.OPT;*" } @{$unified_info{engines}}) || "@ !" -}
{- join("\n\t", map { "- DELETE $_;*" } @{$unified_info{scripts}}) || "@ !" -}
{- join("\n\t", map { "- DELETE $_;*" } @generated) || "@ !" -}
......
......@@ -88,8 +88,7 @@ LIBS={- join(" ", map { $_.$libext } @{$unified_info{libraries}}) -}
SHLIBS={- join(" ", map { shlib($_) } @{$unified_info{libraries}}) -}
SHLIB_INFO={- join(" ", map { "\"".shlib($_).";".shlib_simple($_)."\"" } @{$unified_info{libraries}}) -}
ENGINES={- join(" ", map { dso($_) } @{$unified_info{engines}}) -}
PROGRAMS={- join(" ", map { $_.$exeext } grep { !m|^test/| } @{$unified_info{programs}}) -}
TESTPROGS={- join(" ", map { $_.$exeext } grep { m|^test/| } @{$unified_info{programs}}) -}
PROGRAMS={- join(" ", map { $_.$exeext } @{$unified_info{programs}}) -}
SCRIPTS={- join(" ", @{$unified_info{scripts}}) -}
{- output_off() if $disabled{makedepend}; "" -}
DEPS={- join(" ", map { (my $x = $_) =~ s|\.o$|$depext|; $x; }
......@@ -225,21 +224,21 @@ PROCESSOR= {- $config{processor} -}
# The main targets ###################################################
{- dependmagic('all'); -}: build_libs_nodep build_engines_nodep build_apps_nodep link-utils
{- dependmagic('all'); -}: build_libs_nodep build_engines_nodep build_programs_nodep link-utils
{- dependmagic('build_libs'); -}: build_libs_nodep
{- dependmagic('build_engines'); -}: build_engines_nodep
{- dependmagic('build_apps'); -}: build_apps_nodep
{- dependmagic('build_tests'); -}: build_tests_nodep
{- dependmagic('build_programs'); -}: build_programs_nodep
build_generated: $(GENERATED_MANDATORY)
build_libs_nodep: libcrypto.pc libssl.pc openssl.pc
build_engines_nodep: $(ENGINES)
build_apps_nodep: $(PROGRAMS) $(SCRIPTS)
build_tests_nodep: $(TESTPROGS)
build_programs_nodep: $(PROGRAMS) $(SCRIPTS)
# Kept around for backward compatibility
build_apps build_tests: build_programs
test: tests
{- dependmagic('tests'); -}: build_tests_nodep build_apps_nodep \
build_engines_nodep link-utils
{- dependmagic('tests'); -}: build_programs_nodep build_engines_nodep link-utils
@ : {- output_off() if $disabled{tests}; "" -}
( cd test; \
SRCTOP=../$(SRCDIR) \
......
......@@ -65,9 +65,8 @@ SHLIBS={- join(" ", map { shlib($_) } @{$unified_info{libraries}}) -}
SHLIBPDBS={- join(" ", map { local $shlibext = ".pdb"; shlib($_) } @{$unified_info{libraries}}) -}
ENGINES={- join(" ", map { dso($_) } @{$unified_info{engines}}) -}
ENGINEPDBS={- join(" ", map { local $dsoext = ".pdb"; dso($_) } @{$unified_info{engines}}) -}
PROGRAMS={- join(" ", map { $_.$exeext } grep { !m|^test\\| } @{$unified_info{programs}}) -}
PROGRAMPDBS={- join(" ", map { $_.".pdb" } grep { !m|^test\\| } @{$unified_info{programs}}) -}
TESTPROGS={- join(" ", map { $_.$exeext } grep { m|^test\\| } @{$unified_info{programs}}) -}
PROGRAMS={- join(" ", map { $_.$exeext } @{$unified_info{programs}}) -}
PROGRAMPDBS={- join(" ", map { $_.".pdb" } @{$unified_info{programs}}) -}
SCRIPTS={- join(" ", @{$unified_info{scripts}}) -}
{- output_off() if $disabled{makedepend}; "" -}
DEPS={- join(" ", map { (my $x = $_) =~ s|\.o$|$depext|; $x; }
......@@ -179,22 +178,22 @@ PROCESSOR= {- $config{processor} -}
# The main targets ###################################################
all: build_generated \
build_libs_nodep build_engines_nodep build_apps_nodep depend
build_libs_nodep build_engines_nodep build_programs_nodep depend
build_libs: build_generated build_libs_nodep depend
build_libs_nodep: $(LIBS) {- join(" ",map { shlib_import($_) } @{$unified_info{libraries}}) -}
build_engines: build_generated build_engines_nodep depend
build_engines_nodep: $(ENGINES)
build_apps: build_generated build_apps_nodep depend
build_apps_nodep: $(PROGRAMS) $(SCRIPTS)
build_tests: build_generated build_tests_nodep depend
build_tests_nodep: $(TESTPROGS)
build_programs: build_generated build_programs_nodep depend
build_programs_nodep: $(PROGRAMS) $(SCRIPTS)
build_generated: $(GENERATED_MANDATORY)
# Kept around for backward compatibility
build_apps build_tests: build_programs
test: tests
tests: build_generated \
build_tests_nodep build_apps_nodep build_engines_nodep depend
tests: build_generated build_programs_nodep build_engines_nodep depend
@rem {- output_off() if $disabled{tests}; "" -}
set SRCTOP=$(SRCDIR)
set BLDTOP=$(BLDDIR)
......@@ -224,7 +223,7 @@ libclean:
-del /Q ossl_static.pdb
clean: libclean
-del /Q /F $(PROGRAMS) $(TESTPROGS) $(ENGINES) $(SCRIPTS)
-del /Q /F $(PROGRAMS) $(ENGINES) $(SCRIPTS)
-del /Q /F $(GENERATED)
-del /Q /S /F *.d
-del /Q /S /F *.obj
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册