-
Notifications
You must be signed in to change notification settings - Fork 51
Description
Error messages are as follows,
creating Makefile
compiling export.cpp
In file included from /opt/services/nlp/local/include/simstring/memory_mapped_file.h:62:0,
from /opt/services/nlp/local/include/simstring/simstring.h:52,
from export.cpp:8:
/opt/services/nlp/local/include/simstring/memory_mapped_file_posix.h: In member function ‘void memory_mapped_file_posix::open(const string&, std::ios_base::openmode)’:
/opt/services/nlp/local/include/simstring/memory_mapped_file_posix.h:91:17: error: ‘::close’ has not been declared
::close(m_fd);
^
/opt/services/nlp/local/include/simstring/memory_mapped_file_posix.h: In member function ‘void memory_mapped_file_posix::close()’:
/opt/services/nlp/local/include/simstring/memory_mapped_file_posix.h:106:13: error: ‘::close’ has not been declared
::close(m_fd);
^
/opt/services/nlp/local/include/simstring/memory_mapped_file_posix.h: In member function ‘bool memory_mapped_file_posix::resize(memory_mapped_file_posix::size_type)’:
/opt/services/nlp/local/include/simstring/memory_mapped_file_posix.h:126:17: error: ‘::lseek’ has not been declared
if (::lseek(m_size, size, SEEK_SET) >= 0) {
^
/opt/services/nlp/local/include/simstring/memory_mapped_file_posix.h:128:48: error: ‘read’ was not declared in this scope
if (read(m_fd, &c, sizeof(char)) == -1) {
^
/opt/services/nlp/local/include/simstring/memory_mapped_file_posix.h:131:49: error: ‘write’ was not declared in this scope
if (write(m_fd, &c, sizeof(char)) == -1) {
^
make: *** [export.o] Error 1
I changed export.cpp:8 line from
#include < simstring/simstring.h >
to
#include <../../include/simstring/simstring.h>.
And it works fine.