Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
ba446263
Kaydet (Commit)
ba446263
authored
Eyl 21, 2012
tarafından
Pedro Giffuni
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Vigra: add missing mathutil.hxx patch
üst
b6d8f49c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
83 additions
and
0 deletions
+83
-0
vigra1.6.0.patch
vigra/vigra1.6.0.patch
+83
-0
No files found.
vigra/vigra1.6.0.patch
Dosyayı görüntüle @
ba446263
...
...
@@ -739,6 +739,89 @@ diff -uprN misc/vigra1.6.0/include/vigra/gaussians.hxx misc/build/vigra1.6.0/inc
}
calculateHermitePolynomial();
}
diff -uprN misc/vigra1.6.0/include/vigra/mathutil.hxx misc/build/vigra1.6.0/include/vigra/mathutil.hxx
--- misc/vigra1.6.0/include/vigra/mathutil.hxx 2008-08-13 08:15:38.000000000 -0500
+++ misc/build/vigra1.6.0/include/vigra/mathutil.hxx 2012-09-20 22:05:29.000000000 -0500
@@ -88,7 +88,7 @@ using VIGRA_CSTD::ceil;
// import abs(float), abs(double), abs(long double) from <cmath>
// and abs(int), abs(long), abs(long long) from <cstdlib>
-using std::abs;
+//using std::abs;
// define the missing variants of abs() to avoid 'ambigous overload'
// errors in template functions
@@ -100,10 +100,39 @@ VIGRA_DEFINE_UNSIGNED_ABS(unsigned char)
VIGRA_DEFINE_UNSIGNED_ABS(unsigned short)
VIGRA_DEFINE_UNSIGNED_ABS(unsigned int)
VIGRA_DEFINE_UNSIGNED_ABS(unsigned long)
+#ifdef VIGRA_HAS_LONG_LONG
VIGRA_DEFINE_UNSIGNED_ABS(unsigned long long)
+#endif
#undef VIGRA_DEFINE_UNSIGNED_ABS
+#define VIGRA_DEFINE_SIGNED_ABS(T) \
+ inline T abs(T t) { return (T)abs(t); }
+#define VIGRA_DEFINE_SIGNED_LABS(T) \
+ inline T abs(T t) { return (T)labs(t); }
+#define VIGRA_DEFINE_SIGNED_LLABS(T) \
+ inline T abs(T t) { return (T)llabs(t); }
+#define VIGRA_DEFINE_FABS(T) \
+ inline T abs(T t) { return (T)fabs(t); }
+
+VIGRA_DEFINE_SIGNED_ABS(signed char)
+VIGRA_DEFINE_SIGNED_ABS(signed short)
+VIGRA_DEFINE_SIGNED_ABS(signed int)
+VIGRA_DEFINE_SIGNED_LABS(signed long)
+#ifdef VIGRA_HAS_LONG_LONG
+VIGRA_DEFINE_SIGNED_LLABS(signed long long)
+#endif
+VIGRA_DEFINE_FABS(float)
+VIGRA_DEFINE_FABS(double)
+#ifdef VIGRA_HAS_LONG_DOUBLE
+VIGRA_DEFINE_FABS(long double)
+#endif
+
+#undef VIGRA_DEFINE_SIGNED_ABS
+#undef VIGRA_DEFINE_SIGNED_LABS
+#undef VIGRA_DEFINE_SIGNED_LLABS
+#undef VIGRA_DEFINE_FABS
+
#define VIGRA_DEFINE_MISSING_ABS(T) \
inline T abs(T t) { return t < 0 ? -t : t; }
@@ -134,12 +163,14 @@ inline double round(double t)
: ceil(t - 0.5);
}
+#ifdef VIGRA_HAS_LONG_DOUBLE
inline long double round(long double t)
{
return t >= 0.0
? floor(t + 0.5)
: ceil(t - 0.5);
}
+#endif
/*! Round up to the nearest power of 2.
@@ -440,9 +471,15 @@ VIGRA_DEFINE_NORM(int)
VIGRA_DEFINE_NORM(unsigned int)
VIGRA_DEFINE_NORM(long)
VIGRA_DEFINE_NORM(unsigned long)
+#ifdef VIGRA_HAS_LONG_LONG
+VIGRA_DEFINE_NORM(long long)
+VIGRA_DEFINE_NORM(unsigned long long)
+#endif
VIGRA_DEFINE_NORM(float)
VIGRA_DEFINE_NORM(double)
+#ifdef VIGRA_HAS_LONG_DOUBLE
VIGRA_DEFINE_NORM(long double)
+#endif
#undef VIGRA_DEFINE_NORM
diff -uprN misc/vigra1.6.0/include/vigra/numerictraits.hxx misc/build/vigra1.6.0/include/vigra/numerictraits.hxx
--- misc/vigra1.6.0/include/vigra/numerictraits.hxx 2008-08-13 08:15:39.000000000 -0500
+++ misc/build/vigra1.6.0/include/vigra/numerictraits.hxx 2012-09-19 17:30:24.000000000 -0500
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment