# --- SDE-COPYRIGHT-NOTE-BEGIN --- # This copyright note is auto-generated by ./scripts/Create-CopyPatch. # # Filename: package/.../bglibs/installer-conf.patch.cross # Copyright (C) 2008 The OpenSDE Project # # More information can be found in the files COPYING and README. # # This patch file is dual-licensed. It is available under the license the # patched project is licensed under, as long as it is an OpenSource license # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms # of the GNU General Public License as published by the Free Software # Foundation; either version 2 of the License, or (at your option) any later # version. # --- SDE-COPYRIGHT-NOTE-END --- Author: Christian Wiese Origin: OpenSDE (http://opensde.org) Description: Add support for defining which installer has to be used, because for cross-compiling bglibs we need to use a bg-installer that was built 'natively' with the compiler of the build system. Instead of using 'bg-installer' directly we create the 'installer' wrapper script for being able to explicitely define the path to the installer we want to use via 'conf-installer'. diff -ruN bglibs-1.102/Makefile bglibs-1.102-cross-conf/Makefile --- bglibs-1.102/Makefile 2006-10-30 23:11:21.000000000 +0200 +++ bglibs-1.102-cross/Makefile 2007-04-14 05:50:39.767276500 +0300 @@ -601,9 +601,16 @@ fmt/unum.o: compile fmt/unum.c fmt/number.h selftest.c iobuf/iobuf.h iobuf/common.h iobuf/ibuf.h iobuf/common.h iobuf/obuf.h iobuf/common.h msg/msg.h str/str.h ./compile fmt/unum.c -install: bg-installer INSTHIER conf-bin conf-include conf-lib conf-man - ./bg-installer -v installer + chmod 755 installer + +install: bg-installer INSTHIER installer conf-bin conf-include conf-lib conf-man + ./installer -v /dev/null 2>&1; then tag='--tag=CC'; fi; \ echo '#!/bin/sh'; \ echo 'source=$$1; shift'; \ echo 'base=`echo "$$source" | sed -e s:\\\\.c$$::`'; \ - echo exec libtool --mode=compile --silent `head -n 1 conf-cc` -I. '-o $${base}.lo -c $$source $${1+"$$@"}'; \ + echo exec `head -n 1 conf-libtool` --mode=compile --silent $$tag `head -n 1 conf-cc` -I. '-o $${base}.lo -c $$source $${1+"$$@"}'; \ ) >libcompile chmod 755 libcompile @@ -1023,17 +1030,17 @@ ( echo '#!/bin/sh'; \ echo 'main="$$1"; shift';\ echo 'rm -f "$$main"';\ - echo 'ar cr "$$main" $${1+"$$@"}';\ - echo 'ranlib "$$main"';\ + echo '`head -n 1 conf-ar` cr "$$main" $${1+"$$@"}';\ + echo '`head -n 1 conf-ranlib` "$$main"';\ ) >makelib chmod 755 makelib makeshlib: conf-ld conf-lib LIBVERSION Makefile - ( if libtool --tag=CC --help >/dev/null 2>&1; then tag='--tag=CC'; fi; \ + ( if `head -n 1 conf-libtool` --tag=CC --help >/dev/null 2>&1; then tag='--tag=CC'; fi; \ echo '#!/bin/sh'; \ echo 'lib="$$1"; shift';\ echo 'rm -f "$$lib"';\ - echo libtool --mode=link --silent $$tag `head -n 1 conf-ld` '-o "$$lib" -rpath' `head -n 1 conf-lib` -version-info `head -n 1 LIBVERSION` '$${1+"$$@"}';\ + echo `head -n 1 conf-libtool` --mode=link --silent $$tag `head -n 1 conf-ld` '-o "$$lib" -rpath' `head -n 1 conf-lib` -version-info `head -n 1 LIBVERSION` '$${1+"$$@"}';\ ) >makeshlib chmod 755 makeshlib diff -ruN bglibs-1.102/conf-ar bglibs-1.102-cross-conf/conf-ar --- bglibs-1.102/conf-ar 1970-01-01 02:00:00.000000000 +0200 +++ bglibs-1.102-cross-conf/conf-ar 2007-04-14 04:48:21.373641500 +0300 @@ -0,0 +1 @@ +ar diff -ruN bglibs-1.102/conf-installer bglibs-1.102-cross-conf/conf-installer --- bglibs-1.102/conf-installer 1970-01-01 02:00:00.000000000 +0200 +++ bglibs-1.102-cross-conf/conf-installer 2007-04-14 20:00:21.109411250 +0300 @@ -0,0 +1 @@ +./bg-installer diff -ruN bglibs-1.102/conf-libtool bglibs-1.102-cross-conf/conf-libtool --- bglibs-1.102/conf-libtool 1970-01-01 02:00:00.000000000 +0200 +++ bglibs-1.102-cross-conf/conf-libtool 2007-04-14 04:27:44.956370250 +0300 @@ -0,0 +1 @@ +libtool diff -ruN bglibs-1.102/conf-ranlib bglibs-1.102-cross-conf/conf-ranlib --- bglibs-1.102/conf-ranlib 1970-01-01 02:00:00.000000000 +0200 +++ bglibs-1.102-cross-conf/conf-ranlib 2007-04-14 04:27:03.289766250 +0300 @@ -0,0 +1 @@ +ranlib