burnedram / csgo-plugin-color-say

CSGO server plugin for displaying colored text
MIT License
3 stars 2 forks source link

Which version of protoc is required? #1

Closed basert closed 7 years ago

basert commented 7 years ago

Hey,

I tried running your make file but I keep getting errors when compile the proto files. Which version of protobuf-compiler do I need to use? I'm currently using protoc 3.1.0.

Error-log:

mkdir -p src/protobuf
protoc --proto_path=hl2sdk-csgo/public/engine/protobuf/ --proto_path=/usr/include --cpp_out=src/protobuf/ hl2sdk-csgo/public/engine/protobuf/netmessages.proto
[libprotobuf WARNING google/protobuf/compiler/parser.cc:547] No syntax specified for the proto file: netmessages.proto. Please use 'syntax = "proto2";' or 'syntax = "proto3";' to specify a syntax version. (Defaulted to proto2 syntax.)
netmessages.proto: warning: Import google/protobuf/descriptor.proto but not used.
protoc --proto_path=hl2sdk-csgo/public/game/shared/csgo/protobuf/ --proto_path=hl2sdk-csgo/public/engine/protobuf/ --proto_path=/usr/include --cpp_out=src/protobuf/ hl2sdk-csgo/public/game/shared/csgo/protobuf/cstrike15_usermessages.proto
[libprotobuf WARNING google/protobuf/compiler/parser.cc:547] No syntax specified for the proto file: cstrike15_usermessages.proto. Please use 'syntax = "proto2";' or 'syntax = "proto3";' to specify a syntax version. (Defaulted to proto2 syntax.)
[libprotobuf WARNING google/protobuf/compiler/parser.cc:547] No syntax specified for the proto file: netmessages.proto. Please use 'syntax = "proto2";' or 'syntax = "proto3";' to specify a syntax version. (Defaulted to proto2 syntax.)
cstrike15_usermessages.proto: warning: Import google/protobuf/descriptor.proto but not used.
g++-4.6 src/colorsay.cpp -Wall -Werror -m32 -pipe -msse -mfpmath=sse -std=c++0x -fvisibility=hidden -fvisibility-inlines-hidden -fexceptions -fno-threadsafe-statics -fno-rtti -Dstricmp=strcasecmp -D_stricmp=strcasecmp -D_snprintf=snprintf -D_vsnprintf=vsnprintf -DGNUC -D_LINUX -DPOSIX -DCOMPILER_GCC -Ihl2sdk-csgo/public -Ihl2sdk-csgo/public/engine -Ihl2sdk-csgo/public/mathlib -Ihl2sdk-csgo/public/tier0 -Ihl2sdk-csgo/public/tier1 -Ihl2sdk-csgo/public/game/server -Isrc -Isrc/protobuf -c -o build/colorsay.o
In file included from src/colorsay.cpp:7:0:
src/protobuf/cstrike15_usermessages.pb.h:12:2: error: #error This file was generated by a newer version of protoc which is
src/protobuf/cstrike15_usermessages.pb.h:13:2: error: #error incompatible with your Protocol Buffer headers. Please update
src/protobuf/cstrike15_usermessages.pb.h:14:2: error: #error your headers.
In file included from src/protobuf/cstrike15_usermessages.pb.h:32:0,
                 from src/colorsay.cpp:7:
src/protobuf/netmessages.pb.h:12:2: error: #error This file was generated by a newer version of protoc which is
src/protobuf/netmessages.pb.h:13:2: error: #error incompatible with your Protocol Buffer headers. Please update
src/protobuf/netmessages.pb.h:14:2: error: #error your headers.
In file included from /usr/include/google/protobuf/stubs/macros.h:34:0,
                 from /usr/include/google/protobuf/stubs/logging.h:34,
                 from /usr/include/google/protobuf/arena.h:55,
                 from src/protobuf/cstrike15_usermessages.pb.h:22,
                 from src/colorsay.cpp:7:
/usr/include/google/protobuf/stubs/port.h:141:20: error: redefinition of ‘const int32 google::protobuf::kint32max’
/usr/local/include/google/protobuf/stubs/common.h:197:20: error: ‘const int32 google::protobuf::kint32max’ previously defined here
/usr/include/google/protobuf/stubs/port.h:142:20: error: redefinition of ‘const int32 google::protobuf::kint32min’
/usr/local/include/google/protobuf/stubs/common.h:198:20: error: ‘const int32 google::protobuf::kint32min’ previously defined here
/usr/include/google/protobuf/stubs/port.h:143:20: error: redefinition of ‘const int64 google::protobuf::kint64max’
/usr/local/include/google/protobuf/stubs/common.h:199:20: error: ‘const int64 google::protobuf::kint64max’ previously defined here
/usr/include/google/protobuf/stubs/port.h:144:20: error: redefinition of ‘const int64 google::protobuf::kint64min’
/usr/local/include/google/protobuf/stubs/common.h:200:20: error: ‘const int64 google::protobuf::kint64min’ previously defined here
/usr/include/google/protobuf/stubs/port.h:145:21: error: redefinition of ‘const uint32 google::protobuf::kuint32max’
/usr/local/include/google/protobuf/stubs/common.h:201:21: error: ‘const uint32 google::protobuf::kuint32max’ previously defined here
/usr/include/google/protobuf/stubs/port.h:146:21: error: redefinition of ‘const uint64 google::protobuf::kuint64max’
/usr/local/include/google/protobuf/stubs/common.h:202:21: error: ‘const uint64 google::protobuf::kuint64max’ previously defined here
/usr/include/google/protobuf/stubs/port.h: In static member function ‘static google::protobuf::uint16 google::protobuf::BigEndian::FromHost16(google::protobuf::uint16)’:
/usr/include/google/protobuf/stubs/port.h:337:57: error: ‘bswap_16’ was not declared in this scope
/usr/include/google/protobuf/stubs/port.h: In static member function ‘static google::protobuf::uint16 google::protobuf::BigEndian::ToHost16(google::protobuf::uint16)’:
/usr/include/google/protobuf/stubs/port.h:338:55: error: ‘bswap_16’ was not declared in this scope
/usr/include/google/protobuf/stubs/port.h: In static member function ‘static google::protobuf::uint32 google::protobuf::BigEndian::FromHost32(google::protobuf::uint32)’:
/usr/include/google/protobuf/stubs/port.h:340:57: error: ‘bswap_32’ was not declared in this scope
/usr/include/google/protobuf/stubs/port.h: In static member function ‘static google::protobuf::uint32 google::protobuf::BigEndian::ToHost32(google::protobuf::uint32)’:
/usr/include/google/protobuf/stubs/port.h:341:55: error: ‘bswap_32’ was not declared in this scope
/usr/include/google/protobuf/stubs/port.h: In static member function ‘static google::protobuf::uint64 google::protobuf::BigEndian::FromHost64(google::protobuf::uint64)’:
/usr/include/google/protobuf/stubs/port.h:343:57: error: ‘bswap_64’ was not declared in this scope
/usr/include/google/protobuf/stubs/port.h: In static member function ‘static google::protobuf::uint64 google::protobuf::BigEndian::ToHost64(google::protobuf::uint64)’:
/usr/include/google/protobuf/stubs/port.h:344:55: error: ‘bswap_64’ was not declared in this scope
In file included from /usr/include/google/protobuf/stubs/logging.h:34:0,
                 from /usr/include/google/protobuf/arena.h:55,
                 from src/protobuf/cstrike15_usermessages.pb.h:22,
                 from src/colorsay.cpp:7:
/usr/include/google/protobuf/stubs/macros.h: At global scope:
/usr/include/google/protobuf/stubs/macros.h:110:8: error: redefinition of ‘struct google::protobuf::internal::CompileAssert<<anonymous> >’
/usr/local/include/google/protobuf/stubs/common.h:374:8: error: previous definition of ‘struct google::protobuf::internal::CompileAssert<<anonymous> >’
In file included from /usr/include/google/protobuf/arena.h:55:0,
                 from src/protobuf/cstrike15_usermessages.pb.h:22,
                 from src/colorsay.cpp:7:
/usr/include/google/protobuf/stubs/logging.h:43:6: error: multiple definition of ‘enum google::protobuf::LogLevel’
/usr/local/include/google/protobuf/stubs/common.h:622:6: error: previous definition here
/usr/include/google/protobuf/stubs/logging.h:73:26: error: redefinition of ‘class google::protobuf::internal::LogMessage’
/usr/local/include/google/protobuf/stubs/common.h:647:26: error: previous definition of ‘class google::protobuf::internal::LogMessage’
/usr/include/google/protobuf/stubs/logging.h:105:26: error: redefinition of ‘class google::protobuf::internal::LogFinisher’
/usr/local/include/google/protobuf/stubs/common.h:673:26: error: previous definition of ‘class google::protobuf::internal::LogFinisher’
/usr/include/google/protobuf/stubs/logging.h:163:4: error: redefinition of ‘template<class T> T* google::protobuf::internal::CheckNotNull(const char*, int, const char*, T*)’
/usr/local/include/google/protobuf/stubs/common.h:725:4: error: ‘template<class T> T* google::protobuf::internal::CheckNotNull(const char*, int, const char*, T*)’ previously declared here
/usr/include/google/protobuf/stubs/logging.h:228:26: error: redefinition of ‘class google::protobuf::LogSilencer’
/usr/local/include/google/protobuf/stubs/common.h:787:26: error: previous definition of ‘class google::protobuf::LogSilencer’
In file included from /usr/include/google/protobuf/arena.h:56:0,
                 from src/protobuf/cstrike15_usermessages.pb.h:22,
                 from src/colorsay.cpp:7:
/usr/include/google/protobuf/stubs/mutex.h:48:26: error: redefinition of ‘class google::protobuf::internal::Mutex’
/usr/local/include/google/protobuf/stubs/common.h:1099:26: error: previous definition of ‘class google::protobuf::internal::Mutex’
/usr/include/google/protobuf/stubs/mutex.h:82:26: error: redefinition of ‘class google::protobuf::internal::MutexLock’
/usr/local/include/google/protobuf/stubs/common.h:1125:26: error: previous definition of ‘class google::protobuf::internal::MutexLock’
/usr/include/google/protobuf/stubs/mutex.h:96:26: error: redefinition of ‘class google::protobuf::internal::MutexLockMaybe’
/usr/local/include/google/protobuf/stubs/common.h:1139:26: error: previous definition of ‘class google::protobuf::internal::MutexLockMaybe’
In file included from src/protobuf/cstrike15_usermessages.pb.h:22:0,
                 from src/colorsay.cpp:7:
/usr/include/google/protobuf/arena.h: In member function ‘T* google::protobuf::Arena::CreateInternalRawArray(size_t)’:
/usr/include/google/protobuf/arena.h:635:25: error: cannot use typeid with -fno-rtti
/usr/include/google/protobuf/arena.h: In member function ‘T* google::protobuf::Arena::CreateInternal(bool)’:
/usr/include/google/protobuf/arena.h:640:33: error: cannot use typeid with -fno-rtti
/usr/include/google/protobuf/arena.h: In member function ‘T* google::protobuf::Arena::CreateInternal(bool, const Arg&)’:
/usr/include/google/protobuf/arena.h:649:33: error: cannot use typeid with -fno-rtti
/usr/include/google/protobuf/arena.h: In member function ‘T* google::protobuf::Arena::CreateInternal(bool, const Arg1&, const Arg2&)’:
/usr/include/google/protobuf/arena.h:659:33: error: cannot use typeid with -fno-rtti
/usr/include/google/protobuf/arena.h: In member function ‘T* google::protobuf::Arena::CreateInternal(bool, const Arg1&, const Arg2&, const Arg3&)’:
/usr/include/google/protobuf/arena.h:671:33: error: cannot use typeid with -fno-rtti
/usr/include/google/protobuf/arena.h: In member function ‘T* google::protobuf::Arena::CreateInternal(bool, const Arg1&, const Arg2&, const Arg3&, const Arg4&)’:
/usr/include/google/protobuf/arena.h:686:33: error: cannot use typeid with -fno-rtti
/usr/include/google/protobuf/arena.h: In member function ‘T* google::protobuf::Arena::CreateInternal(bool, const Arg1&, const Arg2&, const Arg3&, const Arg4&, const Arg5&)’:
/usr/include/google/protobuf/arena.h:702:33: error: cannot use typeid with -fno-rtti
/usr/include/google/protobuf/arena.h: In member function ‘T* google::protobuf::Arena::CreateInternal(bool, const Arg1&, const Arg2&, const Arg3&, const Arg4&, const Arg5&, const Arg6&)’:
/usr/include/google/protobuf/arena.h:719:33: error: cannot use typeid with -fno-rtti
/usr/include/google/protobuf/arena.h: In member function ‘T* google::protobuf::Arena::CreateInternal(bool, const Arg1&, const Arg2&, const Arg3&, const Arg4&, const Arg5&, const Arg6&, const Arg7&)’:
/usr/include/google/protobuf/arena.h:737:33: error: cannot use typeid with -fno-rtti
/usr/include/google/protobuf/arena.h: In member function ‘T* google::protobuf::Arena::CreateInternal(bool, const Arg1&, const Arg2&, const Arg3&, const Arg4&, const Arg5&, const Arg6&, const Arg7&, const Arg8&)’:
/usr/include/google/protobuf/arena.h:757:33: error: cannot use typeid with -fno-rtti
In file included from src/protobuf/cstrike15_usermessages.pb.h:25:0,
                 from src/colorsay.cpp:7:
/usr/include/google/protobuf/metadata.h: In member function ‘const google::protobuf::UnknownFieldSet& google::protobuf::internal::InternalMetadataWithArena::unknown_fields() const’:
/usr/include/google/protobuf/metadata.h:76:15: error: ‘default_instance’ is not a member of ‘google::protobuf::UnknownFieldSet’
Makefile:43: recipe for target 'build/colorsay.o' failed
make: *** [build/colorsay.o] Error 1
burnedram commented 7 years ago

Hi basert, I've added more thorough compilation instructions to the readme, but I've decided to actually finish this project since your question was asked, so you should be able to just download the latest release and be good to go!

Sorry for the long wait, but I haven't been very active with this project until now. If you decide to test my plugin out, please tell me what you think of it!