summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 7c49c68)
raw | patch | inline | side by side (parent: 7c49c68)
author | schwarzenberg <schwarzenberg@users.sourceforge.net> | |
Thu, 1 Mar 2007 09:43:25 +0000 (09:43 +0000) | ||
committer | schwarzenberg <schwarzenberg@users.sourceforge.net> | |
Thu, 1 Mar 2007 09:43:25 +0000 (09:43 +0000) |
12 files changed:
ChangeLog | patch | blob | history | |
configure.ac | patch | blob | history | |
src/display/nr-filter-gaussian.cpp | patch | blob | history | |
src/display/nr-filter.cpp | patch | blob | history | |
src/display/pixblock-transform.cpp | patch | blob | history | |
src/extension/internal/ps.cpp | patch | blob | history | |
src/isinf.h | [new file with mode: 0644] | patch | blob |
src/isnan.h | patch | blob | history | |
src/libcola/gradient_projection.cpp | patch | blob | history | |
src/libvpsc/isnan.h | [deleted file] | patch | blob | history |
src/print.cpp | patch | blob | history | |
src/widgets/desktop-widget.cpp | patch | blob | history |
diff --git a/ChangeLog b/ChangeLog
index 1a1180e74f3920cb4e37a033c91eb85cb9575449..5221f8d1d8b364c0ebe74dffe0dd343f03e86346 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
+2007-03-01 Markus Schwarzenberg <Markus.Schwarzenberg@ipms.fraunhofer.de>
+
+ Solaris 8 / gcc-3.2.3 fixes (selectively effecting only this special
+
+ * src/display/nr-filter-gaussian.cpp:
+
+ * include compatibility header "isnormal.h"
+ * template calcTriggsSdikaInitialization<PC> needs to be
+ specified explicitely for gcc 3.2.3
+
+ * src/display/pixblock-transform.cpp, src/display/nr-filter.cpp,
+ src/display/nr-filter.cpp
+
+ * include compatibility header "round.h"
+ * using Inkscape::round
+
+ * src/extension/internal/ps.cpp, src/print.cpp
+
+ include <unistd.h> on SOLARIS_2_8 for open, unlink
+
+ * src/libcola/gradient_projection.cpp
+
+ include and use compatibility headers "isnan.h" "isinf.h"
+
+ * removed obsolete src/libvpsc/isnan.h
+
+ * added src/isinf.h
+
+ * configure.ac: Added Detection of solaris2.8 --> CXXFLAGS += -DSOLARIS_2_8
+
2006-08-05 John Bintz <jcoswell@coswellproductions.org>
* node-context.cpp, nodepath.cpp:
diff --git a/configure.ac b/configure.ac
index d1d8eb114109146820015751f74f1d367d11630a..310efa16f6e3f9f72c943ee73d49d1a1d460bb83 100644 (file)
--- a/configure.ac
+++ b/configure.ac
AC_MSG_RESULT([$platform_win32])
AM_CONDITIONAL(PLATFORM_WIN32, test "$platform_win32" = "yes")
+AC_MSG_CHECKING([for Solaris 2.8 platform])
+case "$host" in
+ *-solaris2.8)
+ platform_solaris_2_8=yes
+ CFLAGS="$CFLAGS -DSOLARIS_2_8"
+ CXXFLAGS="$CXXFLAGS -DSOLARIS_2_8"
+ ;;
+ *)
+ platform_solaris_2_8=no
+ ;;
+esac
+AC_MSG_RESULT([$platform_solaris_2_8])
+AM_CONDITIONAL(PLATFORM_SOLARIS_2_8, test "$platform_solaris_2_8" = "yes")
+
dnl ******************************
dnl Xft checking
dnl ******************************
index 7ebeebd88bc6d4e497add35da11882eba21eb159..42ab92808ff3ee8200cc085fb60511212311512b 100644 (file)
#include <glib.h>
#include <limits>
-using std::isnormal;
+#include "isnormal.h"
#include "display/nr-filter-primitive.h"
#include "display/nr-filter-gaussian.h"
}
// Backward pass
IIRValue v[N+1][PC];
- calcTriggsSdikaInitialization(M, u, iplus, iplus, b[0], v);
+ calcTriggsSdikaInitialization<PC>(M, u, iplus, iplus, b[0], v);
dstimg -= dstr1;
for(unsigned int c=0; c<PC; c++) dstimg[c] = clip_round_cast<PT>(v[0][c]);
int c1=n1-1;
index a720050c989b8a74899b4fde2637b85392bdf266..d2f459149575331ed447227b500b6108f1dad171 100644 (file)
#include "libnr/nr-scale.h"
#include "svg/svg-length.h"
#include "sp-filter-units.h"
+#include "round.h"
+using Inkscape::round;
//#include "display/nr-arena-shape.h"
index 7aa616eb3f30f0bd8e56ce4221ca4ed69e3d1bf3..2d5abc62c11a9910f4461710222ca93872bb4771 100644 (file)
#include <glib.h>
#include <cmath>
+#include "round.h"
+using Inkscape::round;
using std::floor;
#include "libnr/nr-pixblock.h"
index a4eac8b67e1e39fad4b7d53a5f3f78b00851d964..8cf2845363923a99e273f13095d60ad0d6fc77a0 100644 (file)
#include <iostream>
#include <fstream>
+#ifdef SOLARIS_2_8
+#include <unistd.h>
+#endif
+
using namespace std;
namespace Inkscape {
diff --git a/src/isinf.h b/src/isinf.h
--- /dev/null
+++ b/src/isinf.h
@@ -0,0 +1,15 @@
+#ifndef __ISINF_H__
+#define __ISINF_H__
+
+/*
+ * Fix for missing std::isnormal with SOLARIS8/GCC3.2
+ */
+
+#if defined (SOLARIS_2_8) && __GNUC__ == 3 && __GNUC_MINOR__ == 2
+
+ #include <ieeefp.h>
+ #define isinf(x) ((fpclass(x) == FP_NINF) || (fpclass(x) == FP_PINF))
+
+#endif
+
+#endif /* __ISINF_H__ */
diff --git a/src/isnan.h b/src/isnan.h
index 1b4d10aab0594e97d876f16cd4df5e7581cfabca..a1755bdb9459bbfd860ada5f937c720d98ab7efe 100644 (file)
--- a/src/isnan.h
+++ b/src/isnan.h
# define isNaN(_a) (_isnan(_a)) /* Win32 definition */
#elif defined(isnan) || defined(__FreeBSD__) || defined(__osf__)
# define isNaN(_a) (isnan(_a)) /* GNU definition */
+#elif defined (SOLARIS_2_8) && __GNUC__ == 3 && __GNUC_MINOR__ == 2
+# define isNaN(_a) (isnan(_a)) /* GNU definition */
#else
# define isNaN(_a) (std::isnan(_a))
#endif
# define isFinite(_a) (isfinite(_a))
#elif defined(__osf__)
# define isFinite(_a) (finite(_a) && !isNaN(_a))
+#elif defined (SOLARIS_2_8) && __GNUC__ == 3 && __GNUC_MINOR__ == 2
+#include <ieeefp.h>
+#define isFinite(_a) (finite(_a) && !isNaN(_a))
#else
# define isFinite(_a) (std::isfinite(_a))
#endif
index cec59c57ad37d01f356dfd9160a9686b87013c60..78b141b3e788ffb003cb01e3894df288da984cc6 100644 (file)
#include <libvpsc/constraint.h>
#include "gradient_projection.h"
#include <iostream>
+#include "isnan.h"
+#include "isinf.h"
+
using namespace std;
using namespace vpsc;
solver = setupVPSC();
//cerr << "in gradient projection: n=" << n << endl;
for (i=0;i<n;i++) {
- assert(!isnan(place[i]));
+ assert(!isNaN(place[i]));
assert(!isinf(place[i]));
vars[i]->desiredPosition=place[i];
}
// move to new unconstrained position
for (i=0; i<n; i++) {
place[i]-=alpha*g[i];
- assert(!isnan(place[i]));
+ assert(!isNaN(place[i]));
assert(!isinf(place[i]));
vars[i]->desiredPosition=place[i];
}
diff --git a/src/libvpsc/isnan.h b/src/libvpsc/isnan.h
--- a/src/libvpsc/isnan.h
+++ /dev/null
@@ -1,57 +0,0 @@
-#ifndef __ISNAN_H__
-#define __ISNAN_H__
-
-/*
- * Temporary fix for various misdefinitions of isnan().
- * isnan() is becoming undef'd in some .h files.
- * #include this last in your .cpp file to get it right.
- *
- * The problem is that isnan and isfinite are part of C99 but aren't part of
- * the C++ standard (which predates C99).
- *
- * Authors:
- * Inkscape groupies and obsessive-compulsives
- *
- * Copyright (C) 2004 authors
- *
- * Released under GNU LGPL, read the file 'COPYING' for more information
- *
- * 2005 modification hereby placed in public domain. Probably supercedes the 2004 copyright
- * for the code itself.
- */
-
-#include <math.h>
-/* You might try changing the above to <cmath> if you have problems.
- * Whether you use math.h or cmath, you may need to edit the .cpp file
- * and/or other .h files to use the same header file.
- */
-
-#if defined(__isnan)
-# define isNaN(_a) (__isnan(_a)) /* MacOSX/Darwin definition < 10.4 */
-#elif defined(WIN32) || defined(_isnan)
-# define isNaN(_a) (_isnan(_a)) /* Win32 definition */
-#elif defined(isnan) || defined(__FreeBSD__)
-# define isNaN(_a) (isnan(_a)) /* GNU definition */
-#else
-# define isNaN(_a) (std::isnan(_a))
-#endif
-/* If the above doesn't work, then try (a != a).
- * Also, please report a bug as per http://www.inkscape.org/report_bugs.php,
- * giving information about what platform and compiler version you're using.
- */
-
-
-#if defined(__isfinite)
-# define isFinite(_a) (__isfinite(_a)) /* MacOSX/Darwin definition < 10.4 */
-#elif defined(isfinite)
-# define isFinite(_a) (isfinite(_a))
-#else
-# define isFinite(_a) (std::isfinite(_a))
-#endif
-/* If the above doesn't work, then try (finite(_a) && !isNaN(_a)) or (!isNaN((_a) - (_a))).
- * Also, please report a bug as per http://www.inkscape.org/report_bugs.php,
- * giving information about what platform and compiler version you're using.
- */
-
-
-#endif /* __ISNAN_H__ */
diff --git a/src/print.cpp b/src/print.cpp
index 52a8d3c8236781337e53c6de3688396ad4c1e3fc..dad80d1c979425f0af313485b236016c9e5da892 100644 (file)
--- a/src/print.cpp
+++ b/src/print.cpp
#include <gtk/gtkprintunixdialog.h>
#endif
+#ifdef SOLARIS_2_8
+#include <unistd.h>
+#endif
+
#if 0
# include <extension/internal/ps.h>
index d7e5891c61cb7bb5e6cf7214c9545c8ce485faa4..93b579adfcb7f0198858ae1fe1117b0940e8c5da 100644 (file)
#include "sp-item.h"
#include "dialogs/swatches.h"
#include "conn-avoid-ref.h"
+#include "round.h"
+using Inkscape::round;
#ifdef WITH_INKBOARD
#endif