I checked out nghttp2/asio in my C++ project. I have built boost version 1.89.0 from source using b2.
I am met with error "Could not find version of library" and as per the configure shell script that is generated after autoreconf, it is coming because of BOOST_ASIO_LIB.
As per boost's documentation below code should be enough for asio files generation.
b2 --with-system --with-thread --with-date_time --with-regex --with-serialization stage
./b2 install --prefix=$BOOST_PATH threading=multi link=static --with-system --with-thread --with-date_time
- In this case I was generating only the relevant libraries I needed.
./b2 link=static threading=multi --build-type=minimal --prefix=$BOOST_PATH install
- This would build all the libraries I need. The resulting files would be placed in $SOME_PATH.
/b2 --with-system --with-thread --with-date_time --with-regex --with-asio --with-serialization --prefix=$BOOST_PATH stage
- In this case I would create a stage build, for specific libraries.
I tried because I went through the configure shell script for nghttp2-asio, which was generated after autoreconf.
if test "x$BOOST_ROOT" != "x"; then
for libsubdir in $libsubdirs ; do
if ls "$BOOST_ROOT/stage/$libsubdir/libboost_"* >/dev/null 2>&1 ; then break; fi
done
if test -d "$BOOST_ROOT" && test -r "$BOOST_ROOT" && test -d "$BOOST_ROOT/stage/$libsubdir" && test -r "$BOOST_ROOT/stage/$libsubdir"; then
version_dir=`expr //$BOOST_ROOT : '.*/\(.*\)'`
stage_version=`echo $version_dir | sed 's/boost_//' | sed 's/_/./g'`
stage_version_shorten=`expr $stage_version : '\([0-9]*\.[0-9]*\)'`
V_CHECK=`expr $stage_version_shorten \>\= $_version`
if test "$V_CHECK" = "1" -a "$ac_boost_lib_path" = "" ; then
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: We will use a staged boost library from $BOOST_ROOT" >&5
printf "%s\n" "$as_me: We will use a staged boost library from $BOOST_ROOT" >&6;}
BOOST_CPPFLAGS="-I$BOOST_ROOT"
BOOST_LDFLAGS="-L$BOOST_ROOT/stage/$libsubdir"
fi
fi
fi
fi
- I have also tried this by setting $BOOST_ROOT, and then I ran the configure script of nghttp2-asio.
./configure --prefix=$PREFIX_PATH --enable-asio-lib --with-boost=$BOOST_PATH
I want to make static libraries that I can work and use.
I have gone through the configure script and nothing obvious has stood out to me. I have spent a lot of time on this, and I would like to know what I am doing wrong here. Any help would be appreciated.