[kstars] don't use TIME_UTC in enum
Rex Dieter
rdieter at fedoraproject.org
Sun Jun 10 20:33:06 UTC 2012
commit 821fe276459ccce09737916dbdb03f3cfde6371e
Author: Rex Dieter <rdieter at fedoraproject.org>
Date: Sun Jun 10 15:35:34 2012 -0500
don't use TIME_UTC in enum
newer glibc (c11) uses TIME_UTC itself, use something else
kstars-4.8.90-glibc.patch | 54 +++++++++++++++++++++++++++++++++++++++++++++
kstars.spec | 6 +++++
2 files changed, 60 insertions(+), 0 deletions(-)
---
diff --git a/kstars-4.8.90-glibc.patch b/kstars-4.8.90-glibc.patch
new file mode 100644
index 0000000..63f4c0e
--- /dev/null
+++ b/kstars-4.8.90-glibc.patch
@@ -0,0 +1,54 @@
+diff -up kstars-4.8.90/kstars/indi/indielement.h.glibc kstars-4.8.90/kstars/indi/indielement.h
+--- kstars-4.8.90/kstars/indi/indielement.h.glibc 2012-05-22 19:28:05.000000000 -0500
++++ kstars-4.8.90/kstars/indi/indielement.h 2012-06-10 15:31:40.593760560 -0500
+@@ -45,7 +45,7 @@ typedef enum {PG_NONE = 0, PG_TEXT, PG_N
+
+ /* INDI std properties */
+ /* N.B. Need to modify corresponding entry in indidevice.cpp when changed */
+-enum stdProperties { CONNECTION, DEVICE_PORT, TIME_UTC, TIME_LST, TIME_UTC_OFFSET, GEOGRAPHIC_COORD, /* General */
++enum stdProperties { CONNECTION, DEVICE_PORT, INDI_TIME_UTC, TIME_LST, TIME_UTC_OFFSET, GEOGRAPHIC_COORD, /* General */
+ EQUATORIAL_COORD, EQUATORIAL_EOD_COORD, EQUATORIAL_EOD_COORD_REQUEST, HORIZONTAL_COORD, /* Telescope */
+ TELESCOPE_ABORT_MOTION, ON_COORD_SET, SOLAR_SYSTEM, TELESCOPE_MOTION_NS, /* Telescope */
+ TELESCOPE_MOTION_WE, TELESCOPE_PARK, /* Telescope */
+diff -up kstars-4.8.90/kstars/indi/indiproperty.cpp.glibc kstars-4.8.90/kstars/indi/indiproperty.cpp
+--- kstars-4.8.90/kstars/indi/indiproperty.cpp.glibc 2012-05-22 19:28:05.000000000 -0500
++++ kstars-4.8.90/kstars/indi/indiproperty.cpp 2012-06-10 15:32:03.994468064 -0500
+@@ -481,7 +481,7 @@ int INDI_P::buildTextGUI(XMLEle *root, Q
+ return 0;
+
+ // INDI STD, but we use our own controls
+- if (name == "TIME_UTC")
++ if (name == "INDI_TIME_UTC")
+ {
+ setupSetButton("Time");
+ QObject::connect(set_w, SIGNAL(clicked()), indistd, SLOT(newTime()));
+diff -up kstars-4.8.90/kstars/indi/indistd.cpp.glibc kstars-4.8.90/kstars/indi/indistd.cpp
+--- kstars-4.8.90/kstars/indi/indistd.cpp.glibc 2012-05-22 19:28:05.000000000 -0500
++++ kstars-4.8.90/kstars/indi/indistd.cpp 2012-06-10 15:32:38.381038171 -0500
+@@ -248,7 +248,7 @@ void INDIStdDevice::setTextValue(INDI_P
+ switch (pp->stdID)
+ {
+
+- case TIME_UTC:
++ case INDI_TIME_UTC:
+ if ( Options::useTimeUpdate() && !driverTimeUpdated)
+ {
+ driverTimeUpdated = true;
+@@ -570,7 +570,7 @@ void INDIStdDevice::updateTime()
+ lp->updateValue(ksw->data()->geo()->TZ());
+ pp->newText();
+
+- pp = dp->findProp("TIME_UTC");
++ pp = dp->findProp("INDI_TIME_UTC");
+ if (!pp) return;
+
+ lp = pp->findElement("UTC");
+@@ -682,7 +682,7 @@ void INDIStdDevice::createDeviceInit()
+
+ if ( Options::useTimeUpdate() && Options::useComputerSource())
+ {
+- prop = dp->findProp("TIME_UTC");
++ prop = dp->findProp("INDI_TIME_UTC");
+ if (prop)
+ {
+ driverTimeUpdated = false;
diff --git a/kstars.spec b/kstars.spec
index bdd1f5b..e98b134 100644
--- a/kstars.spec
+++ b/kstars.spec
@@ -15,6 +15,10 @@ URL: http://edu.kde.org/kstars
%endif
Source0: http://download.kde.org/%{stable}/%{version}/src/%{name}-%{version}.tar.xz
+## upstreamable patches
+# newer glibc c11 defines/uses TIME_UTC itself, use something else
+Patch50: kstars-4.8.90-glibc.patch
+
BuildRequires: desktop-file-utils
BuildRequires: kdelibs4-devel >= %{version}
BuildRequires: pkgconfig(cfitsio)
@@ -38,6 +42,8 @@ all 8 planets, the Sun and Moon, and thousands of comets and asteroids.
%prep
%setup -q
+%patch50 -p1 -b .glibc
+
%build
mkdir -p %{_target_platform}
More information about the scm-commits
mailing list