From 480053d702bc8b1553c9e01aab3da0dd72737a1b Mon Sep 17 00:00:00 2001 From: Jochen Schmitt Date: Nov 14 2006 16:51:43 +0000 Subject: Try to fix AMD64 problem --- diff --git a/stellarium-0.8.2-x64_1.patch b/stellarium-0.8.2-x64_1.patch new file mode 100644 index 0000000..82f7337 --- /dev/null +++ b/stellarium-0.8.2-x64_1.patch @@ -0,0 +1,11 @@ +--- src/translator.cpp 2006-10-05 09:12:12.000000000 +0100 ++++ src/translator.cpp 2006-10-22 21:34:22.000000000 +0100 +@@ -71,7 +71,7 @@ + } + + //change systemLangName to ISO 639 / ISO 3166. +- unsigned int pos = Translator::systemLangName.find(':', 0); ++ std::string::size_type pos = Translator::systemLangName.find(':', 0); + if(pos != Translator::systemLangName.npos) + Translator::systemLangName.resize(pos); + pos = Translator::systemLangName.find('.', 0); diff --git a/stellarium-0.8.2-x64_2.patch b/stellarium-0.8.2-x64_2.patch new file mode 100644 index 0000000..0889668 --- /dev/null +++ b/stellarium-0.8.2-x64_2.patch @@ -0,0 +1,22 @@ +--- stellarium-0.8.2/src/stel_core.cpp~ 2006-11-13 23:06:16.000000000 +0100 ++++ stellarium-0.8.2/src/stel_core.cpp 2006-11-13 23:06:16.000000000 +0100 +@@ -70,8 +70,6 @@ + dataRoot = DATA_ROOT; + recordActionCallback = recordCallback; + +- projection = Projector::create(Projector::PERSPECTIVE_PROJECTOR, Vec4i(0,0,800,600), 60); +- glFrontFace(projection->needGlFrontFaceCW()?GL_CW:GL_CCW); + + tone_converter = new ToneReproductor(); + atmosphere = new Atmosphere(); +@@ -135,6 +133,10 @@ + // Load core data and initialize with default values + void StelCore::init(const InitParser& conf) + { ++ // do NOT do this in the constructor as there is no valid GLcontext there! ++ projection = Projector::create(Projector::PERSPECTIVE_PROJECTOR, Vec4i(0,0,800,600), 60); ++ glFrontFace(projection->needGlFrontFaceCW()?GL_CW:GL_CCW); ++ + baseFontFile = getDataDir() + conf.get_str("gui", "base_font_name", "DejaVuSans.ttf"); + + // Video Section diff --git a/stellarium.spec b/stellarium.spec index c69ab67..2bbd7f9 100644 --- a/stellarium.spec +++ b/stellarium.spec @@ -1,6 +1,6 @@ Name: stellarium Version: 0.8.2 -Release: 2%{?dist} +Release: 3%{?dist} Summary: Photo-realistic nightsky renderer Group: Amusements/Graphics @@ -9,7 +9,9 @@ URL: http://stellarium.free.fr/ Source0: http://switch.dl.sf.net/stellarium/stellarium-%{version}.tar.gz Source1: stellarium.desktop Source2: http://switch.dl.sf.net/stellarum/stellarium_user_guide-0.8.1-1.pdf -Patch1: stellarium-0.8.2-x64.patch +Patch1: stellarium-0.8.2-x64_1.patch +Patch2: stellarium-0.8.2-x64_2.patch + BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: SDL-devel @@ -40,7 +42,8 @@ You will need a PDF viewer to read the user guide. %prep %setup -q -%patch1 -p1 +%patch1 -p0 +%patch2 -p1 %build %configure @@ -85,6 +88,9 @@ rm -rf $RPM_BUILD_ROOT %doc COPYING stellarium_user_guide-0.8.1-1.pdf %changelog +* Tue Nov 14 2006 Jochen Schmitt 0.8.2-3 +- Try to fix AMD64 problem (#210525) + * Thu Oct 19 2006 Jochen Schmitt 0.8.2-2 - Fix segfault on x64 systems (#210525)