Author Topic: Help compiling on Solaris  (Read 1807 times)

0 Members and 1 Guest are viewing this topic.


Offline karnal

  • Hero Member
  • *****
  • Posts: 1068
    • View Profile
I'll open a github issue tomorrow, unless we can come up with a solution here.

Offline karnal

  • Hero Member
  • *****
  • Posts: 1068
    • View Profile
Actually x86_64 on this one, check: www.smartos.org

Was going to go with FreeBSD but boost is at 1.55 there.

I'd really like to get this running on Solaris, I think the error comes from int8_t being the same as char on that system. It's probably an easy fix.

Offline testz

Solaris? It's will be interesting  :)
Solaris at SPARC will be interesting2

Offline karnal

  • Hero Member
  • *****
  • Posts: 1068
    • View Profile

Offline karnal

  • Hero Member
  • *****
  • Posts: 1068
    • View Profile
Got it so far after accounting for solaris not having byteswap.h (changes made below):
~/graphene/libraries/fc]$ git diff src/byteswap.hpp
diff --git a/src/byteswap.hpp b/src/byteswap.hpp
index 1a0e534..c51f549 100644
--- a/src/byteswap.hpp
+++ b/src/byteswap.hpp
@@ -6,6 +6,10 @@
 #elif defined(__APPLE__)
 # include <libkern/OSByteOrder.h>
 # define bswap_64(x) OSSwapInt64(x)
+#elif defined(__sun) || defined(sun)
+#include <sys/byteorder.h>
+#define bswap_32(x) BSWAP_32(x)
+#define bswap_64(x) BSWAP_64(x)
 #else
 # include <byteswap.h>
 #endif

However, can't get past here .. out of ideas:

[  6%] Performing build step for 'project_secp256k1'
[  7%] Performing install step for 'project_secp256k1'
[  7%] Completed 'project_secp256k1'
[  7%] Built target project_secp256k1
[  8%] Building CXX object libraries/fc/CMakeFiles/fc.dir/src/uint128.cpp.o
In file included from /home/bitshares/graphene/libraries/fc/include/fc/reflect/reflect.hpp:18:0,
                 from /home/bitshares/graphene/libraries/fc/include/fc/time.hpp:138,
                 from /home/bitshares/graphene/libraries/fc/include/fc/log/logger.hpp:3,
                 from /home/bitshares/graphene/libraries/fc/include/fc/exception/exception.hpp:6,
                 from /home/bitshares/graphene/libraries/fc/include/fc/uint128.hpp:6,
                 from /home/bitshares/graphene/libraries/fc/src/uint128.cpp:1:
/home/bitshares/graphene/libraries/fc/include/fc/reflect/typename.hpp:30:21: error: redefinition of 'struct fc::get_typename<char>'
   template<> struct get_typename<char>     { static const char* name()  { return "char";     } };
                     ^
/home/bitshares/graphene/libraries/fc/include/fc/reflect/typename.hpp:22:21: error: previous definition of 'struct fc::get_typename<char>'
   template<> struct get_typename<int8_t>   { static const char* name()  { return "int8_t";   } };
                     ^
libraries/fc/CMakeFiles/fc.dir/build.make:62: recipe for target 'libraries/fc/CMakeFiles/fc.dir/src/uint128.cpp.o' failed
make[2]: *** [libraries/fc/CMakeFiles/fc.dir/src/uint128.cpp.o] Error 1
CMakeFiles/Makefile2:399: recipe for target 'libraries/fc/CMakeFiles/fc.dir/all' failed
make[1]: *** [libraries/fc/CMakeFiles/fc.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2


... any ideas?
« Last Edit: January 17, 2016, 12:42:25 pm by karnal »