Changeset 47351


Ignore:
Timestamp:
Feb 26, 2009, 3:09:04 PM (11 years ago)
Author:
raimue@…
Message:

textproc/asciidoc:
After r47347, the a2x command did still not work correctly. This patch replaces
the tools called by a2x with the GNU versions from coreutils.

Location:
trunk/dports/textproc/asciidoc
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/dports/textproc/asciidoc/Portfile

    r47349 r47351  
    55name                            asciidoc
    66version                         8.3.1
    7 revision                        2
     7revision                        3
    88categories                      textproc
    99maintainers                     boeyms openmaintainer
     
    2929patchfiles                      patch-a2x.diff
    3030
    31 depends_run                     port:python25 port:getopt port:docbook-xml-4.2 port:fop-0.20
     31depends_run                     port:python25 port:getopt port:docbook-xml-4.2 port:fop-0.20 port:coreutils
    3232
    3333destroot.target                 install docs vimdir=${prefix}/share/vim/vimfiles/
  • trunk/dports/textproc/asciidoc/files/patch-a2x.diff

    r47347 r47351  
    1 --- a2x.orig    2009-02-26 14:05:40.000000000 +0100
    2 +++ a2x 2009-02-26 14:05:52.000000000 +0100
    3 @@ -13,7 +13,7 @@
     1--- a2x.orig    2009-02-26 15:27:38.000000000 +0100
     2+++ a2x 2009-02-26 15:53:54.000000000 +0100
     3@@ -8,12 +8,12 @@
     4 #
     5 
     6 VERSION=1.0.0
     7-BASENAME=$(basename "$0")
     8+BASENAME=$(gbasename "$0")
     9 REALNAME="$0"
    410 if [ ! -e "$REALNAME" ]; then
    511     REALNAME=$(which "$REALNAME")
    612 fi
    713-REALNAME="$(readlink -f "$REALNAME")"
    8 +REALNAME="$(readlink "$REALNAME")"
     14+REALNAME="$(greadlink -f "$REALNAME")"
    915 CONF_DIR=/etc/asciidoc
    1016 FOP_COMMAND="fop.sh"    # FOP executable.
    1117 
     18@@ -161,7 +161,7 @@
     19 # Echo the total size in bytes of file name arguments.
     20 function file_size()
     21 {
     22-    echo $(du -cb "$@" | tail -1 | awk '{print $1}')
     23+    echo $(gdu -cb "$@" | gtail -1 | awk '{print $1}')
     24 }
     25 
     26 #--------------------------------------------------------------------
     27@@ -223,7 +223,7 @@
     28 {
     29     local result dir
     30     # First look in same directory as asciidoc executable.
     31-    dir="$(dirname "$REALNAME")"
     32+    dir="$(gdirname "$REALNAME")"
     33     if [ ! -f "$dir/$1" -a -d $CONF_DIR ]; then
     34         dir=$CONF_DIR
     35     fi
     36@@ -334,7 +334,7 @@
     37         quit "source file not found: $1"
     38     fi
     39     SRC_FILE=$1
     40-    SRC_DIR=$(dirname "$1")
     41+    SRC_DIR=$(gdirname "$1")
     42     SRC_NAME=$1
     43     SRC_NAME=${SRC_NAME##*/}    # Strip path.
     44     SRC_NAME=${SRC_NAME%.*}     # Strip extension.
     45@@ -415,7 +415,7 @@
     46     if [[ "$src" -ef "$dst" ]]; then
     47         return
     48     fi
     49-    execute_command_2 "cp -u \"$src\" \"$dst\""
     50+    execute_command_2 "gcp -u \"$src\" \"$dst\""
     51 }
     52 
     53 # Copy distribution admonition and navigation icons to destination directory
     54@@ -429,7 +429,7 @@
     55     if [ ! -r "$src" ]; then
     56         quit "file not found: $src"
     57     fi
     58-    src=$(dirname "$src")
     59+    src=$(gdirname "$src")
     60     # Check we're not trying to copy the file onto itself.
     61     if [[ "$src" -ef "$dst" ]]; then
     62         return
     63@@ -439,9 +439,9 @@
     64             quit "icon destination must be a directory: $dst"
     65         fi
     66     else
     67-        execute_command_2 "mkdir -p \"$dst\""
     68+        execute_command_2 "gmkdir -p \"$dst\""
     69     fi
     70-    execute_command_2 "cp -rfu  \"$src/\"* \"$dst\""
     71+    execute_command_2 "gcp -rfu  \"$src/\"* \"$dst\""
     72 }
     73 
     74 # Run xmllint(1) checking of $1 file if xmllint checking is enabled.
     75@@ -486,7 +486,7 @@
     76         quit "file not found: $xsl"
     77     fi
     78     to_docbook
     79-    xml=$(readlink -f "$SRC_DIR/$SRC_NAME.xml")
     80+    xml=$(greadlink -f "$SRC_DIR/$SRC_NAME.xml")
     81     html="$SRC_NAME.html"
     82     copy_stylesheet_and_icons "$DESTINATION_DIR"
     83     execute_command_2 "cd \"$DESTINATION_DIR\""
     84@@ -519,7 +519,7 @@
     85         quit "file not found: $xsl"
     86     fi
     87     to_docbook
     88-    xml=$(readlink -f "$SRC_DIR/$SRC_NAME.xml")
     89+    xml=$(greadlink -f "$SRC_DIR/$SRC_NAME.xml")
     90     if [ ! -d "$chunkdir" ]; then
     91         execute_command_2 "mkdir \"$chunkdir\""
     92     fi
     93@@ -541,7 +541,7 @@
     94         quit "file not found: $xsl"
     95     fi
     96     to_docbook "-d manpage"
     97-    xml=$(readlink -f "$SRC_DIR/$SRC_NAME.xml")
     98+    xml=$(greadlink -f "$SRC_DIR/$SRC_NAME.xml")
     99     execute_command_2 "cd \"$DESTINATION_DIR\""
     100     execute_command_2 "xsltproc $XSLTPROC_OPTS --nonet \
     101         \"$xsl\" \"$xml\""
Note: See TracChangeset for help on using the changeset viewer.