summaryrefslogtreecommitdiff
path: root/extra/source/fltk
diff options
context:
space:
mode:
authorPatrick J Volkerding <volkerdi@slackware.com>2016-06-30 20:26:57 +0000
committerEric Hameleers <alien@slackware.com>2018-05-31 23:31:18 +0200
commitd31c50870d0bee042ce660e445c9294a59a3a65b (patch)
tree6bfc0de3c95267b401b620c2c67859557dc60f97 /extra/source/fltk
parent76fc4757ac91ac7947a01fb7b53dddf9a78a01d1 (diff)
downloadcurrent-d31c50870d0bee042ce660e445c9294a59a3a65b.tar.gz
Slackware 14.2slackware-14.2
Thu Jun 30 20:26:57 UTC 2016 Slackware 14.2 x86_64 stable is released! The long development cycle (the Linux community has lately been living in "interesting times", as they say) is finally behind us, and we're proud to announce the release of Slackware 14.2. The new release brings many updates and modern tools, has switched from udev to eudev (no systemd), and adds well over a hundred new packages to the system. Thanks to the team, the upstream developers, the dedicated Slackware community, and everyone else who pitched in to help make this release a reality. The ISOs are off to be replicated, a 6 CD-ROM 32-bit set and a dual-sided 32-bit/64-bit x86/x86_64 DVD. Please consider supporting the Slackware project by picking up a copy from store.slackware.com. We're taking pre-orders now, and offer a discount if you sign up for a subscription. Have fun! :-)
Diffstat (limited to 'extra/source/fltk')
-rw-r--r--extra/source/fltk/Fl_XFont_On_Demand.patch42
-rwxr-xr-xextra/source/fltk/fltk.SlackBuild156
-rw-r--r--extra/source/fltk/slack-desc19
3 files changed, 217 insertions, 0 deletions
diff --git a/extra/source/fltk/Fl_XFont_On_Demand.patch b/extra/source/fltk/Fl_XFont_On_Demand.patch
new file mode 100644
index 00000000..b61def2a
--- /dev/null
+++ b/extra/source/fltk/Fl_XFont_On_Demand.patch
@@ -0,0 +1,42 @@
+Index: src/fl_font.cxx
+===================================================================
+--- src/fl_font.cxx (revision 10503)
++++ src/fl_font.cxx (revision 10504)
+@@ -55,6 +55,12 @@
+ # include "fl_font_x.cxx"
+ #endif // WIN32
+
++#if ! (defined(WIN32) || defined(__APPLE__))
++XFontStruct *fl_X_core_font()
++{
++ return fl_xfont.value();
++}
++#endif
+
+ double fl_width(const char* c) {
+ if (c) return fl_width(c, (int) strlen(c));
+Index: src/gl_draw.cxx
+===================================================================
+--- src/gl_draw.cxx (revision 10503)
++++ src/gl_draw.cxx (revision 10504)
+@@ -81,7 +81,7 @@
+ * then sorting through them at draw time (for normal X rendering) to find which one can
+ * render the current glyph... But for now, just use the first font in the list for GL...
+ */
+- XFontStruct *font = fl_xfont;
++ XFontStruct *font = fl_X_core_font();
+ int base = font->min_char_or_byte2;
+ int count = font->max_char_or_byte2-base+1;
+ fl_fontsize->listbase = glGenLists(256);
+Index: FL/x.H
+===================================================================
+--- FL/x.H (revision 10503)
++++ FL/x.H (revision 10504)
+@@ -132,6 +132,7 @@
+ XFontStruct *ptr;
+ };
+ extern FL_EXPORT Fl_XFont_On_Demand fl_xfont;
++extern FL_EXPORT XFontStruct* fl_X_core_font();
+
+ // this object contains all X-specific stuff about a window:
+ // Warning: this object is highly subject to change!
diff --git a/extra/source/fltk/fltk.SlackBuild b/extra/source/fltk/fltk.SlackBuild
new file mode 100755
index 00000000..7ed940e3
--- /dev/null
+++ b/extra/source/fltk/fltk.SlackBuild
@@ -0,0 +1,156 @@
+#!/bin/sh
+
+# Copyright 2015 Patrick J. Volkerding, Sebeka, Minnesota, USA
+# All rights reserved.
+#
+# Redistribution and use of this script, with or without modification, is
+# permitted provided that the following conditions are met:
+#
+# 1. Redistributions of this script must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+
+PKGNAM=fltk
+VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z* | rev | cut -f 3- -d . | cut -f 2 -d - | rev)}
+BUILD=${BUILD:-2}
+
+# Automatically determine the architecture we're building on:
+if [ -z "$ARCH" ]; then
+ case "$(uname -m)" in
+ i?86) ARCH=i586 ;;
+ arm*) readelf /usr/bin/file -A | egrep -q "Tag_CPU.*[4,5]" && ARCH=arm || ARCH=armv7hl ;;
+ # Unless $ARCH is already set, use uname -m for all other archs:
+ *) ARCH=$(uname -m) ;;
+ esac
+ export ARCH
+fi
+
+NUMJOBS=${NUMJOBS:-" -j7 "}
+
+if [ "$ARCH" = "i386" ]; then
+ SLKCFLAGS="-O2 -march=i386 -mcpu=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "s390" ]; then
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+elif [ "$ARCH" = "armv7hl" ]; then
+ SLKCFLAGS="-O3 -march=armv7-a -mfpu=vfpv3-d16"
+ LIBDIRSUFFIX=""
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp}
+PKG=$TMP/package-$PKGNAM
+
+rm -rf $PKG
+mkdir -p $TMP $PKG
+
+cd $TMP
+rm -rf $PKGNAM-$VERSION
+tar xvf $CWD/$PKGNAM-${VERSION}-source.tar.?z* || exit 1
+cd $PKGNAM-$VERSION || exit 1
+
+zcat $CWD/Fl_XFont_On_Demand.patch.gz | patch -p0 --verbose || exit 1
+
+chown -R root:root .
+find . \
+ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
+ -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
+ -exec chmod 644 {} \;
+
+# Configure:
+CFLAGS="$SLKCFLAGS" \
+./configure \
+ --prefix=/usr \
+ --sysconfdir=/etc \
+ --libdir=/usr/lib${LIBDIRSUFFIX} \
+ --includedir=/usr/include \
+ --mandir=/usr/man \
+ --enable-cairo \
+ --enable-gl \
+ --enable-largefile \
+ --enable-threads \
+ --enable-x11 \
+ --enable-xcursor \
+ --enable-xdbe \
+ --enable-xinerama \
+ --enable-xfixes \
+ --enable-xft \
+ --with-x \
+ --enable-shared \
+ --build=$ARCH-slackware-linux || exit 1
+
+# Build and install:
+make $NUMJOBS || make || exit 1
+make install DESTDIR=$PKG docdir=/usr/doc/$PKGNAM-$VERSION || exit 1
+
+# Removed pre-generated man pages:
+rm -rf $PKG/usr/man/cat*
+
+# Remove static libraries:
+rm -f $PKG/usr/lib${LIBDIRSUFFIX}/*.a
+
+# Stripping the .a libraries doesn't make a significant difference, so forget it:
+#find $PKG -name "*.a" | xargs file | grep "ar archive" | cut -f 1 -d : | xargs strip -g 2> /dev/null
+
+# Strip binaries:
+( cd $PKG
+ find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+ find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+)
+
+# Add a documentation directory:
+mkdir -p $PKG/usr/doc/${PKGNAM}-$VERSION
+cp -a \
+ ANNOUNCEMENT COPYING* CREDITS README* VERSION \
+ $PKG/usr/doc/${PKGNAM}-$VERSION
+cp -a documentation/README $PKG/usr/doc/${PKGNAM}-$VERSION/README.documentation
+
+# Compress and if needed symlink the man pages:
+if [ -d $PKG/usr/man ]; then
+ ( cd $PKG/usr/man
+ for manpagedir in $(find . -type d -name "man*") ; do
+ ( cd $manpagedir
+ for eachpage in $( find . -type l -maxdepth 1) ; do
+ ln -s $( readlink $eachpage ).gz $eachpage.gz
+ rm $eachpage
+ done
+ gzip -9 *.?
+ )
+ done
+ )
+fi
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+
+cd $PKG
+/sbin/makepkg -l y -c n $TMP/$PKGNAM-$VERSION-$ARCH-$BUILD.txz
+
diff --git a/extra/source/fltk/slack-desc b/extra/source/fltk/slack-desc
new file mode 100644
index 00000000..3175b3e8
--- /dev/null
+++ b/extra/source/fltk/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 ':'.
+
+ |-----handy-ruler------------------------------------------------------|
+fltk: fltk (The Fast Light Tool Kit)
+fltk:
+fltk: The Fast Light Tool Kit ("FLTK", pronounced "fulltick") is a a cross-
+fltk: platform C++ GUI toolkit for UNIX(r)/Linux(r) (X11), Microsoft(r)
+fltk: Windows(r), and MacOS(r) X. FLTK provides modern GUI functionality
+fltk: without the bloat and supports 3D graphics via OpenGL(r) and its
+fltk: built-in GLUT emulation. The Fast Light Tool Kit was originally
+fltk: developed by Mr. Bill Spitzak.
+fltk:
+fltk: fltk home: http://www.fltk.org
+fltk: