My environment is Centos7,

I do not follow the question, since when i run `cmake` it says the version
arrow to use,,, e.g.

```
-- Building Apache Arrow from commit:
97f9029ce835dfc2655ca91b9820a2e6aed89107
-- Build Type: RELEASE
-- Compiler id: GNU
Selected compiler gcc 4.8.5
-- Found cpplint executable at /opt/parquet-cpp/build-support/cpplint.py
```

Again, I was referring to the environment variables setting in the
`ci/travis_script_static.sh`, and set my env vars like below:

```
  190  export ARROW_EP=/opt/parquet-cpp/arrow_ep-prefix/src/arrow_ep-build
  191  export BROTLI_EP=$ARROW_EP/brotli_ep/src/brotli_ep-install/lib
  193  export
SNAPPY_STATIC_LIB=$ARROW_EP/snappy_ep/src/snappy_ep-install/lib/libsnappy.a
  194  export BROTLI_STATIC_LIB_ENC=$BROTLI_EP/libbrotlienc.a
  195  export BROTLI_STATIC_LIB_DEC=$BROTLI_EP/libbrotlidec.a
  196  export BROTLI_STATIC_LIB_COMMON=$BROTLI_EP/libbrotlicommon.a
  197  export
ZLIB_STATIC_LIB=$ARROW_EP/zlib_ep/src/zlib_ep-install/lib/libz.a
```

And then i ran `cmake`...


Thanks,

On 7 January 2018 at 03:56, Deepak Majeti <[email protected]> wrote:

> What is the Arrow version of your setup? Can you verify if you see the same
> issue on parquet-cpp master?
> It is possible we are missing the boost filesystem library dependency for
> the static build with MSVC.
>
> On Sat, Jan 6, 2018 at 10:33 AM, ALeX Wang <[email protected]> wrote:
>
> > Okay, my following change makes it working,,, could anyone please help
> > confirm,
> >
> > ```
> > diff --git a/CMakeLists.txt b/CMakeLists.txt
> > index fef0cab..25defd6 100644
> > --- a/CMakeLists.txt
> > +++ b/CMakeLists.txt
> > @@ -500,7 +500,8 @@ if (PARQUET_BOOST_USE_SHARED)
> >  else()
> >    set(BOOST_LINK_LIBS
> >      boost_static_regex
> > -    boost_static_system)
> > +    boost_static_system
> > +    boost_static_filesystem)
> >  endif()
> >
> >  #############################################################
> > diff --git a/cmake_modules/ThirdpartyToolchain.cmake
> > b/cmake_modules/ThirdpartyToolchain.cmake
> > index 1221765..d19c4eb 100644
> > --- a/cmake_modules/ThirdpartyToolchain.cmake
> > +++ b/cmake_modules/ThirdpartyToolchain.cmake
> > @@ -81,13 +81,15 @@ if (PARQUET_BOOST_USE_SHARED)
> >  else()
> >    # Find static Boost libraries.
> >    set(Boost_USE_STATIC_LIBS ON)
> > -  find_package(Boost COMPONENTS regex system REQUIRED)
> > +  find_package(Boost COMPONENTS regex system filesystem REQUIRED)
> >    if ("${UPPERCASE_BUILD_TYPE}" STREQUAL "DEBUG")
> >      set(BOOST_STATIC_REGEX_LIBRARY ${Boost_REGEX_LIBRARY_DEBUG})
> >      set(BOOST_STATIC_SYSTEM_LIBRARY ${Boost_SYSTEM_LIBRARY_DEBUG})
> > +    set(BOOST_STATIC_FILESYSTEM_LIBRARY ${Boost_FILESYSTEM_LIBRARY_
> > DEBUG})
> >    else()
> >      set(BOOST_STATIC_REGEX_LIBRARY ${Boost_REGEX_LIBRARY_RELEASE})
> >      set(BOOST_STATIC_SYSTEM_LIBRARY ${Boost_SYSTEM_LIBRARY_RELEASE})
> > +    set(BOOST_STATIC_FILESYSTEM_LIBRARY
> > ${Boost_FILESYSTEM_LIBRARY_RELEASE})
> >    endif()
> >  endif()
> >
> > @@ -115,6 +117,8 @@ else()
> >    set_target_properties(boost_static_regex PROPERTIES IMPORTED_LOCATION
> > ${BOOST_STATIC_REGEX_LIBRARY})
> >    add_library(boost_static_system STATIC IMPORTED)
> >    set_target_properties(boost_static_system PROPERTIES
> IMPORTED_LOCATION
> > ${BOOST_STATIC_SYSTEM_LIBRARY})
> > +  add_library(boost_static_filesystem STATIC IMPORTED)
> > +  set_target_properties(boost_static_filesystem PROPERTIES
> > IMPORTED_LOCATION ${BOOST_STATIC_FILESYSTEM_LIBRARY})
> >  endif()
> >
> >  include_directories(SYSTEM ${Boost_INCLUDE_DIRS})
> > ```
> >
> > On 5 January 2018 at 20:29, ALeX Wang <[email protected]> wrote:
> >
> > > Also, i'm building from
> > >
> > > ```
> > > commit 18ca3922e688a3a730d693ff8f2cfbfd65da8c46
> > > Author: Uwe L. Korn <[email protected]>
> > > Date:   Sun Sep 17 13:55:43 2017 -0400
> > >
> > >     PARQUET-1094: Add benchmark for boolean Arrow column I/O
> > >
> > >     Author: Uwe L. Korn <[email protected]>
> > >
> > >     Closes #391 from xhochy/PARQUET-1094 and squashes the following
> > > commits:
> > >
> > >     089bb3c [Uwe L. Korn] PARQUET-1094: Add benchmark for boolean Arrow
> > > column I/O
> > > ```
> > >
> > > On 5 January 2018 at 20:27, ALeX Wang <[email protected]> wrote:
> > >
> > >> Hi,
> > >>
> > >> I'm referring to the https://github.com/apache/
> > >> parquet-cpp/blob/master/ci/travis_script_static.sh
> > >> and try to build static library,
> > >>
> > >> My cmake cmdline looks like:
> > >> ```
> > >> cmake3 -DCMAKE_BUILD_TYPE=Release -DPARQUET_BUILD_EXAMPLES=OFF
> > >> -DPARQUET_BUILD_TESTS=OFF  -DPARQUET_ARROW_LINKAGE="static"
> > >>  -DPARQUET_BUILD_SHARED=OFF -DPARQUET_BOOST_USE_SHARED=OFF  .
> > >> ```
> > >>
> > >> However, the compilation failed with:
> > >> ```
> > >> [ 90%] Linking CXX executable ../build/release/parquet-scan
> > >> ../build/release/libarrow.a(file.cc.o): In function
> > >> `arrow::io::FileOutputStream::Open(std::string const&, bool,
> > >> std::shared_ptr<arrow::io::FileOutputStream>*)':
> > >> file.cc:(.text+0x2f1f): undefined reference to
> > >> `boost::filesystem::path::codecvt()'
> > >> ../build/release/libarrow.a(file.cc.o): In function
> > >> `arrow::io::ReadableFile::Open(std::string const&,
> arrow::MemoryPool*,
> > >> std::shared_ptr<arrow::io::ReadableFile>*)':
> > >> file.cc:(.text+0x33d0): undefined reference to
> > >> `boost::filesystem::path::codecvt()'
> > >> ../build/release/libarrow.a(file.cc.o): In function
> > >> `arrow::io::ReadableFile::Open(std::string const&,
> > >> std::shared_ptr<arrow::io::ReadableFile>*)':
> > >> file.cc:(.text+0x3865): undefined reference to
> > >> `boost::filesystem::path::codecvt()'
> > >> ../build/release/libarrow.a(file.cc.o): In function
> > >> `arrow::io::MemoryMappedFile::MemoryMap::Open(std::string const&,
> > >> arrow::io::FileMode::type)':
> > >> file.cc:(.text._ZN5arrow2io16MemoryMappedFile9MemoryMap4Open
> > >> ERKSsNS0_8FileMode4typeE[_ZN5arrow2io16MemoryMappedFile9Memo
> > >> ryMap4OpenERKSsNS0_8FileMode4typeE]+0xba): undefined reference to
> > >> `boost::filesystem::path::codecvt()'
> > >> file.cc:(.text._ZN5arrow2io16MemoryMappedFile9MemoryMap4Open
> > >> ERKSsNS0_8FileMode4typeE[_ZN5arrow2io16MemoryMappedFile9Memo
> > >> ryMap4OpenERKSsNS0_8FileMode4typeE]+0x186): undefined reference to
> > >> `boost::filesystem::path::codecvt()'
> > >> collect2: error: ld returned 1 exit status
> > >> ```
> > >>
> > >> Any idea where I did wrong?
> > >>
> > >> Thanks,
> > >> --
> > >> Alex Wang,
> > >> Open vSwitch developer
> > >>
> > >
> > >
> > >
> > > --
> > > Alex Wang,
> > > Open vSwitch developer
> > >
> >
> >
> >
> > --
> > Alex Wang,
> > Open vSwitch developer
> >
>
>
>
> --
> regards,
> Deepak Majeti
>



-- 
Alex Wang,
Open vSwitch developer

Reply via email to