Hi,

Seems no one is looking into Ubuntu 20.04 compilation.
My X-300 is getting lonely...:(
If there are no objections, I can look it up myself.
I was thinking about fixing release_003_009_005.
Seems stable and hopefully need very little tweaking.
Since I don't know the code, I hope it's alright to ask here, if I
have any questions:)

These are all the errors I found with make -k (60% completion):
/home/nikos/work/uhd/host/lib/transport/udp_zero_copy.cpp:193:29:
error: ‘class boost::asio::basic_datagram_socket<boost::asio::ip::udp>’
has no member named ‘native’
/home/nikos/work/uhd/host/lib/transport/tcp_zero_copy.cpp:157:29:
error: ‘class boost::asio::basic_stream_socket<boost::asio::ip::tcp>’
has no member named ‘native’
/home/nikos/work/uhd/host/lib/transport/udp_simple.cpp:59:46: error:
‘class boost::asio::basic_datagram_socket<boost::asio::ip::udp>’ has
no member named ‘native’
/home/nikos/work/uhd/host/lib/usrp/x300/x300_impl.cpp:1475:114: error:
no matching function for call to
‘boost::date_time::subsecond_duration<boost::posix_time::time_duration,
1000>::subsecond_duration(double)’
/usr/include/boost/date_time/time_duration.hpp:285:14: error: no type
named ‘type’ in ‘struct boost::enable_if<boost::is_integral<double>,
void>’

The first 3 I replaced:
_socket->native() -> _socket->native_handle()   Compiles OK.

The last 2 are from the same place in x300_impl.cpp. This is a time
loop of 1 ms, until timeout. The code is perfectly
sound :
boost::system_time timeout_time = boost::get_system_time() +
boost::posix_time::milliseconds(timeout * 1000.0);

What this has to do with subsecond_duration?

From /usr/include/boost/date_time/time_duration.hpp: 285
public:
    // The argument (ss) must be an integral type
    template <typename T>
    explicit subsecond_duration(T const& ss,
                                typename
boost::enable_if<boost::is_integral<T>, void>::type* =
BOOST_DATE_TIME_NULLPTR) :
      base_duration(impl_type(traits_type::ticks_per_second >=
frac_of_second ? ss * adjustment_ratio : ss / adjustment_ratio))

I could rewrite the time loop in C, outside boost, but don't want to
break structure. Any ideas why is the compiler complaining?

TIA
Nikos



Nikos

On Wed, Apr 20, 2022 at 6:05 AM Marcus D. Leech <patchvonbr...@gmail.com> wrote:
>
> On 2022-04-19 22:45, Nikos Balkanas wrote:
> > Hi,
> >
> > I used to have Ubuntu 14.04 and had no issues with uhd. Recently i had
> > to upgrade to Ubuntu 20.04, and I can't find *any* uhd version that
> > can compile in it. I have tried over 20 from git from 3.9.0 to
> > 3.11.5:(
> >
> > With earlier releases like 3.9.x I get into boost problems, and
> > something like "native" not defined.
> > In more recent releases like 3.11.x I get:
> >
> > In file included from
> > /home/nikos/work/uhd/host/lib/usrp/cores/gpio_atr_3000.cpp:8:
> > /home/nikos/work/uhd/host/lib/usrp/cores/gpio_atr_3000.hpp:20:42:
> > error: expected class-name before ‘{’ token
> >     20 | class gpio_atr_3000 : boost::noncopyable {
> >        |                                          ^
> > make[2]: *** [lib/CMakeFiles/uhd.dir/build.make:1237:
> > lib/CMakeFiles/uhd.dir/usrp/cores/gpio_atr_3000.cpp.o] Error 1
> > make[1]: *** [CMakeFiles/Makefile2:655: lib/CMakeFiles/uhd.dir/all] Error 2
> > make: *** [Makefile:163: all] Error 2
> >
> > This seems like a c++ issue...
> >
> > Is there any git release that compiles in Ubuntu 20.04?
> > I know that you list in supported versions, only Ubuntu 14.04 & 16.04,
> > but I suspect this is outdated, since Ubuntu doesn't support them any
> > more, and in uhd installation you describe 20.04 build instructions.
> >
> > TIA
> > Nikos
> > _______________________________________________
> > USRP-users mailing list -- usrp-users@lists.ettus.com
> > To unsubscribe send an email to usrp-users-le...@lists.ettus.com
> For Ubuntu 20.04, you can just install it from the package repo using
> APT--no need to compile it.
>
> _______________________________________________
> USRP-users mailing list -- usrp-users@lists.ettus.com
> To unsubscribe send an email to usrp-users-le...@lists.ettus.com
_______________________________________________
USRP-users mailing list -- usrp-users@lists.ettus.com
To unsubscribe send an email to usrp-users-le...@lists.ettus.com

Reply via email to