2018-02-24 13:12:44 +00:00
|
|
|
{ stdenv, fetchurl, SDL, SDL_ttf, SDL_image, libSM, libICE, libGLU_combined, libpng, lua5, autoconf, automake }:
|
2011-07-08 22:23:55 +01:00
|
|
|
|
2012-10-10 18:25:42 +01:00
|
|
|
stdenv.mkDerivation rec {
|
2015-01-27 12:35:08 +00:00
|
|
|
name = "gravit-0.5.1";
|
2011-07-08 22:23:55 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
2018-06-23 12:34:55 +01:00
|
|
|
url = "https://gravit.slowchop.com/media/downloads/${name}.tgz";
|
2015-01-27 12:35:08 +00:00
|
|
|
sha256 = "14vf7zj2bgrl96wsl3f1knsggc8h9624354ajzd72l46y09x5ky7";
|
2011-07-08 22:23:55 +01:00
|
|
|
};
|
|
|
|
|
2018-02-24 13:12:44 +00:00
|
|
|
buildInputs = [ libGLU_combined SDL SDL_ttf SDL_image lua5 libpng libSM libICE ];
|
2011-07-08 22:23:55 +01:00
|
|
|
|
2016-08-27 22:22:59 +01:00
|
|
|
nativeBuildInputs = [ autoconf automake ];
|
|
|
|
|
2017-11-21 04:27:10 +00:00
|
|
|
preConfigure = ''
|
|
|
|
./autogen.sh
|
|
|
|
|
|
|
|
# Build fails on Linux with windres.
|
|
|
|
export ac_cv_prog_WINDRES=
|
|
|
|
'';
|
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
2011-07-08 22:23:55 +01:00
|
|
|
|
|
|
|
meta = {
|
2018-06-30 01:18:27 +01:00
|
|
|
homepage = https://gravit.slowchop.com;
|
2014-08-24 15:21:08 +01:00
|
|
|
description = "Beautiful OpenGL-based gravity simulator";
|
2014-06-19 05:19:00 +01:00
|
|
|
license = stdenv.lib.licenses.gpl2;
|
2011-07-08 22:23:55 +01:00
|
|
|
|
|
|
|
longDescription = ''
|
2011-11-08 10:01:14 +00:00
|
|
|
Gravit is a gravity simulator which runs under Linux, Windows and
|
2017-08-06 23:05:18 +01:00
|
|
|
macOS. It uses Newtonian physics using the Barnes-Hut N-body
|
2011-07-08 22:23:55 +01:00
|
|
|
algorithm. Although the main goal of Gravit is to be as accurate
|
|
|
|
as possible, it also creates beautiful looking gravity patterns.
|
|
|
|
It records the history of each particle so it can animate and
|
|
|
|
display a path of its travels. At any stage you can rotate your
|
|
|
|
view in 3D and zoom in and out.
|
|
|
|
'';
|
|
|
|
|
2011-07-14 21:53:30 +01:00
|
|
|
platforms = stdenv.lib.platforms.mesaPlatforms;
|
2018-06-23 22:35:31 +01:00
|
|
|
hydraPlatforms = stdenv.lib.platforms.linux; # darwin times out
|
2011-07-08 22:23:55 +01:00
|
|
|
};
|
|
|
|
}
|