2011-05-14 20:00:24 +02:00
|
|
|
$NetBSD: patch-ag,v 1.2 2011/05/14 18:00:24 wiz Exp $
|
2009-09-24 13:50:56 +02:00
|
|
|
|
|
|
|
No need to use bash for this small script.
|
|
|
|
|
|
|
|
Also -print0 is not portable to solaris and perhaps others.
|
|
|
|
|
|
|
|
--- libjava/contrib/rebuild-gcj-db.in.orig 2008-07-02 13:17:54.000000000 +0000
|
2011-05-14 20:00:24 +02:00
|
|
|
+++ libjava/contrib/rebuild-gcj-db.in
|
|
|
|
@@ -1,4 +1,4 @@
|
2009-09-24 13:50:56 +02:00
|
|
|
-#!/bin/bash
|
|
|
|
+#!/bin/sh
|
|
|
|
# rebuild-gcj-db
|
|
|
|
|
2011-05-14 20:00:24 +02:00
|
|
|
## Copyright (C) 2000, 2002, 2003, 2008 Free Software Foundation
|
|
|
|
@@ -16,12 +16,12 @@ for i in `@prefix@/bin/gcc --print-multi
|
|
|
|
base=@prefix@/lib/$dirname
|
2009-09-24 13:50:56 +02:00
|
|
|
dbLocation=`@prefix@/bin/gcj-dbtool -p $base`
|
|
|
|
libdir=$base/gcj
|
|
|
|
- if ! test -d $libdir; then
|
|
|
|
+ if test ! -d $libdir; then
|
|
|
|
# No shared libraries here.
|
|
|
|
continue
|
2011-05-14 20:00:24 +02:00
|
|
|
fi
|
2009-09-24 13:50:56 +02:00
|
|
|
dirname $dbLocation | xargs mkdir -p
|
|
|
|
@prefix@/bin/gcj-dbtool -n $dbLocation 64
|
|
|
|
- find $libdir -follow -name '*.db' -print0 | \
|
|
|
|
+ find $libdir -follow -name '*.db' -print | @AWK@ '{printf("%s%c", $1, 0);}' | \
|
|
|
|
@prefix@/bin/gcj-dbtool -0 -m $dbLocation $dbLocation
|
|
|
|
done
|