Re: CMake dependencies for arrow flight
(Nvm the libre2 error, It was my mistake) On Fri, Jul 29, 2022 at 4:49 PM Li Jin wrote: > Also, if it is the google re2, is there a minimum version required? > Currently my system has re2 from 20201101. > > On Fri, Jul 29, 2022 at 4:45 PM Li Jin wrote: > >> Thanks David! >> >> I used the code in the sql flight Cmakelist. Unfortunately I hit another >> error, I wonder if you happen to know a quick fix for this? (I don't >> know about libre2, is it https://github.com/google/re2 or sth else?) >> >> "libre2.so: cannot open shared object file: No such file or directory" >> >> On Fri, Jul 29, 2022 at 4:09 PM David Li wrote: >> >>> You'll also need to link to arrow_flight (and ditto for other libraries >>> you may want to use). >>> >>> Note that due to ARROW-12175 you may need a bit of finagling if you're >>> using CMake as your build system [1]. You can see a small workaround at [2]. >>> >>> [1]: https://issues.apache.org/jira/browse/ARROW-12175 >>> [2]: >>> https://github.com/apache/arrow-adbc/blob/41daacca08db041b52b458503e713a80528ba65a/c/drivers/flight_sql/CMakeLists.txt#L28-L31 >>> >>> -David >>> >>> On Fri, Jul 29, 2022, at 15:53, Li Jin wrote: >>> > (This is with Arrow 7.0.0) >>> > >>> > On Fri, Jul 29, 2022 at 3:52 PM Li Jin wrote: >>> > >>> >> Hi! >>> >> >>> >> I saw this error when linking my code against arrow flight and >>> suspect I >>> >> didn't write my cmake correctly: >>> >> >>> >> "error: undefined reference to arrow::flight::Location::Location()" >>> >> >>> >> I followed https://arrow.apache.org/docs/cpp/build_system.html#cmake >>> and >>> >> linked my executable with arrow_shared. Is that enough to link arrow >>> flight >>> >> or do I need to do sth else? >>> >> >>> >> Li >>> >> >>> >>
Re: CMake dependencies for arrow flight
Not sure what specifically is causing that error in your case, sorry. RE2 is indeed the regex engine. Arrow appears to select a newer version by default [1] but I'm not sure if this is *required*. However, the error indicates that the library just isn't there, or at least can't be found at runtime - so you may want to play with your LD_LIBRARY_PATH/ensure your Conda environment is active/etc. as appropriate. [1]: https://github.com/apache/arrow/blob/master/cpp/thirdparty/versions.txt#L80 -David On Fri, Jul 29, 2022, at 16:49, Li Jin wrote: > Also, if it is the google re2, is there a minimum version required? > Currently my system has re2 from 20201101. > > On Fri, Jul 29, 2022 at 4:45 PM Li Jin wrote: > >> Thanks David! >> >> I used the code in the sql flight Cmakelist. Unfortunately I hit another >> error, I wonder if you happen to know a quick fix for this? (I don't >> know about libre2, is it https://github.com/google/re2 or sth else?) >> >> "libre2.so: cannot open shared object file: No such file or directory" >> >> On Fri, Jul 29, 2022 at 4:09 PM David Li wrote: >> >>> You'll also need to link to arrow_flight (and ditto for other libraries >>> you may want to use). >>> >>> Note that due to ARROW-12175 you may need a bit of finagling if you're >>> using CMake as your build system [1]. You can see a small workaround at [2]. >>> >>> [1]: https://issues.apache.org/jira/browse/ARROW-12175 >>> [2]: >>> https://github.com/apache/arrow-adbc/blob/41daacca08db041b52b458503e713a80528ba65a/c/drivers/flight_sql/CMakeLists.txt#L28-L31 >>> >>> -David >>> >>> On Fri, Jul 29, 2022, at 15:53, Li Jin wrote: >>> > (This is with Arrow 7.0.0) >>> > >>> > On Fri, Jul 29, 2022 at 3:52 PM Li Jin wrote: >>> > >>> >> Hi! >>> >> >>> >> I saw this error when linking my code against arrow flight and suspect >>> I >>> >> didn't write my cmake correctly: >>> >> >>> >> "error: undefined reference to arrow::flight::Location::Location()" >>> >> >>> >> I followed https://arrow.apache.org/docs/cpp/build_system.html#cmake >>> and >>> >> linked my executable with arrow_shared. Is that enough to link arrow >>> flight >>> >> or do I need to do sth else? >>> >> >>> >> Li >>> >> >>> >>
Re: CMake dependencies for arrow flight
Also, if it is the google re2, is there a minimum version required? Currently my system has re2 from 20201101. On Fri, Jul 29, 2022 at 4:45 PM Li Jin wrote: > Thanks David! > > I used the code in the sql flight Cmakelist. Unfortunately I hit another > error, I wonder if you happen to know a quick fix for this? (I don't > know about libre2, is it https://github.com/google/re2 or sth else?) > > "libre2.so: cannot open shared object file: No such file or directory" > > On Fri, Jul 29, 2022 at 4:09 PM David Li wrote: > >> You'll also need to link to arrow_flight (and ditto for other libraries >> you may want to use). >> >> Note that due to ARROW-12175 you may need a bit of finagling if you're >> using CMake as your build system [1]. You can see a small workaround at [2]. >> >> [1]: https://issues.apache.org/jira/browse/ARROW-12175 >> [2]: >> https://github.com/apache/arrow-adbc/blob/41daacca08db041b52b458503e713a80528ba65a/c/drivers/flight_sql/CMakeLists.txt#L28-L31 >> >> -David >> >> On Fri, Jul 29, 2022, at 15:53, Li Jin wrote: >> > (This is with Arrow 7.0.0) >> > >> > On Fri, Jul 29, 2022 at 3:52 PM Li Jin wrote: >> > >> >> Hi! >> >> >> >> I saw this error when linking my code against arrow flight and suspect >> I >> >> didn't write my cmake correctly: >> >> >> >> "error: undefined reference to arrow::flight::Location::Location()" >> >> >> >> I followed https://arrow.apache.org/docs/cpp/build_system.html#cmake >> and >> >> linked my executable with arrow_shared. Is that enough to link arrow >> flight >> >> or do I need to do sth else? >> >> >> >> Li >> >> >> >
Re: CMake dependencies for arrow flight
Thanks David! I used the code in the sql flight Cmakelist. Unfortunately I hit another error, I wonder if you happen to know a quick fix for this? (I don't know about libre2, is it https://github.com/google/re2 or sth else?) "libre2.so: cannot open shared object file: No such file or directory" On Fri, Jul 29, 2022 at 4:09 PM David Li wrote: > You'll also need to link to arrow_flight (and ditto for other libraries > you may want to use). > > Note that due to ARROW-12175 you may need a bit of finagling if you're > using CMake as your build system [1]. You can see a small workaround at [2]. > > [1]: https://issues.apache.org/jira/browse/ARROW-12175 > [2]: > https://github.com/apache/arrow-adbc/blob/41daacca08db041b52b458503e713a80528ba65a/c/drivers/flight_sql/CMakeLists.txt#L28-L31 > > -David > > On Fri, Jul 29, 2022, at 15:53, Li Jin wrote: > > (This is with Arrow 7.0.0) > > > > On Fri, Jul 29, 2022 at 3:52 PM Li Jin wrote: > > > >> Hi! > >> > >> I saw this error when linking my code against arrow flight and suspect I > >> didn't write my cmake correctly: > >> > >> "error: undefined reference to arrow::flight::Location::Location()" > >> > >> I followed https://arrow.apache.org/docs/cpp/build_system.html#cmake > and > >> linked my executable with arrow_shared. Is that enough to link arrow > flight > >> or do I need to do sth else? > >> > >> Li > >> >
Re: CMake dependencies for arrow flight
You'll also need to link to arrow_flight (and ditto for other libraries you may want to use). Note that due to ARROW-12175 you may need a bit of finagling if you're using CMake as your build system [1]. You can see a small workaround at [2]. [1]: https://issues.apache.org/jira/browse/ARROW-12175 [2]: https://github.com/apache/arrow-adbc/blob/41daacca08db041b52b458503e713a80528ba65a/c/drivers/flight_sql/CMakeLists.txt#L28-L31 -David On Fri, Jul 29, 2022, at 15:53, Li Jin wrote: > (This is with Arrow 7.0.0) > > On Fri, Jul 29, 2022 at 3:52 PM Li Jin wrote: > >> Hi! >> >> I saw this error when linking my code against arrow flight and suspect I >> didn't write my cmake correctly: >> >> "error: undefined reference to arrow::flight::Location::Location()" >> >> I followed https://arrow.apache.org/docs/cpp/build_system.html#cmake and >> linked my executable with arrow_shared. Is that enough to link arrow flight >> or do I need to do sth else? >> >> Li >>
Re: CMake dependencies for arrow flight
(This is with Arrow 7.0.0) On Fri, Jul 29, 2022 at 3:52 PM Li Jin wrote: > Hi! > > I saw this error when linking my code against arrow flight and suspect I > didn't write my cmake correctly: > > "error: undefined reference to arrow::flight::Location::Location()" > > I followed https://arrow.apache.org/docs/cpp/build_system.html#cmake and > linked my executable with arrow_shared. Is that enough to link arrow flight > or do I need to do sth else? > > Li >