pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/databases/gigabase Fix portability by explicit casts t...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/aa8d5bc03dfa
branches:  trunk
changeset: 425306:aa8d5bc03dfa
user:      joerg <joerg%pkgsrc.org@localhost>
date:      Fri Mar 20 20:45:46 2020 +0000

description:
Fix portability by explicit casts to resolve ambiguity. Don't
reimplement standard C functions.

diffstat:

 databases/gigabase/distinfo                         |   5 ++++-
 databases/gigabase/patches/patch-query.h            |  12 ++++++++++++
 databases/gigabase/patches/patch-testddl.cpp        |  15 +++++++++++++++
 databases/gigabase/patches/patch-testtimeseries.cpp |  13 +++++++++++++
 4 files changed, 44 insertions(+), 1 deletions(-)

diffs (68 lines):

diff -r a3cf3f46cb5c -r aa8d5bc03dfa databases/gigabase/distinfo
--- a/databases/gigabase/distinfo       Fri Mar 20 20:44:15 2020 +0000
+++ b/databases/gigabase/distinfo       Fri Mar 20 20:45:46 2020 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.4 2015/11/03 01:56:11 agc Exp $
+$NetBSD: distinfo,v 1.5 2020/03/20 20:45:46 joerg Exp $
 
 SHA1 (gigabase-3.82.tar.gz) = b90a4b14f441fb80260bf7f2e332ef4a4e9e736f
 RMD160 (gigabase-3.82.tar.gz) = 91f4ec9318e64e861982cf3fb8031d27bc1e8e80
@@ -6,3 +6,6 @@
 Size (gigabase-3.82.tar.gz) = 1746054 bytes
 SHA1 (patch-aa) = b36dceea6f9c69e7b315923bea7e3bbf377607c8
 SHA1 (patch-class.h) = 86f10c351d52b562bf5e311110a1547140e2284d
+SHA1 (patch-query.h) = 44b50ad53c389bf8f6473738b118b3551b057c81
+SHA1 (patch-testddl.cpp) = d42f3bf7b4b120c97500b045a3eea811d5239b3e
+SHA1 (patch-testtimeseries.cpp) = 11f8dc2f31a5b0b71ae76b900f9aeaf3ff63fd90
diff -r a3cf3f46cb5c -r aa8d5bc03dfa databases/gigabase/patches/patch-query.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/gigabase/patches/patch-query.h  Fri Mar 20 20:45:46 2020 +0000
@@ -0,0 +1,12 @@
+$NetBSD: patch-query.h,v 1.1 2020/03/20 20:45:46 joerg Exp $
+
+--- query.h.orig       2020-03-20 18:58:57.685093966 +0000
++++ query.h
+@@ -710,6 +710,7 @@ inline dbQuery& add(dbQuery& query, dbAr
+ #endif
+ 
+ #define USER_FUNC(f) static dbUserFunction f##_descriptor(&f, STRLITERAL(#f))
++#define USER_FUNC2(f,g) static dbUserFunction f##_descriptor(g, STRLITERAL(#f))
+ 
+ class  dbInheritedAttribute;
+ class  dbSynthesizedAttribute;
diff -r a3cf3f46cb5c -r aa8d5bc03dfa databases/gigabase/patches/patch-testddl.cpp
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/gigabase/patches/patch-testddl.cpp      Fri Mar 20 20:45:46 2020 +0000
@@ -0,0 +1,15 @@
+$NetBSD: patch-testddl.cpp,v 1.1 2020/03/20 20:45:46 joerg Exp $
+
+--- testddl.cpp.orig   2020-03-20 18:59:33.126845571 +0000
++++ testddl.cpp
+@@ -102,8 +102,8 @@ class Record : public Base {
+ 
+ REGISTER(Record);
+ 
+-USER_FUNC(sin);
+-USER_FUNC(cos);
++USER_FUNC2(sin, (real8(*)(real8))(cos));
++USER_FUNC2(cos, (real8(*)(real8))(sin));
+ 
+ int __cdecl main()
+ {
diff -r a3cf3f46cb5c -r aa8d5bc03dfa databases/gigabase/patches/patch-testtimeseries.cpp
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/gigabase/patches/patch-testtimeseries.cpp       Fri Mar 20 20:45:46 2020 +0000
@@ -0,0 +1,13 @@
+$NetBSD: patch-testtimeseries.cpp,v 1.1 2020/03/20 20:45:46 joerg Exp $
+
+--- testtimeseries.cpp.orig    2020-03-20 19:03:40.088638131 +0000
++++ testtimeseries.cpp
+@@ -47,8 +47,6 @@ REGISTER_TEMPLATE(DailyBlock);
+ REGISTER(Stock);
+ 
+ inline int random(unsigned mod) { return rand() % mod; }
+-inline float fmax(float x, float y) { return x > y ? x : y; }
+-inline float fmin(float x, float y) { return x < y ? x : y; }
+ 
+ int main(int argc, char* argv[])
+ {



Home | Main Index | Thread Index | Old Index