Boost issue or no?

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Boost issue or no?

Boost - Dev mailing list
Hi all,

I am trying to build pCloudCC and not sure if this is a Boost issue or a
pCloud issue:

# make

[ 10%] Building C object CMakeFiles/sqlite3.dir/lib/sqlite/sqlite3.c.o

[ 20%] *Linking C static library libsqlite3.a*

[ 20%] Built target sqlite3

[ 30%] Building CXX object CMakeFiles/pcloudcc_lib.dir/pclsync_lib_c.cpp.o

[ 40%] Building CXX object CMakeFiles/pcloudcc_lib.dir/pclsync_lib.cpp.o

In file included from
*/root/build/console-client-master/pCloudCC/pclsync_lib.cpp:30:0*:

*/root/build/console-client-master/pCloudCC/lib/pclsync/pcompat.h:95:0:*
*warning:*"_GNU_SOURCE" redefined [enabled by default]

 #define _GNU_SOURCE

* ^*

*<command-line>:0:0:* *note: *this is the location of the previous
definition

In file included from
*/usr/local/include/boost/smart_ptr/detail/local_sp_deleter.hpp:20:0*,

                 from
*/usr/local/include/boost/smart_ptr/shared_ptr.hpp:1158*,

                 from */usr/local/include/boost/shared_ptr.hpp:17*,

                 from
*/root/build/console-client-master/pCloudCC/pclsync_lib.cpp:45*:

*/usr/local/include/boost/smart_ptr/detail/local_counted_base.hpp:* In
member function ‘*void boost::detail::local_counted_base::add_ref()*’:

*/usr/local/include/boost/smart_ptr/detail/local_counted_base.hpp:67:49:*
*error:
**__builtin_assume*’ was not declared in this scope

         __builtin_assume( local_use_count_ >= 1 );

*                                                 ^*

In file included from
*/usr/local/include/boost/smart_ptr/detail/sp_counted_impl.hpp:29:0*,

                 from
*/usr/local/include/boost/smart_ptr/detail/shared_count.hpp:30*,

                 from */usr/local/include/boost/smart_ptr/shared_ptr.hpp:28*
,

                 from */usr/local/include/boost/shared_ptr.hpp:17*,

                 from
*/root/build/console-client-master/pCloudCC/pclsync_lib.cpp:45*:

/usr/local/include/boost/core/addressof.hpp: In instantiation of ‘*T*
boost::addressof(T&) [with T = int (*)(_IO_FILE*)]*’:

*/usr/local/include/boost/smart_ptr/detail/sp_counted_impl.hpp:182:98:*
  required
from ‘*void* boost::detail::sp_counted_impl_pd<P,
D>::get_local_deleter(const sp_typeinfo&) [with P = _IO_FILE*; D = int
(*)(_IO_FILE*); boost::detail::sp_typeinfo = std::type_info]*’

*/root/build/console-client-master/pCloudCC/pclsync_lib.cpp:304:1:*   required
from here

*/usr/local/include/boost/core/addressof.hpp:40:33:* *error: *‘
*__builtin_addressof*’ was not declared in this scope

     return __builtin_addressof(o);

*                                 ^*

make[2]: *** [CMakeFiles/pcloudcc_lib.dir/pclsync_lib.cpp.o] Error 1

make[1]: *** [CMakeFiles/pcloudcc_lib.dir/all] Error 2

make: *** [all] Error 2

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Reply | Threaded
Open this post in threaded view
|

Re: Boost issue or no?

Boost - Dev mailing list
Joshua Alexander wrote:
...
> */usr/local/include/boost/smart_ptr/detail/local_counted_base.hpp:67:49:**error:**__builtin_assume*’
> was not declared in this scope
...
> */usr/local/include/boost/core/addressof.hpp:40:33:* *error: *‘*__builtin_addressof*’
> was not declared in this scope

What compiler are you using?


_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Reply | Threaded
Open this post in threaded view
|

Re: Boost issue or no?

Boost - Dev mailing list
>
> What compiler are you using?
>>
>
Not sure, trying to build on CentOS 7.

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Reply | Threaded
Open this post in threaded view
|

Re: Boost issue or no?

Boost - Dev mailing list
In reply to this post by Boost - Dev mailing list
Joshua Alexander wrote:
> Hi all,
>
> I am trying to build pCloudCC and not sure if this is a Boost issue or a
> pCloud issue:

...

> */usr/local/include/boost/smart_ptr/detail/local_counted_base.hpp:67:49:**error:**__builtin_assume*’
> was not declared in this scope
>         __builtin_assume( local_use_count_ >= 1 );

It's a pCloud issue. pCloud defines __has_builtin(x) to 1 here:

https://github.com/pcloudcom/console-client/blob/cd02e53e0d0f2884c5742899c84874dffa528834/pCloudCC/lib/pclsync/pcompiler.h#L50

which then makes Boost think that __builtin_assume is supported, and it
isn't. Similarly for __builtin_addressof.


_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Reply | Threaded
Open this post in threaded view
|

Re: Boost issue or no?

Boost - Dev mailing list
Thanks so much!


> It's a pCloud issue. pCloud defines __has_builtin(x) to 1 here:
>>
>

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost