jmhodges / gocld3

Apache License 2.0
20 stars 18 forks source link

Can't build. Protobuff problem #7

Closed edwvee closed 4 years ago

edwvee commented 5 years ago
$go get github.com/jmhodges/gocld3/cld3
# github.com/jmhodges/gocld3/cld3
In file included from feature_extractor.h:45:0,
                 from embedding_feature_extractor.h:23,
                 from nnet_language_identifier.h:22,
                 from cld3.cc:3:
feature_extractor.pb.h:10:40: fatal error: google/protobuf/port_def.inc: No such file or directory
compilation terminated.
$ uname -a
Linux acc-MS-7A15 4.15.0-62-generic #69~16.04.1-Ubuntu SMP Fri Sep 6 02:43:35 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
$ go version
go version go1.10.4 linux/amd64

Any suggestions?

jmhodges commented 5 years ago

What version of protobuf do you have installed? Have you tried a recent one?

edwvee commented 5 years ago

I just don't know much about protobuf. Could this be an answer?


$ aptitude search protobuf
p   golang-gogoprotobuf-dev                                                                        - Alternative protocol buffer support for the Go programming language                                      
p   golang-gogoprotobuf-dev:i386                                                                   - Alternative protocol buffer support for the Go programming language                                      
i   golang-goprotobuf-dev                                                                          - Protocol buffer support for the Go programming language                                                  
p   golang-goprotobuf-dev:i386                                                                     - Protocol buffer support for the Go programming language                                                  
p   golang-protobuf-extensions-dev                                                                 - Protocol Buffer extensions for the Go language                                                           
p   libactivemq-protobuf-java                                                                      - ActiveMQ Protocol Buffers Maven plugin                                                                   
p   libactivemq-protobuf-java-doc                                                                  - ActiveMQ Protocol Buffers Maven plugin - documentation                                                   
i   libmirprotobuf3                                                                                - Display server for Ubuntu - RPC definitions                                                              
p   libmirprotobuf3:i386                                                                           - Display server for Ubuntu - RPC definitions                                                              
p   libprotobuf-c-dev                                                                              - Protocol Buffers C static library and headers (protobuf-c)                                               
p   libprotobuf-c-dev:i386                                                                         - Protocol Buffers C static library and headers (protobuf-c)                                               
v   libprotobuf-c0-dev                                                                             -                                                                                                          
v   libprotobuf-c0-dev:i386                                                                        -                                                                                                          
i   libprotobuf-c1                                                                                 - Protocol Buffers C shared library (protobuf-c)                                                           
p   libprotobuf-c1:i386                                                                            - Protocol Buffers C shared library (protobuf-c)                                                           
p   libprotobuf-c1-dbg                                                                             - Protocol Buffers C shared library debug symbols (protobuf-c)                                             
p   libprotobuf-c1-dbg:i386                                                                        - Protocol Buffers C shared library debug symbols (protobuf-c)                                             
i A libprotobuf-dev                                                                                - protocol buffers C++ library (development files)                                                         
p   libprotobuf-dev:i386                                                                           - protocol buffers C++ library (development files)                                                         
p   libprotobuf-java                                                                               - Java bindings for protocol buffers                                                                       
i   libprotobuf-lite9v5                                                                            - protocol buffers C++ library (lite version)                                                              
p   libprotobuf-lite9v5:i386                                                                       - protocol buffers C++ library (lite version)                                                              
i   libprotobuf9v5                                                                                 - protocol buffers C++ library                                                                             
p   libprotobuf9v5:i386                                                                            - protocol buffers C++ library                                                                             
p   protobuf-c-compiler                                                                            - Protocol Buffers C compiler (protobuf-c)                                                                 
p   protobuf-c-compiler:i386                                                                       - Protocol Buffers C compiler (protobuf-c)                                                                 
i   protobuf-compiler                                                                              - compiler for protocol buffer definition files                                                            
p   protobuf-compiler:i386                                                                         - compiler for protocol buffer definition files                                                            
p   python-protobuf                                                                                - Python bindings for protocol buffers                                                                     
p   python-protobuf:i386                                                                           - Python bindings for protocol buffers                                                                     
p   python-protobuf.socketrpc                                                                      - Python socket RPC for Google protocol buffers                                                            
v   python2.7-protobuf.socketrpc         
```                                                          -       
edwvee commented 5 years ago
$ protoc --version
libprotoc 2.6.1
jmhodges commented 5 years ago

Yep, cld3 (which this library wraps) requires a more modern 3.x release. The latest protobuf is 3.9.1 but any relatively modern Linux district will have some thing close.

I’ll leave this open for a couple days or until you update with how a protobuf upgrade has helped.