summaryrefslogtreecommitdiffstats
path: root/astro/celestia/files
diff options
context:
space:
mode:
authoredwin <edwin@FreeBSD.org>2003-08-31 03:58:53 +0000
committeredwin <edwin@FreeBSD.org>2003-08-31 03:58:53 +0000
commit15e1f930fd554969e32abeebe9c5976a31fab335 (patch)
tree5ba042230186d6b0a16687d1c288f7f66f665e0b /astro/celestia/files
parent6c8012c0ed78f25668f62559e946979a0a1d2439 (diff)
downloadFreeBSD-ports-15e1f930fd554969e32abeebe9c5976a31fab335.zip
FreeBSD-ports-15e1f930fd554969e32abeebe9c5976a31fab335.tar.gz
Partly unbreak astro/celestia due to C++ issues.
Also applied PR ports/46149 PR: ports/46149 Submitted by: Brad Laue <brad@brad-x.com> Approved by: maintainer timeout
Diffstat (limited to 'astro/celestia/files')
-rw-r--r--astro/celestia/files/patch-src::celengine::starbrowser.h11
-rw-r--r--astro/celestia/files/patch-src::celestia::celestiacore.cpp21
2 files changed, 32 insertions, 0 deletions
diff --git a/astro/celestia/files/patch-src::celengine::starbrowser.h b/astro/celestia/files/patch-src::celengine::starbrowser.h
new file mode 100644
index 0000000..2e89a54
--- /dev/null
+++ b/astro/celestia/files/patch-src::celengine::starbrowser.h
@@ -0,0 +1,11 @@
+--- src/celengine/starbrowser.h.orig Sat Aug 30 20:38:54 2003
++++ src/celengine/starbrowser.h Sat Aug 30 20:39:08 2003
+@@ -12,6 +12,8 @@
+ #ifndef _CELENGINE_STARBROWSER_H_
+ #define _CELENGINE_STARBROWSER_H_
+
++using namespace std;
++
+ #include "star.h"
+ #include "stardb.h"
+ #include "simulation.h"
diff --git a/astro/celestia/files/patch-src::celestia::celestiacore.cpp b/astro/celestia/files/patch-src::celestia::celestiacore.cpp
new file mode 100644
index 0000000..e874e23
--- /dev/null
+++ b/astro/celestia/files/patch-src::celestia::celestiacore.cpp
@@ -0,0 +1,21 @@
+--- src/celestia/celestiacore.cpp.orig Sat Aug 30 20:44:13 2003
++++ src/celestia/celestiacore.cpp Sat Aug 30 20:48:22 2003
+@@ -38,7 +38,6 @@
+ #include "celestiacore.h"
+ #include <celutil/debug.h>
+
+-
+ using namespace std;
+
+ static const int DragThreshold = 3;
+@@ -1138,8 +1137,8 @@
+ {
+ double distFromSun = body.getHeliocentricPosition(t).distanceFromOrigin();
+ float planetTemp = sun->getTemperature() *
+- (float) (pow(1 - body.getAlbedo(), 0.25) *
+- sqrt(sun->getRadius() / (2 * distFromSun)));
++ (float) (pow((double)(1 - body.getAlbedo()),(double)( 0.25) *
++ sqrt(sun->getRadius() / (2 * distFromSun))));
+ overlay << setprecision(0);
+ overlay << "Temperature: " << planetTemp << " K\n";
+ overlay << setprecision(3);
OpenPOWER on IntegriCloud