Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

cxref: adding a nice C documentation tool

  • Loading branch information...
commit ec4b86b59f18400f944e15efe6275e12ab3d21b5 1 parent bc2325a
Vincent Batts authored
0  TESTING/cxref/README
No changes.
94  TESTING/cxref/cxref.SlackBuild
... ...
@@ -0,0 +1,94 @@
  1
+#!/bin/sh
  2
+
  3
+# Slackware build script for cxref
  4
+
  5
+# Written by Vincent Batts, vbatts@hashbangbash.com
  6
+
  7
+PRGNAM=cxref
  8
+VERSION=${VERSION:-1.6c}
  9
+BUILD=${BUILD:-1}
  10
+TAG=${TAG:-_SBo}
  11
+
  12
+# Automatically determine the architecture we're building on:
  13
+if [ -z "$ARCH" ]; then
  14
+  case "$( uname -m )" in
  15
+    i?86) ARCH=i486 ;;
  16
+    arm*) ARCH=arm ;;
  17
+    # Unless $ARCH is already set, use uname -m for all other archs:
  18
+       *) ARCH=$( uname -m ) ;;
  19
+  esac
  20
+fi
  21
+
  22
+CWD=$(pwd)
  23
+TMP=${TMP:-/tmp/SBo}
  24
+PKG=$TMP/package-$PRGNAM
  25
+OUTPUT=${OUTPUT:-/tmp}
  26
+
  27
+PAPERSIZE=${PAPERSIZE:-US}
  28
+if [ "${PAPERSIZE}" = "US" ] ; then
  29
+  PAPERSIZE_ARG="--enable-us-paper"
  30
+else
  31
+  PAPERSIZE_ARG=""
  32
+fi
  33
+
  34
+if [ "$ARCH" = "i486" ]; then
  35
+  SLKCFLAGS="-O2 -march=i486 -mtune=i686"
  36
+elif [ "$ARCH" = "i686" ]; then
  37
+  SLKCFLAGS="-O2 -march=i686 -mtune=i686"
  38
+elif [ "$ARCH" = "x86_64" ]; then
  39
+  SLKCFLAGS="-O2 -fPIC"
  40
+fi
  41
+
  42
+set -e
  43
+
  44
+rm -rf $PKG
  45
+mkdir -p $TMP $PKG $OUTPUT
  46
+cd $TMP
  47
+rm -rf $PRGNAM-$VERSION
  48
+tar xvf $CWD/$PRGNAM-$VERSION.tgz
  49
+cd $PRGNAM-$VERSION
  50
+chown -R root:root .
  51
+find . \
  52
+ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
  53
+ -exec chmod 755 {} \; -o \
  54
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
  55
+ -exec chmod 644 {} \;
  56
+
  57
+CFLAGS="$SLKCFLAGS" \
  58
+CXXFLAGS="$SLKCFLAGS" \
  59
+./configure \
  60
+  --prefix=/usr \
  61
+  --sysconfdir=/etc \
  62
+  $PAPERSIZE_ARG \
  63
+  --localstatedir=/var \
  64
+  --mandir=/usr/man \
  65
+  --docdir=/usr/doc/$PRGNAM-$VERSION \
  66
+  --build=$ARCH-slackware-linux
  67
+
  68
+make
  69
+make install DESTDIR=$PKG
  70
+
  71
+( cd $PKG
  72
+  find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | \
  73
+    xargs strip --strip-unneeded 2> /dev/null || true
  74
+  find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | \
  75
+    xargs strip --strip-unneeded 2> /dev/null || true
  76
+)
  77
+
  78
+( cd $PKG/usr/man
  79
+  find . -type f -exec gzip -9 {} \;
  80
+  for i in $( find . -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
  81
+)
  82
+
  83
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
  84
+cp -a \
  85
+    doc/INSTALL ChangeLog* doc/COPYING doc/ANNOUNCE TODO doc/README* doc/NEWS  \
  86
+  $PKG/usr/doc/$PRGNAM-$VERSION
  87
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
  88
+
  89
+mkdir -p $PKG/install
  90
+cat $CWD/slack-desc > $PKG/install/slack-desc
  91
+
  92
+cd $PKG
  93
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz
  94
+
10  TESTING/cxref/cxref.info
... ...
@@ -0,0 +1,10 @@
  1
+PRGNAM="cxref"
  2
+VERSION="1.6c"
  3
+HOMEPAGE="http://www.gedanken.demon.co.uk/cxref/"
  4
+DOWNLOAD="http://www.gedanken.demon.co.uk/download-cxref/cxref-1.6c.tgz"
  5
+MD5SUM="5857b9cc313cab8c8054215791b21b47"
  6
+DOWNLOAD_x86_64=""
  7
+MD5SUM_x86_64=""
  8
+MAINTAINER="Vincent Batts"
  9
+EMAIL="vbatts@hashbangbash.com"
  10
+APPROVED=""
19  TESTING/cxref/slack-desc
... ...
@@ -0,0 +1,19 @@
  1
+# HOW TO EDIT THIS FILE:
  2
+# The "handy ruler" below makes it easier to edit a package description.  Line
  3
+# up the first '|' above the ':' following the base package name, and the '|'
  4
+# on the right side marks the last column you can put a character in.  You must
  5
+# make exactly 11 lines for the formatting to be correct.  It's also
  6
+# customary to leave one space after the ':' except on otherwise blank lines.
  7
+
  8
+     |-----handy-ruler------------------------------------------------------|
  9
+cxref: cxref (C Cross Referencing & Documenting tool)
  10
+cxref:
  11
+cxref: Cxref is a program that will produce documentation (in LaTeX, HTML,
  12
+cxref: RTF or SGML) including cross-references from C program source code. 
  13
+cxref: It has been designed to work with ANSI C, incorporating K&R, and
  14
+cxref: most popular GNU extensions.
  15
+cxref:
  16
+cxref:
  17
+cxref:
  18
+cxref:
  19
+cxref:

0 notes on commit ec4b86b

Please sign in to comment.
Something went wrong with that request. Please try again.