2007-01-16 00:13:00 +01:00
|
|
|
#
|
2009-03-03 18:19:58 +01:00
|
|
|
# spec file for package freeglut (Version 090301)
|
2007-01-16 00:13:00 +01:00
|
|
|
#
|
2010-01-14 15:51:19 +01:00
|
|
|
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2007-01-16 00:13:00 +01:00
|
|
|
#
|
2008-08-11 22:37:31 +02:00
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2007-01-16 00:13:00 +01:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
# norootforbuild
|
|
|
|
|
2008-04-10 14:13:22 +02:00
|
|
|
|
2007-01-16 00:13:00 +01:00
|
|
|
Name: freeglut
|
|
|
|
BuildRequires: Mesa-devel gcc-c++ libdrm-devel pkgconfig xorg-x11-devel
|
2007-08-24 01:04:46 +02:00
|
|
|
Summary: Freely licensed alternative to the GLUT library
|
2009-03-03 18:19:58 +01:00
|
|
|
Version: 090301
|
2010-04-04 20:05:47 +02:00
|
|
|
Release: 4
|
2008-04-10 14:13:22 +02:00
|
|
|
Url: http://freeglut.sourceforge.net/
|
2007-01-16 00:13:00 +01:00
|
|
|
%define USE_EXTERNAL_MESA 1
|
|
|
|
Source0: freeglut-%{version}.tar.bz2
|
|
|
|
Source1: glutman.tar.bz2
|
|
|
|
Source2: glxdemos.tar.bz2
|
2010-04-04 20:05:47 +02:00
|
|
|
Source3: xdriinfo-1.0.3.tar.bz2
|
2007-01-16 00:13:00 +01:00
|
|
|
Source4: compat70.tar.bz2
|
2010-01-14 15:51:19 +01:00
|
|
|
Source5: baselibs.conf
|
2007-01-16 00:13:00 +01:00
|
|
|
Patch1: glxdemos.diff
|
2009-01-22 13:09:44 +01:00
|
|
|
Patch10: freeglut-glxgears-notify.diff
|
|
|
|
Patch11: freeglut-glxinfo-notify.diff
|
2010-01-14 15:51:19 +01:00
|
|
|
License: MIT
|
2007-01-16 00:13:00 +01:00
|
|
|
Provides: mesaglut
|
|
|
|
Obsoletes: mesaglut
|
2008-11-02 15:40:28 +01:00
|
|
|
# bug437293
|
|
|
|
%ifarch ppc64
|
|
|
|
Obsoletes: freeglut-64bit
|
|
|
|
%endif
|
|
|
|
#
|
2007-01-16 00:13:00 +01:00
|
|
|
Group: System/Libraries
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
|
|
|
|
%description
|
2007-08-24 01:04:46 +02:00
|
|
|
Freeglut is a completely open source alternative to the OpenGL Utility
|
2007-01-16 00:13:00 +01:00
|
|
|
Toolkit (GLUT) library. GLUT was originally written by Mark Kilgard to
|
|
|
|
support the sample programs in the second edition OpenGL Redbook. Since
|
|
|
|
then, GLUT has been used in a wide variety of practical applications
|
|
|
|
because it is simple, universally available, and highly portable.
|
|
|
|
|
|
|
|
GLUT (and freeglut) allow the user to create and manage windows
|
|
|
|
containing OpenGL contexts and also read the mouse, keyboard, and
|
|
|
|
joystick functions on a wide range of platforms.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Authors:
|
|
|
|
--------
|
|
|
|
Pawel W. Olszta
|
|
|
|
Andreas Umbach
|
|
|
|
Steve Baker
|
|
|
|
|
|
|
|
%package devel
|
2010-01-14 15:51:19 +01:00
|
|
|
License: MIT
|
2007-08-24 01:04:46 +02:00
|
|
|
Summary: Development libraries, includes and man pages for freeglut (GLUT Library)
|
2007-01-16 00:13:00 +01:00
|
|
|
Group: Development/Libraries/X11
|
|
|
|
Requires: %{name} = %{version}-%{release} xorg-x11-Mesa-devel xorg-x11-devel
|
|
|
|
Provides: mesaglut-devel
|
|
|
|
Obsoletes: mesaglut-devel
|
2008-11-02 15:40:28 +01:00
|
|
|
# bug437293
|
|
|
|
%ifarch ppc64
|
|
|
|
Obsoletes: freeglut-devel-64bit
|
|
|
|
%endif
|
|
|
|
#
|
2007-01-16 00:13:00 +01:00
|
|
|
|
|
|
|
%description devel
|
2007-08-24 01:04:46 +02:00
|
|
|
This package contains all necessary include files and libraries needed
|
|
|
|
to compile and link applications for the freeglut library.
|
|
|
|
|
|
|
|
In addition, it also includes manual pages which describe all functions
|
|
|
|
provided by the freeglut library.
|
|
|
|
|
|
|
|
freeglut is a completely open source alternative to the OpenGL Utility
|
|
|
|
Toolkit (GLUT) library. GLUT was originally written by Mark Kilgard to
|
|
|
|
support the sample programs in the second edition OpenGL Redbook. Since
|
|
|
|
then, GLUT has been used in a wide variety of practical applications
|
|
|
|
because it is simple, universally available, and highly portable.
|
|
|
|
|
|
|
|
GLUT (and freeglut) allow the user to create and manage windows
|
|
|
|
containing OpenGL contexts and also read the mouse, keyboard, and
|
|
|
|
joystick functions on a wide range of platforms.
|
2007-01-16 00:13:00 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q -b1 -b2 -b3 -b4 -n freeglut
|
|
|
|
%if %USE_EXTERNAL_MESA
|
|
|
|
pushd ..
|
|
|
|
%patch1
|
|
|
|
# Change lib -> %_lib
|
|
|
|
if [ "%_lib" != lib ] ; then
|
|
|
|
for f in `find usr/ \! -wholename '*/include/*' -type f -print` ; do
|
|
|
|
sed -i 's|/lib/|/%_lib/|g;s|/lib$|/%_lib|' "$f"
|
|
|
|
done
|
|
|
|
for f in `find usr/ -wholename '*/lib/*' -type f -print` ; do
|
|
|
|
d="`echo "$f" | sed 's|/lib|/%_lib|g'`"
|
|
|
|
mkdir -p "`dirname "$d"`"
|
|
|
|
mv "$f" "$d"
|
|
|
|
done
|
|
|
|
find usr -type d -print | xargs rmdir 2>/dev/null || true
|
|
|
|
fi
|
|
|
|
popd
|
|
|
|
%endif
|
2009-01-22 13:09:44 +01:00
|
|
|
pushd ../glxgears
|
|
|
|
%patch10 -p1
|
|
|
|
popd
|
|
|
|
pushd ../glxinfo
|
|
|
|
%patch11 -p1
|
|
|
|
popd
|
2007-01-16 00:13:00 +01:00
|
|
|
|
|
|
|
%build
|
|
|
|
autoreconf -fi
|
2009-04-23 21:18:00 +02:00
|
|
|
%configure --disable-static --with-pic
|
2007-01-16 00:13:00 +01:00
|
|
|
make %{?jobs:-j%jobs}
|
|
|
|
%if %USE_EXTERNAL_MESA
|
|
|
|
pushd ..
|
|
|
|
for i in glxinfo glxgears; do
|
2009-04-23 21:18:00 +02:00
|
|
|
pushd $i; xmkmf -a; make %{?jobs:-j%jobs} CDEBUGFLAGS="$RPM_OPT_FLAGS"; popd
|
2007-01-16 00:13:00 +01:00
|
|
|
done
|
|
|
|
pushd xdriinfo-*
|
|
|
|
test -f /usr/%_lib/pkgconfig/x11.pc || \
|
|
|
|
export PKG_CONFIG_PATH=/usr/%_lib/pkgconfig:$RPM_BUILD_DIR/usr/%_lib/pkgconfig
|
2009-04-23 21:18:00 +02:00
|
|
|
%configure --disable-static --with-pic
|
|
|
|
make %{?jobs:-j%jobs}
|
2007-01-16 00:13:00 +01:00
|
|
|
popd
|
|
|
|
popd
|
|
|
|
%endif
|
|
|
|
|
|
|
|
%install
|
|
|
|
%makeinstall
|
|
|
|
# remove demos
|
|
|
|
rm -f ${RPM_BUILD_ROOT}/usr/bin/{fractals*,lorenz,one}
|
|
|
|
# glut Manual Pages
|
|
|
|
mkdir -p ${RPM_BUILD_ROOT}/%{_mandir}/man3
|
|
|
|
pushd ../glut-3.7
|
|
|
|
for i in man/glut/glut*; do
|
|
|
|
install -m 644 $i ${RPM_BUILD_ROOT}/%{_mandir}/man3/`basename $i man`3
|
|
|
|
done
|
|
|
|
popd
|
|
|
|
%if %USE_EXTERNAL_MESA
|
|
|
|
pushd ..
|
|
|
|
for i in glxinfo glxgears; do
|
|
|
|
pushd $i
|
|
|
|
make install DESTDIR=$RPM_BUILD_ROOT BINDIR=/usr/bin
|
|
|
|
make install.man DESTDIR=$RPM_BUILD_ROOT MANDIR=%_mandir/man1
|
|
|
|
popd
|
|
|
|
done
|
|
|
|
pushd xdriinfo-*
|
|
|
|
make install DESTDIR=$RPM_BUILD_ROOT
|
|
|
|
popd
|
|
|
|
popd
|
|
|
|
%endif
|
2009-04-23 21:18:00 +02:00
|
|
|
%{__rm} -f %{buildroot}%{_libdir}/*.la
|
2007-01-16 00:13:00 +01:00
|
|
|
|
2009-04-23 21:18:00 +02:00
|
|
|
%post -p /sbin/ldconfig
|
2007-01-16 00:13:00 +01:00
|
|
|
|
2009-04-23 21:18:00 +02:00
|
|
|
%postun -p /sbin/ldconfig
|
2007-01-16 00:13:00 +01:00
|
|
|
|
|
|
|
%clean
|
|
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%if %USE_EXTERNAL_MESA
|
|
|
|
/usr/bin/glxgears
|
|
|
|
/usr/bin/glxinfo
|
|
|
|
/usr/bin/xdriinfo
|
|
|
|
%{_mandir}/man1/glxgears.1x.gz
|
|
|
|
%{_mandir}/man1/glxinfo.1x.gz
|
2007-08-24 01:04:46 +02:00
|
|
|
%{_mandir}/man1/xdriinfo.1.gz
|
2007-01-16 00:13:00 +01:00
|
|
|
%endif
|
|
|
|
%{_libdir}/libglut.so.*
|
|
|
|
|
|
|
|
%files devel
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_includedir}/GL/*
|
|
|
|
%{_libdir}/libglut.so
|
|
|
|
%{_mandir}/man3/*
|
|
|
|
|
2007-08-24 01:04:46 +02:00
|
|
|
%changelog
|