diff options
author | JK Wood <joshuakwood@gmail.com> | 2014-07-23 22:48:40 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2014-07-23 22:48:40 +0700 |
commit | 48e4fad06ab7cfe8e2e1ee80d6b0ec1f677320b5 (patch) | |
tree | 43e93abace5c273965a09ba203f20169584af984 /ham | |
parent | 56837f7a6b002042a0926e2b631b532bf6282f85 (diff) |
ham/direwolf: Added (soundcard modem encoder/decoder).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'ham')
-rw-r--r-- | ham/direwolf/Makefile.patch | 114 | ||||
-rw-r--r-- | ham/direwolf/README | 9 | ||||
-rw-r--r-- | ham/direwolf/direwolf.SlackBuild | 104 | ||||
-rw-r--r-- | ham/direwolf/direwolf.desktop | 9 | ||||
-rw-r--r-- | ham/direwolf/direwolf.info | 10 | ||||
-rw-r--r-- | ham/direwolf/doinst.sh | 19 | ||||
-rw-r--r-- | ham/direwolf/slack-desc | 19 |
7 files changed, 284 insertions, 0 deletions
diff --git a/ham/direwolf/Makefile.patch b/ham/direwolf/Makefile.patch new file mode 100644 index 0000000000000..e58ef7271cbb7 --- /dev/null +++ b/ham/direwolf/Makefile.patch @@ -0,0 +1,114 @@ +--- Makefile.linux 2014-04-13 22:13:06.000000000 -0500 ++++ Makefile.linux.fixed 2014-07-22 22:39:30.875648118 -0500 +@@ -4,8 +4,26 @@ + + all : direwolf decode_aprs text2tt tt2text ll2utm utm2ll aclients + +-CC = gcc ++CC ?= gcc ++INSTALL ?= sudo install ++INSTALL_PROGRAM = $(INSTALL) -m 755 ++INSTALL_DATA = $(INSTALL) -m 644 ++INSTALL_DIR = $(INSTALL) -d ++ ++prefix ?= /usr/local ++exec_prefix = $(prefix) ++bindir ?= $(exec_prefix)/bin ++docdir ?= $(prefix)/share/doc/direwolf ++datadir ?= $(prefix)/share/direwolf ++appdir ?= /usr/share/applications ++sysconfdir ?= ~ ++LINK_IN_HOME ?= yes + ++ifeq ($(LINK_IN_HOME),yes) ++ HOME_DESKTOP = ln -f -s /usr/share/applications/direwolf.desktop ~/Desktop/direwolf.desktop ++else ++ HOME_DESKTOP = ++endif + # + # The DSP filters can be sped up considerably with the SSE + # instructions. The SSE instructions were introduced in 1999 +@@ -78,12 +96,14 @@ + # cause compatibility issues for those with older computers. + # + +-arch := $(shell echo | gcc -E -dM - | grep __i386__) ++arch ?= $(shell echo | gcc -E -dM - | grep __i386__) + ++ifndef CFLAGS + ifneq ($(arch),) +-CFLAGS := -DUSE_ALSA -O3 -march=pentium3 -pthread ++ CFLAGS := -DUSE_ALSA -O3 -march=pentium3 -pthread + else +-CFLAGS := -DUSE_ALSA -O3 -pthread ++ CFLAGS := -DUSE_ALSA -O3 -pthread ++endif + endif + + +@@ -131,37 +151,40 @@ + LatLong-UTMconversion.o : utm/LatLong-UTMconversion.c + $(CC) $(CFLAGS) -c -o $@ $^ + +- + # Optional install step. + # TODO: Review file locations. + # TODO: Handle Linux variations correctly. + # The Raspberry Pi has ~/Desktop but Ubuntu does not. + # For now, just put reference to it at the end so only last step fails. + +-install : direwolf decode_aprs tocalls.txt symbols-new.txt symbolsX.txt dw-icon.png direwolf.desktop +- sudo install direwolf /usr/local/bin +- sudo install decode_aprs /usr/local/bin +- sudo install text2tt /usr/local/bin +- sudo install tt2text /usr/local/bin +- sudo install ll2utm /usr/local/bin +- sudo install utm2ll /usr/local/bin +- sudo install aclients /usr/local/bin +- sudo install -D --mode=644 tocalls.txt /usr/share/direwolf/tocalls.txt +- sudo install -D --mode=644 symbols-new.txt /usr/share/direwolf/symbols-new.txt +- sudo install -D --mode=644 symbolsX.txt /usr/share/direwolf/symbolsX.txt +- sudo install -D --mode=644 dw-icon.png /usr/share/direwolf/dw-icon.png +- sudo install -D --mode=644 direwolf.desktop /usr/share/applications/direwolf.desktop +- cp direwolf.conf ~ +- cp dw-start.sh ~ +- sudo install -D --mode=644 CHANGES.txt /usr/local/share/doc/direwolf/CHANGES.txt +- sudo install -D --mode=644 LICENSE-dire-wolf.txt /usr/local/share/doc/direwolf/LICENSE-dire-wolf.txt +- sudo install -D --mode=644 LICENSE-other.txt /usr/local/share/doc/direwolf/LICENSE-other.txt +- sudo install -D --mode=644 User-Guide.pdf /usr/local/share/doc/direwolf/User-Guide.pdf +- sudo install -D --mode=644 Raspberry-Pi-APRS.pdf /usr/local/share/doc/direwolf/Raspberry-Pi-APRS.pdf +- sudo install -D --mode=644 APRStt-Implementation-Notes.pdf /usr/local/share/doc/direwolf/APRStt-Implementation-Notes.pdf +- sudo install -D --mode=644 Quick-Start-Guide-Windows.pdf /usr/local/share/doc/direwolf/Quick-Start-Guide-Windows.pdf +- ln -f -s /usr/share/applications/direwolf.desktop ~/Desktop/direwolf.desktop +- ++install : direwolf decode_aprs tocalls.txt symbols-new.txt symbolsX.txt dw-icon.png direwolf.desktop ++ $(INSTALL_DIR) $(DESTDIR)$(bindir)/ ++ $(INSTALL_PROGRAM) direwolf $(DESTDIR)$(bindir)/ ++ $(INSTALL_PROGRAM) decode_aprs $(DESTDIR)$(bindir)/ ++ $(INSTALL_PROGRAM) text2tt $(DESTDIR)$(bindir)/ ++ $(INSTALL_PROGRAM) tt2text $(DESTDIR)$(bindir)/ ++ $(INSTALL_PROGRAM) ll2utm $(DESTDIR)$(bindir)/ ++ $(INSTALL_PROGRAM) utm2ll $(DESTDIR)$(bindir)/ ++ $(INSTALL_PROGRAM) aclients $(DESTDIR)$(bindir)/ ++ $(INSTALL_DIR) $(DESTDIR)$(datadir) ++ $(INSTALL_DATA) tocalls.txt $(DESTDIR)$(datadir)/ ++ $(INSTALL_DATA) symbols-new.txt $(DESTDIR)$(datadir)/ ++ $(INSTALL_DATA) symbolsX.txt $(DESTDIR)$(datadir)/ ++ $(INSTALL_DATA) dw-icon.png $(DESTDIR)$(datadir)/ ++ $(INSTALL_DIR) $(DESTDIR)$(appdir) ++ $(INSTALL_DATA) direwolf.desktop $(DESTDIR)$(appdir)/ ++ $(INSTALL_DIR) $(DESTDIR)$(sysconfdir) ++ $(INSTALL_DATA) direwolf.conf $(DESTDIR)$(sysconfdir)/ ++ $(INSTALL_DATA) dw-start.sh $(DESTDIR)$(sysconfdir)/ ++ $(INSTALL_DIR) $(DESTDIR)$(docdir) ++ $(INSTALL_DATA) CHANGES.txt $(DESTDIR)$(docdir)/ ++ $(INSTALL_DATA) LICENSE-dire-wolf.txt $(DESTDIR)$(docdir)/ ++ $(INSTALL_DATA) LICENSE-other.txt $(DESTDIR)$(docdir)/ ++ $(INSTALL_DATA) User-Guide.pdf $(DESTDIR)$(docdir)/ ++ $(INSTALL_DATA) Raspberry-Pi-APRS.pdf $(DESTDIR)$(docdir)/ ++ $(INSTALL_DATA) APRStt-Implementation-Notes.pdf $(DESTDIR)$(docdir)/ ++ $(INSTALL_DATA) Quick-Start-Guide-Windows.pdf $(DESTDIR)$(docdir)/ ++ $(HOME_DESKTOP) + + # Separate application to decode raw data. + diff --git a/ham/direwolf/README b/ham/direwolf/README new file mode 100644 index 0000000000000..e57c5e1a851dd --- /dev/null +++ b/ham/direwolf/README @@ -0,0 +1,9 @@ +Dire Wolf is a software "soundcard" modem/TNC and APRS * +encoder/decoder. It can be used stand-alone to receive APRS +messages, as a digipeater, APRStt gateway, or Internet Gateway +(IGate). It can also be used as a virtual TNC for other +applications such as APRSIS32, UI-View32, Xastir, APRS-TW, YAAC, +UISS, Linux AX25, SARTrack, and many others. + +You'll need to edit the config file before first run to specify +soundcard, etc. diff --git a/ham/direwolf/direwolf.SlackBuild b/ham/direwolf/direwolf.SlackBuild new file mode 100644 index 0000000000000..127403989c79f --- /dev/null +++ b/ham/direwolf/direwolf.SlackBuild @@ -0,0 +1,104 @@ +#!/bin/sh +# Slackbuild for direwolf +# Written by JK Wood <joshuakwood@gmail.com> + +# Slackbuild is released under the Dog-on-Fire License: +# If use of this script causes your dog to catch on fire, +# you agree to send me five dollars. Or a picture +# of the dog on fire. +# Otherwise, you're on your own. I've tested the script +# on my own computer, and it hasn't broken anything. +# So if it does it on your computer, that falls in +# the realm of "Not my problem." +# +# Of course, if you'll send a bug report to the above +# email address, I may be able to see what you did +# wrong and prevent it from happening in the future. +# In which case, I may just send YOU five dollars. + +# Oh, and feel free to copy it and modify it as you +# see fit. Or as I see fit. Or as I fit. Although +# that is unlikely, as I am rather tall. + +PRGNAM=direwolf +VERSION=${VERSION:-1.0} +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} + +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) ARCH=i486 ;; + arm*) ARCH=arm ;; + *) ARCH=$( uname -m ) ;; + esac +fi + +CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +if [ "$ARCH" = "i486" ]; then + SLKCFLAGS="-O2 -march=i486 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "i686" ]; then + SLKCFLAGS="-O2 -march=i686 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" +else + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" +fi + +set -e + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +rm -rf $PRGNAM-$VERSION +unzip $CWD/$PRGNAM-$VERSION-src.zip -d $TMP +cd $PRGNAM-$VERSION +chown -R root:root . +find -L . \ + \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ + -o -perm 511 \) -exec chmod 755 {} \; -o \ + \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ + -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; + +# Fix some silly Makefile choices +patch -p0 < $CWD/Makefile.patch + +CFLAGS="$SLKCFLAGS -DUSE_ALSA -pthread" \ +LDFLAGS="-L/lib${LIBDIRSUFFIX} -L/usr/lib${LIBDIRSUFFIX}" \ + make -f Makefile.linux +INSTALL=install \ + prefix=/usr \ + docdir=/usr/doc/$PRGNAM-$VERSION \ + sysconfdir=/etc \ + LINK_IN_HOME=no \ +make -f Makefile.linux install DESTDIR=$PKG + +# direwolf comes with a lovely desktop +# file that assumes LXDE. Use our own +# here. +install -m 644 $CWD/direwolf.desktop $PKG/usr/share/applications/ +mkdir -p $PKG/usr/share/pixmaps +cp -a $PKG/usr/share/direwolf/dw-icon.png $PKG/usr/share/pixmaps/ + +mv $PKG/etc/direwolf.conf $PKG/etc/direwolf.conf.new + +find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ + | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild +find $PKG/usr/doc -name "Makefile" -exec rm {} \; +find $PKG/usr/doc -type f -exec chmod 644 {} \; + +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc + +cd $PKG +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG${PKGTYPE:-.tgz} diff --git a/ham/direwolf/direwolf.desktop b/ham/direwolf/direwolf.desktop new file mode 100644 index 0000000000000..35b9f8aa4229c --- /dev/null +++ b/ham/direwolf/direwolf.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Type=Application +Exec=direwolf -c /etc/direwolf.conf +Name=Dire Wolf +Comment=APRS Soundcard TNC +Icon=dw-icon +Terminal=true +Categories=HamRadio; +Keywords=Ham Radio;APRS;Soundcard TNC;KISS;AGWPE;AX.25; diff --git a/ham/direwolf/direwolf.info b/ham/direwolf/direwolf.info new file mode 100644 index 0000000000000..bf0a0eb484e17 --- /dev/null +++ b/ham/direwolf/direwolf.info @@ -0,0 +1,10 @@ +PRGNAM="direwolf" +VERSION="1.0" +HOMEPAGE="http://home.comcast.net/~wb2osz/site/" +DOWNLOAD="http://home.comcast.net/~wb2osz/Version%201.0/direwolf-1.0-src.zip" +MD5SUM="9386fb7f56ae7df6008869c82836fb11" +DOWNLOAD_x86_64="" +MD5SUM_x86_64="" +REQUIRES="" +MAINTAINER="JK Wood" +EMAIL="joshuakwood@gmail.com" diff --git a/ham/direwolf/doinst.sh b/ham/direwolf/doinst.sh new file mode 100644 index 0000000000000..fa7b7058f41be --- /dev/null +++ b/ham/direwolf/doinst.sh @@ -0,0 +1,19 @@ +config() { + NEW="$1" + OLD="$(dirname $NEW)/$(basename $NEW .new)" + # If there's no config file by that name, mv it over: + if [ ! -r $OLD ]; then + mv $NEW $OLD + elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then + # toss the redundant copy + rm $NEW + fi + # Otherwise, we leave the .new copy for the admin to consider... +} + +config etc/direwolf.conf.new + +if [ -x /usr/bin/update-desktop-database ]; then + /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1 +fi + diff --git a/ham/direwolf/slack-desc b/ham/direwolf/slack-desc new file mode 100644 index 0000000000000..b6e1340900e4c --- /dev/null +++ b/ham/direwolf/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. +# Line up the first '|' above the ':' following the base package name, and +# the '|' on the right side marks the last column you can put a character in. +# You must make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':' except on otherwise blank lines. + + |-----handy-ruler------------------------------------------------------| +direwolf: direwolf (soundcard modem/TNC and APRS encoder/decoder) +direwolf: +direwolf: Dire Wolf is a software "soundcard" modem/TNC and APRS * +direwolf: encoder/decoder. It can be used stand-alone to receive APRS +direwolf: messages, as a digipeater, APRStt gateway, or Internet Gateway +direwolf: (IGate). It can also be used as a virtual TNC for other +direwolf: applications such as APRSIS32, UI-View32, Xastir, APRS-TW, YAAC, +direwolf: UISS, Linux AX25, SARTrack, and many others. +direwolf: +direwolf: Homepage: http://home.comcast.net/~wb2osz/site/ +direwolf: |