[Libreoffice-commits] core.git: autogen.sh solenv/gbuild

2014-04-23 Thread Luboš Luňák
 autogen.sh |   16 
 solenv/gbuild/partial_build.mk |5 -
 2 files changed, 20 insertions(+), 1 deletion(-)

New commits:
commit 2bf2bc2c7f257a818f3f723780690450f1a22c50
Author: Luboš Luňák l.lu...@collabora.com
Date:   Sun Mar 23 16:21:51 2014 +0100

make it possible to do 'make -C sw/' even with builddir!=srcdir

The change in partial_build.mk assumes all the Makefile's using it
are in builddir/module/ or builddir/external/module , these are
differentiated by checking for ../External_module.mk .

Change-Id: Iddc8fa2ec0842f181780f7491cf5a2244efd014a

diff --git a/autogen.sh b/autogen.sh
index f15dd91a..6894a8e 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -135,6 +135,22 @@ if ($src_path ne $build_path)
 {
 system (ln -sf $src_path/configure.ac configure.ac);
 system (ln -sf $src_path/g g);
+my @modules = $src_path/*/Makefile;
+foreach my $module (@modules)
+{
+my $dir = basename (dirname ($module));
+mkdir ($dir);
+system (ln -sf $src_path/$dir/Makefile $dir/Makefile);
+}
+my @external_modules = $src_path/external/*/Makefile;
+mkdir (external);
+system (ln -sf $src_path/external/Module_external.mk external/);
+foreach my $module (@external_modules)
+{
+my $dir = basename (dirname ($module));
+mkdir (external/$dir);
+system (ln -sf $src_path/external/$dir/Makefile 
external/$dir/Makefile);
+}
 }
 system ($aclocal $aclocal_flags)  die Failed to run aclocal;
 unlink (configure);
diff --git a/solenv/gbuild/partial_build.mk b/solenv/gbuild/partial_build.mk
index 68e807b..4d5e1db 100644
--- a/solenv/gbuild/partial_build.mk
+++ b/solenv/gbuild/partial_build.mk
@@ -22,7 +22,10 @@ gb_Side:=host
 endif
 
 ifeq (,$(BUILDDIR))
-BUILDDIR := $(dir $(realpath $(lastword $(MAKEFILE_LIST../..
+gb_partial_build__makefile_dir=$(dir $(abspath $(firstword $(MAKEFILE_LIST
+BUILDDIR := $(if $(wildcard 
$(gb_partial_build__makefile_dir)../Module_external.mk), \
+  $(gb_partial_build__makefile_dir)../.., \
+  $(gb_partial_build__makefile_dir)..)
 endif
 
 ifeq ($(BUILD_TYPE),)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: autogen.sh solenv/gbuild

2014-04-11 Thread Stephan Bergmann
 autogen.sh |7 ---
 solenv/gbuild/partial_build.mk |2 +-
 2 files changed, 1 insertion(+), 8 deletions(-)

New commits:
commit 11545b91d539b5c354c1423755be2a3809794bb6
Author: Stephan Bergmann sberg...@redhat.com
Date:   Fri Apr 11 14:24:15 2014 +0200

Revert make it possible to do 'make -C sw/' even with builddir!=srcdir

This reverts commit 11e881a63821ea209bda509d1e502d9ba270782d, which assumed 
that
all the Makefile's using it are in builddir/module/, which is not the 
case
for the external/ sub-modules.

diff --git a/autogen.sh b/autogen.sh
index da967a4..f15dd91a 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -135,13 +135,6 @@ if ($src_path ne $build_path)
 {
 system (ln -sf $src_path/configure.ac configure.ac);
 system (ln -sf $src_path/g g);
-my @modules = $src_path/*/Makefile;
-foreach my $module (@modules)
-{
-my $dir = basename (dirname ($module));
-mkdir ($dir);
-system (ln -sf $src_path/$dir/Makefile $dir/Makefile);
-}
 }
 system ($aclocal $aclocal_flags)  die Failed to run aclocal;
 unlink (configure);
diff --git a/solenv/gbuild/partial_build.mk b/solenv/gbuild/partial_build.mk
index eb2b5cc..68e807b 100644
--- a/solenv/gbuild/partial_build.mk
+++ b/solenv/gbuild/partial_build.mk
@@ -22,7 +22,7 @@ gb_Side:=host
 endif
 
 ifeq (,$(BUILDDIR))
-BUILDDIR := $(dir $(abspath $(firstword $(MAKEFILE_LIST..
+BUILDDIR := $(dir $(realpath $(lastword $(MAKEFILE_LIST../..
 endif
 
 ifeq ($(BUILD_TYPE),)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits