From c554e2168bbc7c89bd02768a45ce9a8c7dd57b43 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Tue, 17 Oct 2006 00:56:29 +0000 Subject: r19358: Use subunit tests from the right location (from $src/bin/torture when developing, $LIBDIR/torture when installed) (This used to be commit 4ae6380e6bb48e27e9947e149b3d079b3e293cc0) --- source4/build/smb_build/makefile.pm | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) (limited to 'source4/build/smb_build') diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm index 91ee7186a5..e44de5c5c1 100644 --- a/source4/build/smb_build/makefile.pm +++ b/source4/build/smb_build/makefile.pm @@ -110,9 +110,11 @@ sub _prepare_compiler_linker($) my $builddir_headers = ""; $self->{duplicate_build} = 0; + if ($self->{developer}) { + $self->{duplicate_build} = 1; + } if ($self->{config}->{LIBRARY_OUTPUT_TYPE} eq "SHARED_LIBRARY") { - if ($self->{developer}) { - $self->{duplicate_build} = 1; + if ($self->{duplicate_build}) { $devld_local = " -Wl,-rpath,\$(builddir)/bin"; } $devld_install = " -Wl,-rpath-link,\$(builddir)/bin"; @@ -372,9 +374,14 @@ sub Binary($$) $extradir = "/torture" . substr($ctx->{INSTALLDIR}, length("TORTUREDIR")); } my $localdir = "bin$extradir"; + + my $dynconfig = "dynconfig.o"; + my $dynconfig_install; if ($self->{duplicate_build}) { $installdir = "bin/install$extradir"; + $dynconfig = "dynconfig-devel.o"; + $dynconfig_install = "dynconfig.o"; } else { $installdir = "bin$extradir"; } @@ -401,20 +408,20 @@ sub Binary($$) if ($self->{duplicate_build}) { $self->output(<< "__EOD__" # -$localdir/$ctx->{BINARY}: \$($ctx->{TYPE}_$ctx->{NAME}_DEPEND_LIST) \$($ctx->{TYPE}_$ctx->{NAME}_FULL_OBJ_LIST) +$localdir/$ctx->{BINARY}: \$($ctx->{TYPE}_$ctx->{NAME}_DEPEND_LIST) \$($ctx->{TYPE}_$ctx->{NAME}_FULL_OBJ_LIST) $dynconfig \@echo Linking \$\@ - \@\$(LD) \$(LDFLAGS) -o \$\@ \$(LOCAL_LINK_FLAGS) \$(INSTALL_LINK_FLAGS) \\ - \$\($ctx->{TYPE}_$ctx->{NAME}_LINK_FLAGS) + \@\$(LD) \$(LDFLAGS) -o \$\@ \$(LOCAL_LINK_FLAGS) $dynconfig \\ + \$(INSTALL_LINK_FLAGS) \$\($ctx->{TYPE}_$ctx->{NAME}_LINK_FLAGS) __EOD__ ); } $self->output(<< "__EOD__" -$installdir/$ctx->{BINARY}: \$($ctx->{TYPE}_$ctx->{NAME}_DEPEND_LIST) \$($ctx->{TYPE}_$ctx->{NAME}_FULL_OBJ_LIST) +$installdir/$ctx->{BINARY}: \$($ctx->{TYPE}_$ctx->{NAME}_DEPEND_LIST) \$($ctx->{TYPE}_$ctx->{NAME}_FULL_OBJ_LIST) $dynconfig_install \@echo Linking \$\@ \@\$(LD) \$(LDFLAGS) -o \$\@ \$(INSTALL_LINK_FLAGS) \\ - \$\($ctx->{TYPE}_$ctx->{NAME}_LINK_FLAGS) + $dynconfig_install \$\($ctx->{TYPE}_$ctx->{NAME}_LINK_FLAGS) __EOD__ ); -- cgit