File mingw32-freeglut.spec of Package mingw32-freeglut

#
# spec file for package mingw32-freeglut
#
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# 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.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#


Name:           mingw32-freeglut
Version:        2.8.1
Release:        0
Summary:        Freely licensed alternative to the GLUT library
License:        X11
Group:          Development/Libraries/X11
Url:            http://freeglut.sf.net/
Source:         http://downloads.sf.net/freeglut/freeglut-%{version}.tar.gz
Source2:        glutman.tar.bz2
Patch1:         freeglut-mingw.diff
#!BuildIgnore: post-build-checks
BuildRequires:  autoconf
BuildRequires:  automake
BuildRequires:  libtool
BuildRequires:  mingw32-cross-binutils
BuildRequires:  mingw32-cross-gcc
BuildRequires:  mingw32-cross-gcc-c++
BuildRequires:  mingw32-cross-pkg-config
BuildRequires:  mingw32-filesystem
%_mingw32_package_header_debug
BuildArch:      noarch

%description
freeglut is an alternative to the OpenGL Utility Toolkit (GLUT)
library.

%package -n mingw32-libglut0
Summary:        Freely licensed alternative to the GLUT library
Group:          System/Libraries
Obsoletes:      %{name}
Provides:       %{name}

%description -n mingw32-libglut0
freeglut is an alternative to the OpenGL Utility Toolkit (GLUT)
library.

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.

%package devel
Summary:        Development libraries, includes and man pages for freeglut (GLUT Library)
Group:          Development/Libraries/C and C++

%description devel
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 an alternative to the OpenGL Utility Toolkit (GLUT)
library.

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.

%_mingw32_debug_package

%prep
%setup -q -b2 -n freeglut-%{version}
%patch -P 1 -p1

%build
autoreconf -fi
echo ac_cv_header_GL_gl_h=yes >>%{_mingw32_cache}
echo ac_cv_header_GL_glu_h=yes >>%{_mingw32_cache}
echo lt_cv_deplibs_check_method=pass_all >>%{_mingw32_cache}
%{_mingw32_configure} --disable-static --without-x
make %{?_smp_mflags} || make

%install
make DESTDIR=%{buildroot} install %{?_smp_mflags}
# remove demos
rm -f %{buildroot}%{_mingw32_bindir}/{fractals*,lorenz*,one*}
# glut Manual Pages
mkdir -p %{buildroot}/%{_mingw32_mandir}/man3
pushd ../glut-3.7
  for i in man/glut/glut*; do
    install -m 644 $i %{buildroot}/%{_mingw32_mandir}/man3/`basename $i man`3
  done
popd
rm -f %{buildroot}%{_mingw32_libdir}/*.la

%files -n mingw32-libglut0
%defattr(-,root,root)
%{_mingw32_bindir}/libglut-0.dll

%files devel
%defattr(-,root,root)
%{_mingw32_includedir}/GL/*
%{_mingw32_libdir}/*.dll.a
%{_mingw32_mandir}/man3/*

%changelog
openSUSE Build Service is sponsored by