Bug 203043 - [new port] databases/rethinkdb 2.3.5
Summary: [new port] databases/rethinkdb 2.3.5
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Kurt Jaeger
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-11 15:19 UTC by Kurt Jaeger
Modified: 2017-09-21 11:16 UTC (History)
5 users (show)

See Also:


Attachments
shar (19.54 KB, text/plain)
2015-09-11 15:19 UTC, Kurt Jaeger
no flags Details
shar-v2 (24.39 KB, text/plain)
2015-09-11 22:27 UTC, Kurt Jaeger
no flags Details
shar-v3 (24.39 KB, text/plain)
2015-09-12 08:55 UTC, Kurt Jaeger
no flags Details
shar-v4 (26.85 KB, text/plain)
2015-09-13 20:20 UTC, Kurt Jaeger
no flags Details
shar-v5 (32.43 KB, text/plain)
2015-09-17 08:26 UTC, Kurt Jaeger
no flags Details
shar-v6 (33.67 KB, text/plain)
2015-09-18 10:28 UTC, Kurt Jaeger
no flags Details
v7 (37.40 KB, patch)
2015-09-23 10:46 UTC, Carlos J Puga Medina
no flags Details | Diff
poudriere testport on 93x64 (441.35 KB, text/plain)
2015-09-23 11:30 UTC, Carlos J Puga Medina
no flags Details
v8 (35.88 KB, text/plain)
2015-09-25 18:49 UTC, Carlos J Puga Medina
no flags Details
v9 2.3.5 of this port (35.27 KB, text/plain)
2016-09-04 14:48 UTC, Rodomar705
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kurt Jaeger freebsd_committer 2015-09-11 15:19:18 UTC
Created attachment 160930 [details]
shar

work in progress.

It builds until

[389/398] BUILD v8_3.30.33.16

and needs a little more patching.
Comment 1 Kurt Jaeger freebsd_committer 2015-09-11 22:27:34 UTC
Created attachment 160942 [details]
shar-v2

next, builds until v8, but fails to link v8.
Comment 2 Kurt Jaeger freebsd_committer 2015-09-12 08:55:41 UTC
Created attachment 160949 [details]
shar-v3

Builds up to a point, then fails to link v8.
Comment 3 Kurt Jaeger freebsd_committer 2015-09-12 08:56:06 UTC
See http://opsec.eu/backup/rethinkdb-build
for the build-log.
Comment 4 Kurt Jaeger freebsd_committer 2015-09-13 20:20:12 UTC
Created attachment 161007 [details]
shar-v4

this builds on current-amd64.
Comment 5 Kurt Jaeger freebsd_committer 2015-09-13 20:20:30 UTC
It still needs more cleanup.
Comment 6 Kurt Jaeger freebsd_committer 2015-09-17 08:26:08 UTC
Created attachment 161139 [details]
shar-v5

New version, builds in poudriere on current-amd64.
Testing on other versions @work.
Comment 7 Kurt Jaeger freebsd_committer 2015-09-18 10:28:35 UTC
Created attachment 161162 [details]
shar-v6

This builds on 11-current-amd64, 10.2 i+a.

It fails on 9.3a.

http://people.freebsd.org/~pi/logs/databases__rethinkdb-*
Comment 8 Carlos J Puga Medina 2015-09-19 15:20:51 UTC
(In reply to Kurt Jaeger from comment #7)

I'm going to take a look.
Comment 9 Carlos J Puga Medina 2015-09-23 10:46:55 UTC
Created attachment 161299 [details]
v7

More progress trying to fix rethinkdb build errors on 9.3-a.
Comment 10 Carlos J Puga Medina 2015-09-23 11:30:07 UTC
Created attachment 161302 [details]
poudriere testport on 93x64
Comment 11 Kurt Jaeger freebsd_committer 2015-09-23 12:07:41 UTC
v7 fails to build on 11-amd64.

Additional test-builds @work. Logfile will be provided soonish.
Comment 12 Carlos J Puga Medina 2015-09-23 12:25:48 UTC
(In reply to Kurt Jaeger from comment #11)

Yes, the latest added patches should be only be applied to 9.3a release.

rethinkdb/files/patch-src_rdb__protocol_geo_s2_util_endian_endian.h
rethinkdb/files/patch-src_rdb__protocol_geo_s2_util_coding_coder.h
Comment 13 Carlos J Puga Medina 2015-09-25 00:32:54 UTC
I made some changes in rethinkdb/Makefile. Testing work@
Comment 14 Carlos J Puga Medina 2015-09-25 18:49:16 UTC
Created attachment 161400 [details]
v8

- rethinkdb/files/patch-src_rdb__protocol_geo_s2_util_endian_endian.h
- rethinkdb/files/patch-src_rdb__protocol_geo_s2_util_coding_coder.h

Both patches were removed because they are wrong.
Comment 15 Kurt Jaeger freebsd_committer 2015-09-26 06:08:36 UTC
dependency www/node fails to build on 9.3a 8-(
Comment 16 Kurt Jaeger freebsd_committer 2015-10-11 09:14:50 UTC
9.3a build seems to be problematic, Carlos reports:

http://stackoverflow.com/questions/28415149/g-include-paths-on-freebsd

And there's an PR that has a bit more on the C++ issues:

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=193528

So, we'll add this with BROKEN on 9.
Comment 17 Kurt Jaeger freebsd_committer 2015-10-11 09:17:19 UTC
There's a version 2.1.5-2 out.
Comment 18 James T. Koerting 2015-11-07 15:31:20 UTC
In a 10.1p19 I got this with shar-v8:

./src/arch/io/timer/timer_signal_provider.hpp:23:5: error: unknown type name 'timer_t';

which I could overcome with:

--- src/arch/io/timer/timer_signal_provider.hpp.orig    2015-11-07 00:40:37.000000000 +0100
+++ src/arch/io/timer/timer_signal_provider.hpp 2015-11-06 23:49:19.000000000 +0100
@@ -20,7 +20,7 @@
 private:
     friend void timer_signal_provider_signal_handler(UNUSED int signum, siginfo_t *siginfo, UNUSED void *uctx);

-    timer_t timerid;
+    __timer_t timerid;
     timer_provider_callback_t *callback;

     DISABLE_COPYING(timer_signal_provider_t);


But then (with external re2/v8 and pkg installed re2/v8) I got this:


/usr/local/src/rethinkdb/work/rethinkdb-2.1.4/build/external/re2_20140111/lib/libre2.a(nfa.o): In function `re2::NFA::Search(re2::StringPiece const&, re2::StringPiece const&, bool, bool, re2::StringPiece*, int)':
re2/nfa.cc:(.text+0x11b2): undefined reference to `std::__1::basic_ostream<char, std::__1::char_traits<char> >::operator<<(void const*)'
re2/nfa.cc:(.text+0x11e7): undefined reference to `std::__1::basic_ostream<char, std::__1::char_traits<char> >::operator<<(void const*)'
/usr/local/src/rethinkdb/work/rethinkdb-2.1.4/build/external/re2_20140111/lib/libre2.a(tostring.o): In function `re2::ToStringWalker::PostVisit(re2::Regexp*, int, int, int*, int)':
re2/tostring.cc:(.text+0xb9a): undefined reference to `std::__1::basic_ostream<char, std::__1::char_traits<char> >::operator<<(void const*)'
/usr/local/src/rethinkdb/work/rethinkdb-2.1.4/build/external/v8_3.30.33.16/lib/libv8_base.a(code-stubs-hydrogen.o): In function `v8::internal::ToNumberStub::GenerateCode()':
../src/code-stubs-hydrogen.cc:(.text._ZN2v88internal12ToNumberStub12GenerateCodeEv+0xcd): undefined reference to `std::__1::basic_ostream<char, std::__1::char_traits<char> >::operator<<(void const*)'
/usr/local/src/rethinkdb/work/rethinkdb-2.1.4/build/external/v8_3.30.33.16/lib/libv8_base.a(code-stubs-hydrogen.o): In function `v8::internal::NumberToStringStub::GenerateCode()':
../src/code-stubs-hydrogen.cc:(.text._ZN2v88internal18NumberToStringStub12GenerateCodeEv+0xcd): undefined reference to `std::__1::basic_ostream<char, std::__1::char_traits<char> >::operator<<(void const*)'
/usr/local/src/rethinkdb/work/rethinkdb-2.1.4/build/external/v8_3.30.33.16/lib/libv8_base.a(code-stubs-hydrogen.o):../src/code-stubs-hydrogen.cc:(.text._ZN2v88internal25FastCloneShallowArrayStub12GenerateCodeEv+0xcd): more undefined references to `std::__1::basic_ostream<char, std::__1::char_traits<char> >::operator<<(void const*)' follow
c++: error: linker command failed with exit code 1 (use -v to see invocation)


I'm not to much a c/++ programmer, so that I'm not in the position to solve this on my own. Any idea/workaround which is known?
Comment 19 Kurt Jaeger freebsd_committer 2015-11-20 19:27:17 UTC
There's a version 2.2.1 out now.
Comment 20 outbackdingo 2016-06-08 13:40:22 UTC
Ive tried the v8 shar on 10.3-RELEASE FreeBSD 10.3-RELEASE
and below id what resulted. seems to have built fine, though there is no rc script for it i tried it manually

rethinkdb --config-file /usr/local/etc/rethinkdb/instances.d/default.conf 
Recursively removing directory /var/db/rethinkdb_data/tmp
In recursion: removing file /var/db/rethinkdb_data/tmp
Version: rethinkdb 2.1.4 (CLANG 3.4.1 (tags/RELEASE_34/dot1-final 208032))
error: Error in src/utils.cc at line 533:
error: Guarantee failed: [res == 0]  (errno 2 - No such file or directory) Fatal error: failed to delete '/var/db/rethinkdb_data/tmp'.
error: Backtrace:
error: Wed Jun  8 05:36:59 2016
       
       1: 0x804ec2 <_ZN11backtrace_tC1Ev+0x42> at /usr/local/bin/rethinkdb at 0x804ec2 ()
       2: 0x8055d4 <_ZN26lazy_backtrace_formatter_tC2Ev+0x24> at /usr/local/bin/rethinkdb at 0x8055d4 ()
       3: 0x804b29 <_Z16format_backtraceb+0x19> at /usr/local/bin/rethinkdb at 0x804b29 ()
       4: 0x8a22a8 <_Z18report_fatal_errorPKciS0_z+0x178> at /usr/local/bin/rethinkdb at 0x8a22a8 ()
       5: 0x80fa5d <_Z23remove_directory_helperPKcPK4statiP3FTW+0x8d> at /usr/local/bin/rethinkdb at 0x80fa5d ()
       6: 0x8061c2f5e <nftw+0xfe> at /lib/libc.so.7 at 0x8061c2f5e ()
       7: 0x80faf3 <_Z26remove_directory_recursivePKc+0x53> at /usr/local/bin/rethinkdb at 0x80faf3 ()
       8: 0x80fef6 <_Z28recreate_temporary_directoryRK11base_path_t+0xc6> at /usr/local/bin/rethinkdb at 0x80fef6 ()
       9: 0xa58936 <_Z24main_rethinkdb_porcelainiPPc+0x2f6> at /usr/local/bin/rethinkdb at 0xa58936 ()
       10: 0x8a0d03 <main+0x303> at /usr/local/bin/rethinkdb at 0x8a0d03 ()
       11: 0x78b74f <_start+0x16f> at /usr/local/bin/rethinkdb at 0x78b74f ()
error: Exiting.
Trace/BPT trap (core dumped)
Comment 21 Rodomar705 2016-09-04 14:48:38 UTC
Created attachment 174373 [details]
v9 2.3.5 of this port

Updated the port and patched to 2.3.5, the port compiles but fail to link the executable itself, need to track it down. There are some compilation issues from v8 headers if the package is installed system wide, probably the headers is parsed in the wrong order; for now the only way is to remove it. I hope that someone is interested in this.
Comment 22 Kurt Jaeger freebsd_committer 2017-02-05 09:20:30 UTC
To keep track of current event:

- Company behind rethink is closing
  http://www.rethinkdb.com/
  https://rethinkdb.com/blog/rethinkdb-shutdown/
  https://github.com/rethinkdb/rethinkdb/issues/6137#issuecomment-275968142
Comment 24 Carlos J. Puga Medina freebsd_committer 2017-02-06 23:50:15 UTC
Yes, it seems that RethinkDB has a second chance after the project has been donated to the Linux Foundation.

We can try to fix our port.

[1] https://github.com/rethinkdb/rethinkdb/pull/688
[2] https://github.com/rethinkdb/rethinkdb/pull/5974