mirror of https://github.com/fltk/fltk
More packaging fun (games package to "advertise" FLTK...)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4755 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
parent
464c2f4a5e
commit
61b86ce0e5
2
Makefile
2
Makefile
|
@ -47,6 +47,7 @@ install: makeinclude
|
|||
|
||||
install-desktop: makeinclude
|
||||
cd fluid; $(MAKE) $(MFLAGS) $(INSTALL_DESKTOP)
|
||||
cd test; $(MAKE) $(MFLAGS) $(INSTALL_DESKTOP)
|
||||
|
||||
uninstall: makeinclude
|
||||
$(RM) $(DESTDIR)$(bindir)/fltk-config
|
||||
|
@ -57,6 +58,7 @@ uninstall: makeinclude
|
|||
|
||||
uninstall-desktop: makeinclude
|
||||
cd fluid; $(MAKE) $(MFLAGS) $(UNINSTALL_DESKTOP)
|
||||
cd test; $(MAKE) $(MFLAGS) $(UNINSTALL_DESKTOP)
|
||||
|
||||
depend: makeinclude
|
||||
for dir in $(DIRS); do\
|
||||
|
|
|
@ -37,13 +37,11 @@ dnl FLTK library versions...
|
|||
FL_MAJOR_VERSION=1
|
||||
FL_MINOR_VERSION=1
|
||||
FL_PATCH_VERSION=7
|
||||
FL_RELEASE_VERSION=
|
||||
FL_API_VERSION=${FL_MAJOR_VERSION}.${FL_MINOR_VERSION}
|
||||
|
||||
AC_SUBST(FL_MAJOR_VERSION)
|
||||
AC_SUBST(FL_MINOR_VERSION)
|
||||
AC_SUBST(FL_PATCH_VERSION)
|
||||
AC_SUBST(FL_RELEASE_VERSION)
|
||||
AC_SUBST(FL_API_VERSION)
|
||||
|
||||
dnl Get the operating system and version number...
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
%vendor FLTK Development Team
|
||||
%license COPYING
|
||||
%readme README
|
||||
%version @FL_MAJOR_VERSION@.@FL_MINOR_VERSION@.@FL_PATCH_VERSION@@FL_RELEASE_VERSION@
|
||||
%version @FL_MAJOR_VERSION@.@FL_MINOR_VERSION@.@FL_PATCH_VERSION@
|
||||
%description << EOF
|
||||
The Fast Light Tool Kit ("FLTK", pronounced "fulltick") is a
|
||||
cross-platform C++ GUI toolkit for UNIX(r)/Linux(r) (X11),
|
||||
|
|
|
@ -25,8 +25,8 @@
|
|||
# http://www.fltk.org/str.php
|
||||
#
|
||||
|
||||
%define version 1.1.7
|
||||
%define release 0
|
||||
%define version @VERSION@
|
||||
%define release @RELEASE@
|
||||
%define prefix /usr
|
||||
|
||||
Summary: Fast Light Tool Kit (FLTK)
|
||||
|
@ -36,8 +36,8 @@ Release: %{release}
|
|||
License: LGPL
|
||||
Group: System Environment/Libraries
|
||||
Source: ftp://ftp.fltk.org/pub/fltk/%{version}/fltk-%{version}-source.tar.gz
|
||||
URL: http://www.fltk.org
|
||||
Packager: Michael Sweet <mike@easysw.com>
|
||||
URL: http://www.fltk.org/
|
||||
Packager: FLTK Developer <fltk@fltk.org>
|
||||
# use BuildRoot so as not to disturb the version already installed
|
||||
BuildRoot: /var/tmp/fltk-%{PACKAGE_VERSION}
|
||||
|
||||
|
@ -57,6 +57,13 @@ Install fltk-devel if you need to develop FLTK applications.
|
|||
You'll need to install the fltk package if you plan to run
|
||||
dynamically linked applications.
|
||||
|
||||
%package games
|
||||
Summary: FLTK Games
|
||||
Group: Games
|
||||
|
||||
%description games
|
||||
Install fltk-games to play checkers or Sudoku on your computer.
|
||||
|
||||
%prep
|
||||
%setup
|
||||
|
||||
|
@ -85,7 +92,8 @@ rm -rf $RPM_BUILD_ROOT
|
|||
%files devel
|
||||
%defattr(-,root,root)
|
||||
%dir %{prefix}/bin
|
||||
%{prefix}/bin/*
|
||||
%{prefix}/bin/fltk-config
|
||||
%{prefix}/bin/fluid
|
||||
%dir %{prefix}/include/FL
|
||||
%{prefix}/include/FL/*
|
||||
%{prefix}/include/Fl
|
||||
|
@ -96,10 +104,18 @@ rm -rf $RPM_BUILD_ROOT
|
|||
%{_mandir}/*
|
||||
%dir %{prefix}/share/doc/fltk
|
||||
%{prefix}/share/doc/fltk/*
|
||||
%{prefix}/share/applnk/*
|
||||
%{prefix}/share/icons/*
|
||||
%{prefix}/share/applnk/Development/*
|
||||
%{prefix}/share/icons/hicolor/*/apps/fluid.png
|
||||
%{prefix}/share/mimelnk/*
|
||||
|
||||
%files games
|
||||
%dir %{prefix}/bin
|
||||
%{prefix}/bin/checkers
|
||||
%{prefix}/bin/sudoku
|
||||
%{prefix}/share/applnk/Games/*
|
||||
%{prefix}/share/icons/hicolor/*/apps/checkers.png
|
||||
%{prefix}/share/icons/hicolor/*/apps/sudoku.png
|
||||
|
||||
#
|
||||
# End of "$Id$".
|
||||
#
|
|
@ -88,7 +88,9 @@ install-linux:
|
|||
-$(MKDIR) $(DESTDIR)/usr/share/applnk/Development
|
||||
$(CP) fluid.desktop $(DESTDIR)/usr/share/applnk/Development
|
||||
for size in 16 32 48 64 128; do \
|
||||
-$(MKDIR) $(DESTDIR)/usr/share/icons/hicolor/$${size}x$${size}/apps; \
|
||||
if test ! -d $(DESTDIR)/usr/share/icons/hicolor/$${size}x$${size}/apps; then \
|
||||
$(MKDIR) $(DESTDIR)/usr/share/icons/hicolor/$${size}x$${size}/apps; \
|
||||
fi; \
|
||||
$(CP) icons/fluid-$$size.png $(DESTDIR)/usr/share/icons/hicolor/$${size}x$${size}/apps/fluid.png; \
|
||||
done
|
||||
-$(MKDIR) $(DESTDIR)/usr/share/mimelnk/application
|
||||
|
|
63
makesrcdist
63
makesrcdist
|
@ -5,40 +5,43 @@
|
|||
|
||||
echo "Getting distribution..."
|
||||
|
||||
CVS_RSH=ssh; export CVS_RSH
|
||||
MAINTAINER=easysw
|
||||
|
||||
cd /tmp
|
||||
cvs -q -d$MAINTAINER@cvs.sourceforge.net:/cvsroot/fltk get -P -r v1_1 fltk
|
||||
|
||||
if test $# = 0; then
|
||||
echo -n "Version number for distribution? "
|
||||
read version
|
||||
if test $# = 0 -o "x$1" = xsnapshot; then
|
||||
echo Updating for snapshot...
|
||||
svn up
|
||||
rev=`svnversion . | sed -e '1,$s/[a-zA-Z]//g'`
|
||||
version="1.1svn"
|
||||
fileversion="1.1svn-r$rev"
|
||||
fileurl="ftp://ftp.easysw.com/pub/fltk/snapshots/fltk-$fileversion-source.tar.bz2"
|
||||
url="."
|
||||
else
|
||||
echo Creating tag for release...
|
||||
rev="1"
|
||||
version=$1
|
||||
fileversion=$1
|
||||
fileurl="ftp://ftp.easysw.com/pub/fltk/$version/fltk-$fileversion-source.tar.bz2"
|
||||
url="https://svn.easysw.com/public/fltk/fltk/tags/release-$version"
|
||||
|
||||
svn copy https://svn.easysw.com/public/fltk/fltk/branches/branch-1.1 "$url" \
|
||||
-m "Tag $version" || exit 1
|
||||
fi
|
||||
|
||||
rm -rf fltk-$version
|
||||
mv fltk fltk-$version
|
||||
cd fltk-$version
|
||||
echo Exporting $version...
|
||||
rm -rf /tmp/fltk-$version
|
||||
svn export $url /tmp/fltk-$version
|
||||
|
||||
if test x$version != xsnapshot; then
|
||||
echo "Tagging release..."
|
||||
echo Applying version number...
|
||||
cd /tmp/fltk-$version
|
||||
|
||||
tag=`echo v$version | tr '.' '_'`
|
||||
fileurl=`echo $fileurl | sed -e '1,$s/\\//\\\\\\//g'`
|
||||
sed -e '1,$s/@VERSION@/'$version'/' \
|
||||
-e '1,$s/@RELEASE@/'$rev'/' \
|
||||
-e '1,$s/^Source:.*/Source: '$fileurl'/' \
|
||||
<fltk.spec.in >fltk.spec
|
||||
|
||||
cvs tag -F $tag
|
||||
fi
|
||||
|
||||
echo "Making configuration script..."
|
||||
|
||||
autoconf
|
||||
|
||||
echo "Removing CVS directories..."
|
||||
|
||||
find . -name .cvsignore -exec rm -f '{}' \;
|
||||
find . -name CVS -exec rm -rf '{}' \;
|
||||
echo Creating configure script...
|
||||
autoconf -f
|
||||
|
||||
echo Cleaning developer files...
|
||||
rm -rf OpenGL autom4te* bc5 config forms gl glut images packages themes
|
||||
rm -f makesrcdist
|
||||
|
||||
|
@ -46,15 +49,15 @@ cd ..
|
|||
|
||||
echo "Making UNIX distribution..."
|
||||
|
||||
gtar czf fltk-$version-source.tar.gz fltk-$version
|
||||
gtar czf fltk-$fileversion-source.tar.gz fltk-$version
|
||||
|
||||
echo "Making BZ2 distribution..."
|
||||
gunzip -c fltk-$version-source.tar.gz | bzip2 -v9 >fltk-$version-source.tar.bz2
|
||||
gtar cjf fltk-$fileversion-source.tar.bz2 fltk-$version
|
||||
|
||||
echo "Making Windows distribution..."
|
||||
|
||||
rm -f fltk-$version-source.zip
|
||||
zip -r9 fltk-$version-source.zip fltk-$version
|
||||
rm -f fltk-$fileversion-source.zip
|
||||
zip -r9 fltk-$fileversion-source.zip fltk-$version
|
||||
|
||||
echo "Removing distribution directory..."
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
#
|
||||
# Test/example program makefile for the Fast Light Tool Kit (FLTK).
|
||||
#
|
||||
# Copyright 1998-2005 by Bill Spitzak and others.
|
||||
# Copyright 1998-2006 by Bill Spitzak and others.
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU Library General Public
|
||||
|
@ -180,10 +180,53 @@ install:
|
|||
$(CP) *.h *.cxx *.fl demo.menu *.xbm *.xpm $(DESTDIR)$(docdir)/examples
|
||||
$(CHMOD) 644 $(DESTDIR)$(docdir)/examples/*.*
|
||||
|
||||
install-linux:
|
||||
echo Installing games to $(DESTDIR)$(bindir)...
|
||||
-$(MKDIR) $(DESTDIR)$(bindir)
|
||||
-$(MKDIR) $(DESTDIR)/usr/share/applnk/Games
|
||||
-$(MKDIR) $(DESTDIR)/usr/share/icons/hicolor/32x32/apps; \
|
||||
-$(MKDIR) $(DESTDIR)/usr/share/icons/hicolor/128x128/apps; \
|
||||
for game in checkers sudoku; do \
|
||||
$(CP) $$game $(DESTDIR)$(bindir); \
|
||||
$(CHMOD) 755 $(DESTDIR)$(bindir)/$$game; \
|
||||
$(CP) $$game.desktop $(DESTDIR)/usr/share/applnk/Games; \
|
||||
$(CP) icons/$$game-32.png $(DESTDIR)/usr/share/icons/hicolor/32x32/apps/$$game.png; \
|
||||
$(CP) icons/$$game-128.png $(DESTDIR)/usr/share/icons/hicolor/128x128/apps/$$game.png; \
|
||||
done
|
||||
|
||||
install-osx:
|
||||
echo Installing games in $(DESTDIR)/Applications...
|
||||
for game in checkers sudoku; do \
|
||||
if test ! -d $(DESTDIR)/Applications/$$game.app; then \
|
||||
$(MKDIR) $(DESTDIR)/Applications/$$game.app; \
|
||||
$(MKDIR) $(DESTDIR)/Applications/$$game.app/Contents; \
|
||||
$(MKDIR) $(DESTDIR)/Applications/$$game.app/Contents/MacOS; \
|
||||
$(MKDIR) $(DESTDIR)/Applications/$$game.app/Contents/Resources; \
|
||||
fi; \
|
||||
$(CP) $$game.app/Contents/Info.plist $(DESTDIR)/Applications/$$game.app/Contents; \
|
||||
$(CP) $$game.app/Contents/PkgInfo $(DESTDIR)/Applications/$$game.app/Contents; \
|
||||
$(CP) $$game.app/Contents/MacOS/$$game $(DESTDIR)/Applications/$$game.app/Contents/MacOS; \
|
||||
$(CP) $$game.app/Contents/Resources/$$game.icns $(DESTDIR)/Applications/$$game.app/Contents/Resources; \
|
||||
done
|
||||
|
||||
uninstall:
|
||||
echo "Removing examples programs from $(DESTDIR)$(docdir)/examples..."
|
||||
-$(RMDIR) $(DESTDIR)$(docdir)/examples
|
||||
|
||||
uninstall-linux:
|
||||
echo Removing games from $(DESTDIR)$(bindir)...
|
||||
for game in checkers sudoku; do \
|
||||
$(RM) $(DESTDIR)$(bindir)/$$game; \
|
||||
$(RM) $(DESTDIR)/usr/share/applnk/Games/$$game.desktop; \
|
||||
$(RM) $(DESTDIR)/usr/share/icons/hicolor/32x32/apps/$$game.png; \
|
||||
$(RM) $(DESTDIR)/usr/share/icons/hicolor/128x128/apps/$$game.png; \
|
||||
done
|
||||
|
||||
uninstall-osx:
|
||||
echo Removing games from $(DESTDIR)/Applications...
|
||||
$(RM) -r $(DESTDIR)/Applications/checkers.app
|
||||
$(RM) -r $(DESTDIR)/Applications/sudoku.app
|
||||
|
||||
# FLUID file rules
|
||||
.fl.cxx .fl.h: ../fluid/fluid$(EXEEXT)
|
||||
echo Generating $<...
|
||||
|
@ -212,6 +255,10 @@ button$(EXEEXT): button.o
|
|||
buttons$(EXEEXT): buttons.o
|
||||
|
||||
checkers$(EXEEXT): checkers.o
|
||||
echo Linking $@...
|
||||
$(CXX) $(CXXFLAGS) checkers.o -o $@ $(LINKFLTK) $(LDLIBS)
|
||||
$(CP) checkers$(EXEEXT) checkers.app/Contents/MacOS
|
||||
$(POSTBUILD) $@ ../FL/mac.r
|
||||
|
||||
clock$(EXEEXT): clock.o
|
||||
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 23 KiB |
Binary file not shown.
After Width: | Height: | Size: 1.8 KiB |
|
@ -0,0 +1,44 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<plist version="0.9">
|
||||
<dict>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>checkers</string>
|
||||
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>org.fltk.checkers</string>
|
||||
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1.0</string>
|
||||
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>English</string>
|
||||
|
||||
<key>NSHumanReadableCopyright</key>
|
||||
<string>Copyright 1997-2006 by Bill Spitzak and others</string>
|
||||
|
||||
<key>CFAppleHelpAnchor</key>
|
||||
<string>help</string>
|
||||
|
||||
<key>CFBundleName</key>
|
||||
<string>checkers</string>
|
||||
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
|
||||
<key>CFBundleSignature</key>
|
||||
<string>FLSU</string>
|
||||
|
||||
<key>CFBundleIconFile</key>
|
||||
<string>checkers.icns</string>
|
||||
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>1.0</string>
|
||||
|
||||
<key>CFBundleGetInfoString</key>
|
||||
<string>1.0, Copyright 1997-2006 by Bill Spitzak and others</string>
|
||||
|
||||
</dict>
|
||||
</plist>
|
|
@ -0,0 +1 @@
|
|||
FLSUFlsu
|
|
@ -0,0 +1,10 @@
|
|||
[Desktop Entry]
|
||||
Name=checkers
|
||||
Comment=Checkers Game
|
||||
TryExec=checkers
|
||||
Exec=checkers
|
||||
Icon=checkers
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Encoding=UTF-8
|
||||
Categories=Games
|
Before Width: | Height: | Size: 6.4 KiB After Width: | Height: | Size: 6.4 KiB |
Binary file not shown.
After Width: | Height: | Size: 295 B |
|
@ -17,7 +17,7 @@
|
|||
<string>English</string>
|
||||
|
||||
<key>NSHumanReadableCopyright</key>
|
||||
<string>Copyright 2005 by Michael Sweet</string>
|
||||
<string>Copyright 2005-2006 by Michael Sweet</string>
|
||||
|
||||
<key>CFAppleHelpAnchor</key>
|
||||
<string>help</string>
|
||||
|
@ -38,7 +38,7 @@
|
|||
<string>1.0</string>
|
||||
|
||||
<key>CFBundleGetInfoString</key>
|
||||
<string>1.0, Copyright 2005 by Michael Sweet</string>
|
||||
<string>1.0, Copyright 2005-2006 by Michael Sweet</string>
|
||||
|
||||
</dict>
|
||||
</plist>
|
||||
|
|
|
@ -0,0 +1,10 @@
|
|||
[Desktop Entry]
|
||||
Name=sudoku
|
||||
Comment=Suduku Number Game
|
||||
TryExec=sudoku
|
||||
Exec=sudoku
|
||||
Icon=sudoku
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Encoding=UTF-8
|
||||
Categories=Games
|
Loading…
Reference in New Issue