File: 40_createLinks.dpatch

package info (click to toggle)
maxdb-buildtools 562049-4
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 65,936 kB
  • ctags: 71,169
  • sloc: ansic: 265,970; perl: 108,708; python: 30,361; xml: 18,494; sh: 14,652; cpp: 8,606; yacc: 5,328; makefile: 2,082; lex: 708; asm: 321; fortran: 5; pascal: 4
file content (28 lines) | stat: -rw-r--r-- 976 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#! /bin/sh /usr/share/dpatch/dpatch-run
## 40_createLinks.dpatch by  <debian@martin-kittel.de>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: Do not overwrite existing files when trying to link

@DPATCH@
diff -urNad maxdb-buildtools-533920/sys/src/base/createLinks /tmp/dpep.Bn0Pp1/maxdb-buildtools-533920/sys/src/base/createLinks
--- maxdb-buildtools-533920/sys/src/base/createLinks	2004-11-02 20:00:20.000000000 +0100
+++ /tmp/dpep.Bn0Pp1/maxdb-buildtools-533920/sys/src/base/createLinks	2005-01-22 11:09:22.000000000 +0100
@@ -9,7 +9,7 @@
 for f in bison flex
 do
     inpath=`which $f`
-    if [ ! -z "$inpath" ]
+    if [ ! -z "$inpath" -a ! -e $targetDir/$f ]
     then
         ln -s -f $inpath $targetDir
     fi
@@ -22,7 +22,7 @@
 	mv ps rm rmdir sed sh sort tar touch uniq wc
 do
     inpath=`which $f`
-    if [ ! -z "$inpath" ]
+    if [ ! -z "$inpath" -a ! -e $targetDir/$f ]
     then
         ln -s -f $inpath $targetDir
     fi