academic/stellarium: Updated for version 0.10.2
This commit is contained in:
parent
58114d9c9b
commit
8b72deef21
|
@ -5,11 +5,4 @@ projectors. Just set your coordinates and go.
|
|||
For reasonable performance, you will want to have some kind of 3D
|
||||
acceleration.
|
||||
|
||||
Starting from version 0.9.1, stellarium REQUIRES qt4 be installed. The
|
||||
build system has gone through a bit of changes too cmake is now used
|
||||
instead of the configure script. Cmake will search for qmake and other qt4
|
||||
executables so, if they're not already present inside the PATH variable,
|
||||
you will have to tell cmake where it can find it, using the QT4PATH variable
|
||||
inside the script.
|
||||
|
||||
Requiers: qt4 and boost both of which you can find at slackbuilds.org
|
||||
Requires qt4 and boost both of which you can find at slackbuilds.org.
|
|
@ -1,183 +0,0 @@
|
|||
diff -Naur stellarium-0.9.1.orig/src/StelApp.cpp stellarium-0.9.1/src/StelApp.cpp
|
||||
--- stellarium-0.9.1.orig/src/StelApp.cpp 2008-01-17 09:15:35.000000000 -0500
|
||||
+++ stellarium-0.9.1/src/StelApp.cpp 2008-09-01 14:12:51.000000000 -0400
|
||||
@@ -141,7 +141,7 @@
|
||||
{
|
||||
Translator::init(stelFileMgr->findFile("data/iso639-1.utf8"));
|
||||
}
|
||||
- catch (exception& e)
|
||||
+ catch (std::exception& e)
|
||||
{
|
||||
cerr << "ERROR while loading translations: " << e.what() << endl;
|
||||
}
|
||||
@@ -180,7 +180,7 @@
|
||||
{
|
||||
fontMapFile = stelFileMgr->findFile(QFile::decodeName("data/fontmap.dat"));
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
cerr << "ERROR when locating font map file: " << e.what() << endl;
|
||||
}
|
||||
@@ -243,7 +243,7 @@
|
||||
{
|
||||
iconPath = stelFileMgr->findFile("data/icon.bmp");
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
cerr << "ERROR when trying to locate icon file: " << e.what() << endl;
|
||||
}
|
||||
@@ -425,7 +425,7 @@
|
||||
stelFileMgr->findFile("landscapes/" + *i + "/landscape.ini");
|
||||
cout << (*i).toUtf8().data() << endl;
|
||||
}
|
||||
- catch(exception& e){}
|
||||
+ catch(std::exception& e){}
|
||||
}
|
||||
exit(0);
|
||||
}
|
||||
@@ -434,7 +434,7 @@
|
||||
{
|
||||
setConfigFile(qPrintable(argsGetOptionWithArg<QString>(argList, "-c", "--config-file", "config.ini")));
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
cerr << "ERROR: while looking for --config-file option: " << e.what() << ". Using \"config.ini\"" << endl;
|
||||
setConfigFile("config.ini");
|
||||
@@ -463,7 +463,7 @@
|
||||
projectionType = argsGetOptionWithArg<QString>(argList, "", "--projection-type", "");
|
||||
|
||||
}
|
||||
- catch (exception& e)
|
||||
+ catch (std::exception& e)
|
||||
{
|
||||
cerr << "ERROR while checking command line options: " << e.what() << endl;
|
||||
exit(0);
|
||||
@@ -746,7 +746,7 @@
|
||||
configFile = stelFileMgr->findFile(configName, StelFileMgr::FLAGS(StelFileMgr::WRITABLE|StelFileMgr::FILE));
|
||||
return;
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
//cerr << "DEBUG StelApp::setConfigFile could not locate writable config file " << configName << endl;
|
||||
}
|
||||
@@ -756,7 +756,7 @@
|
||||
configFile = stelFileMgr->findFile(configName, StelFileMgr::FILE);
|
||||
return;
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
//cerr << "DEBUG StelApp::setConfigFile could not find read only config file " << configName << endl;
|
||||
}
|
||||
@@ -767,7 +767,7 @@
|
||||
//cerr << "DEBUG StelApp::setConfigFile found NEW file path: " << configFile << endl;
|
||||
return;
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
cerr << "ERROR StelApp::setConfigFile could not find or create configuration file " << configName.toUtf8().data() << endl;
|
||||
exit(1);
|
||||
@@ -781,7 +781,7 @@
|
||||
{
|
||||
defaultConfigFilePath = stelFileMgr->findFile("data/default_config.ini");
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
cerr << "ERROR (copyDefaultConfigFile): failed to locate data/default_config.ini. Please check your installation." << endl;
|
||||
exit(1);
|
||||
diff -Naur stellarium-0.9.1.orig/src/stel_command_interface.cpp stellarium-0.9.1/src/stel_command_interface.cpp
|
||||
--- stellarium-0.9.1.orig/src/stel_command_interface.cpp 2008-01-17 09:15:35.000000000 -0500
|
||||
+++ stellarium-0.9.1/src/stel_command_interface.cpp 2008-09-01 14:16:11.000000000 -0400
|
||||
@@ -436,7 +436,7 @@
|
||||
image_filename = stapp->getFileMgr().findFile(image_filename);
|
||||
script_images->load_image(image_filename, args["name"].c_str(), img_pos);
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
cerr << "ERROR finding script: " << e.what() << endl;
|
||||
debug_message = _("Unable to open file: ") + image_filename.toStdWString();
|
||||
@@ -511,7 +511,7 @@
|
||||
audio = new Audio(QFile::encodeName(audioFilePath).constData(), "default track", StelUtils::stringToLong(args["output_rate"]));
|
||||
audio->play(args["loop"]=="on");
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
cerr << "ERROR while trying to play audio file: " << args["filename"] << " : " << e.what() << endl;
|
||||
}
|
||||
diff -Naur stellarium-0.9.1.orig/src/stel_ui_conf.cpp stellarium-0.9.1/src/stel_ui_conf.cpp
|
||||
--- stellarium-0.9.1.orig/src/stel_ui_conf.cpp 2008-01-17 09:15:35.000000000 -0500
|
||||
+++ stellarium-0.9.1/src/stel_ui_conf.cpp 2008-09-01 14:17:51.000000000 -0400
|
||||
@@ -620,7 +620,7 @@
|
||||
{
|
||||
fileName = StelApp::getInstance().getFileMgr().findFile(QString("data/cities_") + planetEnglishName.c_str() + ".fab");
|
||||
}
|
||||
- catch (exception& e)
|
||||
+ catch (std::exception& e)
|
||||
{
|
||||
cerr << "INFO StelUI::load_cities " << e.what() << endl;
|
||||
return;
|
||||
diff -Naur stellarium-0.9.1.orig/src/stel_ui_tuiconf.cpp stellarium-0.9.1/src/stel_ui_tuiconf.cpp
|
||||
--- stellarium-0.9.1.orig/src/stel_ui_tuiconf.cpp 2008-01-17 09:15:35.000000000 -0500
|
||||
+++ stellarium-0.9.1/src/stel_ui_tuiconf.cpp 2008-09-01 14:19:10.000000000 -0400
|
||||
@@ -155,7 +155,7 @@
|
||||
{
|
||||
tui_time_settmz = new s_tui::Time_zone_item(QFile::encodeName(app->getFileMgr().findFile("data/zone.tab")).constData(), wstring(L"2.2 "));
|
||||
}
|
||||
- catch(exception &e)
|
||||
+ catch(std::exception &e)
|
||||
{
|
||||
cerr << "ERROR locating zone file: " << e.what() << endl;
|
||||
}
|
||||
@@ -520,7 +520,7 @@
|
||||
cmd = "script action play filename \"" + SelectedScript
|
||||
+ "\" path \"" + QFile::encodeName(theParent).constData() + "/\"";
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
cerr << "ERROR while executing script " << SelectedScript << ": " << e.what() << endl;
|
||||
}
|
||||
@@ -677,7 +677,7 @@
|
||||
{
|
||||
saveCurrentConfig(app->getConfigFilePath());
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
cerr << "ERROR: could not save config.ini file: " << e.what() << endl;
|
||||
}
|
||||
@@ -686,7 +686,7 @@
|
||||
{
|
||||
system( QFile::encodeName(app->getFileMgr().findFile("data/script_save_config ")).constData());
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
cerr << "ERROR while calling script_save_config: " << e.what() << endl;
|
||||
}
|
||||
@@ -699,7 +699,7 @@
|
||||
{
|
||||
system( QFile::encodeName(app->getFileMgr().findFile("data/script_internet_update ")).constData());
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
cerr << "ERROR while calling script_internet_update: " << e.what() << endl;
|
||||
}
|
||||
@@ -713,7 +713,7 @@
|
||||
{
|
||||
system( QFile::encodeName(app->getFileMgr().findFile("data/script_shutdown ")).constData());
|
||||
}
|
||||
- catch(exception& e)
|
||||
+ catch(std::exception& e)
|
||||
{
|
||||
cerr << "ERROR while calling script_shutdown: " << e.what() << endl;
|
||||
}
|
|
@ -0,0 +1,3 @@
|
|||
if [ -x /usr/bin/update-desktop-database ]; then
|
||||
/usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
|
||||
fi
|
|
@ -22,10 +22,8 @@
|
|||
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
set -e
|
||||
|
||||
PRGNAM=stellarium
|
||||
VERSION=0.9.1
|
||||
VERSION=0.10.2
|
||||
ARCH=${ARCH:-i486}
|
||||
BUILD=${BUILD:-1}
|
||||
TAG=${TAG:-_SBo}
|
||||
|
@ -35,15 +33,6 @@ TMP=${TMP:-/tmp/SBo}
|
|||
PKG=$TMP/package-$PRGNAM
|
||||
OUTPUT=${OUTPUT:-/tmp}
|
||||
|
||||
# The path containg qt4. It will be added to PATH.
|
||||
# CMake needs qt4 qmake.
|
||||
# You have to specify it only if you do not have qt4 executables already inside PATH and
|
||||
# cmake fails to find qt4.
|
||||
|
||||
QT4PATH=""
|
||||
|
||||
# CFLAGS adjustment.
|
||||
|
||||
if [ "$ARCH" = "i486" ]; then
|
||||
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
|
||||
elif [ "$ARCH" = "i686" ]; then
|
||||
|
@ -54,46 +43,47 @@ elif [ "$ARCH" = "x86_64" ]; then
|
|||
SLKCFLAGS="-O2 -fPIC"
|
||||
fi
|
||||
|
||||
set -e
|
||||
|
||||
rm -rf $PKG
|
||||
mkdir -p $TMP $PKG $OUTPUT
|
||||
cd $TMP
|
||||
rm -rf $PRGNAM-$VERSION
|
||||
tar -xzvf $CWD/$PRGNAM-$VERSION.tar.gz
|
||||
|
||||
patch -p0 < $CWD/boost1.36.patch
|
||||
|
||||
cd $PRGNAM-$VERSION
|
||||
chown -R root:root .
|
||||
chmod -R a-s,u+w,go+r-w .
|
||||
|
||||
if [ "$QT4PATH" ]
|
||||
then
|
||||
CFLAGS="$SLKCFLAGS" \
|
||||
CXXFLAGS="$SLKCFLAGS" \
|
||||
PATH="$QT4PATH/bin":"$PATH" \
|
||||
cmake -DCMAKE_INSTALL_PREFIX=/usr .
|
||||
else
|
||||
CFLAGS="$SLKCFLAGS" \
|
||||
CXXFLAGS="$SLKCFLAGS" \
|
||||
cmake -DCMAKE_INSTALL_PREFIX=/usr .
|
||||
fi
|
||||
|
||||
make
|
||||
make install DESTDIR=$PKG
|
||||
|
||||
# Strip executables
|
||||
mkdir build && cd build
|
||||
cmake -DCMAKE_INSTALL_PREFIX=/usr \
|
||||
-DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
|
||||
-DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
|
||||
-DCMAKE_BUILD_TYPE="release" ..
|
||||
make
|
||||
make install DESTDIR=$PKG
|
||||
cd -
|
||||
|
||||
( cd "$PKG"
|
||||
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
|
||||
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
|
||||
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | \
|
||||
xargs strip --strip-unneeded 2> /dev/null || true
|
||||
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | \
|
||||
xargs strip --strip-unneeded 2> /dev/null
|
||||
)
|
||||
|
||||
mv $PKG/usr/share/man $PKG/usr
|
||||
gzip -9 $PKG/usr/man/man?/*.?
|
||||
|
||||
mkdir -p $PKG/usr/share/{applications,pixmaps}
|
||||
cat $CWD/$PRGNAM.desktop > $PKG/usr/share/applications/$PRGNAM.desktop
|
||||
cp -a doc/images/$PRGNAM-logo.png $PKG/usr/share/pixmaps/$PRGNAM.png
|
||||
|
||||
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
cp -a AUTHORS COPYING ChangeLog INSTALL README $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
|
||||
|
||||
mkdir -p $PKG/install
|
||||
cat $CWD/slack-desc > $PKG/install/slack-desc
|
||||
cat $CWD/doinst.sh > $PKG/install/doinst.sh
|
||||
|
||||
cd $PKG
|
||||
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
[Desktop Entry]
|
||||
Comment=a 3D planetarium which renders realistic skies in real time
|
||||
Comment[fr_FR]=un planetarium 3D au rendu réaliste en temps réel
|
||||
Exec=stellarium
|
||||
GenericName=3D planetarium
|
||||
GenericName[fr_FR]=planetarium 3D
|
||||
Icon=stellarium.png
|
||||
Name=stellarium
|
||||
StartupNotify=true
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Categories=Education;Science;Astronomy;
|
|
@ -1,8 +1,8 @@
|
|||
PRGNAM="stellarium"
|
||||
VERSION="0.9.1"
|
||||
VERSION="0.10.2"
|
||||
HOMEPAGE="http://www.stellarium.org"
|
||||
DOWNLOAD="http://downloads.sourceforge.net/stellarium/stellarium-0.9.1.tar.gz"
|
||||
MD5SUM="d0d55cb1ff5acd08a4d3b27d953579c0"
|
||||
MAINTAINER="Michael Bueker"
|
||||
DOWNLOAD="http://downloads.sourceforge.net/stellarium/stellarium-0.10.2.tar.gz"
|
||||
MD5SUM="c544fff9e75e9317055075b658ae5924"
|
||||
MAINTAINER="Alan Alberghini"
|
||||
EMAIL="414N@slacky.it"
|
||||
APPROVED="David Somero"
|
||||
APPROVED="dsomero"
|
||||
|
|
Loading…
Reference in New Issue