locale_utils.cc:78: error: ‘CODESET’ was not declared in this scope #502

Closed
andschwa opened this Issue Feb 26, 2014 · 19 comments

Comments

Projects
None yet
6 participants
@andschwa

When building, I get this error, seeming to do with locale_utils.

make  all-recursive
make[1]: Entering directory `/home/$USER/mosh'
Making all in src
make[2]: Entering directory `/home/$USER/mosh/src'
Making all in protobufs
make[3]: Entering directory `/home/$USER/mosh/src/protobufs'
  GEN    userinput.pb.cc
  GEN    hostinput.pb.cc
  GEN    transportinstruction.pb.cc
make  all-am
make[4]: Entering directory `/home/$USER/mosh/src/protobufs'
  CXX    userinput.pb.o
  CXX    hostinput.pb.o
  CXX    transportinstruction.pb.o
  AR     libmoshprotos.a
make[4]: Leaving directory `/home/$USER/mosh/src/protobufs'
make[3]: Leaving directory `/home/$USER/mosh/src/protobufs'
Making all in util
make[3]: Entering directory `/home/$USER/mosh/src/util'
  CXX    locale_utils.o
locale_utils.cc: In function ‘const char* locale_charset()’:
locale_utils.cc:78: error: ‘CODESET’ was not declared in this scope
locale_utils.cc:78: error: ‘nl_langinfo’ was not declared in this scope
make[3]: *** [locale_utils.o] Error 1
make[3]: Leaving directory `/home/$USER/mosh/src/util'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/$USER/mosh/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/$USER/mosh'
make: *** [all] Error 2

I don't have sudo access to this machine, so these can't be updated:

  • Linux $HOSTNAME 2.6.32-358.18.1.el6.x86_64
  • gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-3)
  • libprotoc 2.5.0
  • ncurses5-config --version: 5.7.20090207
  • locate zlib: /usr/share/doc/zlib-devel-1.2.3
  • OpenSSL 1.0.1e-fips 11 Feb 2013

This was on the master branch, give me a minute to try mosh-1.2.4.

@andschwa

This comment has been minimized.

Show comment Hide comment
@andschwa

andschwa Feb 26, 2014

The tag mosh-1.2.4 builds correctly. So it's a bug in master, I'll leave the issue, but close it.

The tag mosh-1.2.4 builds correctly. So it's a bug in master, I'll leave the issue, but close it.

@andschwa andschwa closed this Feb 26, 2014

@keithw

This comment has been minimized.

Show comment Hide comment
@keithw

keithw Feb 26, 2014

Owner

Interesting -- I'd love to prevent a regression before we release 1.2.5. Are you able to help chase this down? The locale_utils.cc file essentially hasn't been touched since Mosh 1.2. What is the HAVE_LANGINFO_H line in config.h?

Owner

keithw commented Feb 26, 2014

Interesting -- I'd love to prevent a regression before we release 1.2.5. Are you able to help chase this down? The locale_utils.cc file essentially hasn't been touched since Mosh 1.2. What is the HAVE_LANGINFO_H line in config.h?

@keithw keithw reopened this Feb 26, 2014

@andschwa

This comment has been minimized.

Show comment Hide comment
@andschwa

andschwa Feb 26, 2014

grep HAVE_LANGINFO_H config.h returns nothing, same for config.h.in

grep LANG config.h

/* #undef HAVE_M4_NORMALIZE___FCNTL_H__LANGINFO_H__LIMITS_H__LOCALE_H__NETDB_H__NETINET_IN_H__STDDEF_H__STDINT_H__INTTYPES_H__STDLIB_H__STRING_H__SYS_IOCTL_H__SYS_RESOURCE_H__SYS_SOCKET_H__SYS_STAT_H__SYS_TIME_H__TERMIOS_H__UNISTD_H__WCHAR_H__WCTYPE_H___ */
/* #undef HAVE_M4_NORMALIZE___GETTIMEOFDAY__SETRLIMIT__ISWPRINT__MEMCHR__MEMSET__NL_LANGINFO__POSIX_MEMALIGN__SETENV__SETLOCALE__SIGACTION__SOCKET__STRCHR__STRDUP__STRNCASECMP__STRTOK__STRERROR__STRTOL__WCWIDTH__CFMAKERAW__PSELECT__GETADDRINFO__GETNAMEINFO___ */

grep LANG config.h.in

#undef HAVE_M4_NORMALIZE___FCNTL_H__LANGINFO_H__LIMITS_H__LOCALE_H__NETDB_H__NETINET_IN_H__STDDEF_H__STDINT_H__INTTYPES_H__STDLIB_H__STRING_H__SYS_IOCTL_H__SYS_RESOURCE_H__SYS_SOCKET_H__SYS_STAT_H__SYS_TIME_H__TERMIOS_H__UNISTD_H__WCHAR_H__WCTYPE_H___
#undef HAVE_M4_NORMALIZE___GETTIMEOFDAY__SETRLIMIT__ISWPRINT__MEMCHR__MEMSET__NL_LANGINFO__POSIX_MEMALIGN__SETENV__SETLOCALE__SIGACTION__SOCKET__STRCHR__STRDUP__STRNCASECMP__STRTOK__STRERROR__STRTOL__WCWIDTH__CFMAKERAW__PSELECT__GETADDRINFO__GETNAMEINFO___

Commands run were:

  • ./autogen.sh
  • ./configure --prefix=$HOME/usr
  • make

Necessary environment variables:

  • LD_LIBRARY_PATH=$HOME/usr/lib/
  • PKG_CONFIG_PATH=$HOME/usr/lib/pkgconfig

FYI: the server I'm compiling on is funky: it strips execute rights from files created by a git clone command. I ran git status and added back the proper rights (although they're stripped initially, the use of chmod +x is unrestricted) until git status returned no diff from master.

grep HAVE_LANGINFO_H config.h returns nothing, same for config.h.in

grep LANG config.h

/* #undef HAVE_M4_NORMALIZE___FCNTL_H__LANGINFO_H__LIMITS_H__LOCALE_H__NETDB_H__NETINET_IN_H__STDDEF_H__STDINT_H__INTTYPES_H__STDLIB_H__STRING_H__SYS_IOCTL_H__SYS_RESOURCE_H__SYS_SOCKET_H__SYS_STAT_H__SYS_TIME_H__TERMIOS_H__UNISTD_H__WCHAR_H__WCTYPE_H___ */
/* #undef HAVE_M4_NORMALIZE___GETTIMEOFDAY__SETRLIMIT__ISWPRINT__MEMCHR__MEMSET__NL_LANGINFO__POSIX_MEMALIGN__SETENV__SETLOCALE__SIGACTION__SOCKET__STRCHR__STRDUP__STRNCASECMP__STRTOK__STRERROR__STRTOL__WCWIDTH__CFMAKERAW__PSELECT__GETADDRINFO__GETNAMEINFO___ */

grep LANG config.h.in

#undef HAVE_M4_NORMALIZE___FCNTL_H__LANGINFO_H__LIMITS_H__LOCALE_H__NETDB_H__NETINET_IN_H__STDDEF_H__STDINT_H__INTTYPES_H__STDLIB_H__STRING_H__SYS_IOCTL_H__SYS_RESOURCE_H__SYS_SOCKET_H__SYS_STAT_H__SYS_TIME_H__TERMIOS_H__UNISTD_H__WCHAR_H__WCTYPE_H___
#undef HAVE_M4_NORMALIZE___GETTIMEOFDAY__SETRLIMIT__ISWPRINT__MEMCHR__MEMSET__NL_LANGINFO__POSIX_MEMALIGN__SETENV__SETLOCALE__SIGACTION__SOCKET__STRCHR__STRDUP__STRNCASECMP__STRTOK__STRERROR__STRTOL__WCWIDTH__CFMAKERAW__PSELECT__GETADDRINFO__GETNAMEINFO___

Commands run were:

  • ./autogen.sh
  • ./configure --prefix=$HOME/usr
  • make

Necessary environment variables:

  • LD_LIBRARY_PATH=$HOME/usr/lib/
  • PKG_CONFIG_PATH=$HOME/usr/lib/pkgconfig

FYI: the server I'm compiling on is funky: it strips execute rights from files created by a git clone command. I ran git status and added back the proper rights (although they're stripped initially, the use of chmod +x is unrestricted) until git status returned no diff from master.

@andschwa

This comment has been minimized.

Show comment Hide comment
@andschwa

andschwa Feb 26, 2014

Heh... let me fix my environment variables real quick :)

Heh... let me fix my environment variables real quick :)

@andschwa

This comment has been minimized.

Show comment Hide comment
@andschwa

andschwa Feb 26, 2014

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/usr/lib/:/usr/include
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$HOME/usr/lib/pkgconfig

So now it includes /usr/include for sure.

configure:  === Configuration results ===
configure: Version:             1.2.4a
configure: c++ compiler:        g++
configure: Warning CXXFLAGS:    -Wall -Werror
configure: Picky CXXFLAGS:      -Wextra -pedantic -Wno-long-long -Weffc++
configure: Harden CFLAGS:        -fno-strict-overflow -D_FORTIFY_SOURCE=2 -fstack-protector-all -Wstack-protector --param ssp-buffer-size=1 -fPIE
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/usr/lib/:/usr/include
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$HOME/usr/lib/pkgconfig

So now it includes /usr/include for sure.

configure:  === Configuration results ===
configure: Version:             1.2.4a
configure: c++ compiler:        g++
configure: Warning CXXFLAGS:    -Wall -Werror
configure: Picky CXXFLAGS:      -Wextra -pedantic -Wno-long-long -Weffc++
configure: Harden CFLAGS:        -fno-strict-overflow -D_FORTIFY_SOURCE=2 -fstack-protector-all -Wstack-protector --param ssp-buffer-size=1 -fPIE
@andschwa

This comment has been minimized.

Show comment Hide comment
@andschwa

andschwa Feb 26, 2014

The file /usr/include/langinfo.h certainly exists, and what's more has CODESET defined. I ran ./configure again, and then make clean and make, still the same error. For some reason CODESET isn't being replaced by the pre-processor with the value defined in langinfo.h.

grep CODESET /usr/include/langinfo.h

  _NL_TIME_CODESET,
  _NL_COLLATE_CODESET,
  _NL_CTYPE_CODESET_NAME,
  CODESET = _NL_CTYPE_CODESET_NAME,
#define CODESET         CODESET
  _NL_MONETARY_CODESET,
  _NL_NUMERIC_CODESET,
  _NL_MESSAGES_CODESET,
  _NL_PAPER_CODESET,
  _NL_NAME_CODESET,
  _NL_ADDRESS_CODESET,
  _NL_TELEPHONE_CODESET,
  _NL_MEASUREMENT_CODESET,
  _NL_IDENTIFICATION_CODESET,

The file /usr/include/langinfo.h certainly exists, and what's more has CODESET defined. I ran ./configure again, and then make clean and make, still the same error. For some reason CODESET isn't being replaced by the pre-processor with the value defined in langinfo.h.

grep CODESET /usr/include/langinfo.h

  _NL_TIME_CODESET,
  _NL_COLLATE_CODESET,
  _NL_CTYPE_CODESET_NAME,
  CODESET = _NL_CTYPE_CODESET_NAME,
#define CODESET         CODESET
  _NL_MONETARY_CODESET,
  _NL_NUMERIC_CODESET,
  _NL_MESSAGES_CODESET,
  _NL_PAPER_CODESET,
  _NL_NAME_CODESET,
  _NL_ADDRESS_CODESET,
  _NL_TELEPHONE_CODESET,
  _NL_MEASUREMENT_CODESET,
  _NL_IDENTIFICATION_CODESET,
@andschwa

This comment has been minimized.

Show comment Hide comment
@andschwa

andschwa Feb 26, 2014

Removing the conditional around the #include <langinfo.h> and running make clean and make again gives me:

make  all-recursive
make[1]: Entering directory `/home/$USER/src/mosh-test'
Making all in src
make[2]: Entering directory `/home/$USER/src/mosh-test/src'
Making all in protobufs
make[3]: Entering directory `/home/$USER/src/mosh-test/src/protobufs'
  GEN    userinput.pb.cc
  GEN    hostinput.pb.cc
  GEN    transportinstruction.pb.cc
make  all-am
make[4]: Entering directory `/home/$USER/src/mosh-test/src/protobufs'
  CXX    userinput.pb.o
  CXX    hostinput.pb.o
  CXX    transportinstruction.pb.o
  AR     libmoshprotos.a
make[4]: Leaving directory `/home/$USER/src/mosh-test/src/protobufs'
make[3]: Leaving directory `/home/$USER/src/mosh-test/src/protobufs'
Making all in util
make[3]: Entering directory `/home/$USER/src/mosh-test/src/util'
  CXX    locale_utils.o
  CXX    swrite.o
  CXX    select.o
  CXX    timestamp.o
  CXX    pty_compat.o
pty_compat.cc:42:25: error: sys/stropts.h: No such file or directory
make[3]: *** [pty_compat.o] Error 1
make[3]: Leaving directory `/home/$USER/src/mosh-test/src/util'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/$USER/src/mosh-test/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/$USER/src/mosh-test'
make: *** [all] Error 2

Which is certainly a different error as locale_utils.o was compiled. So the HAVE_LANGINFO_H not being defined is one thing for sure. Now on to debug this.

Removing the conditional around the #include <langinfo.h> and running make clean and make again gives me:

make  all-recursive
make[1]: Entering directory `/home/$USER/src/mosh-test'
Making all in src
make[2]: Entering directory `/home/$USER/src/mosh-test/src'
Making all in protobufs
make[3]: Entering directory `/home/$USER/src/mosh-test/src/protobufs'
  GEN    userinput.pb.cc
  GEN    hostinput.pb.cc
  GEN    transportinstruction.pb.cc
make  all-am
make[4]: Entering directory `/home/$USER/src/mosh-test/src/protobufs'
  CXX    userinput.pb.o
  CXX    hostinput.pb.o
  CXX    transportinstruction.pb.o
  AR     libmoshprotos.a
make[4]: Leaving directory `/home/$USER/src/mosh-test/src/protobufs'
make[3]: Leaving directory `/home/$USER/src/mosh-test/src/protobufs'
Making all in util
make[3]: Entering directory `/home/$USER/src/mosh-test/src/util'
  CXX    locale_utils.o
  CXX    swrite.o
  CXX    select.o
  CXX    timestamp.o
  CXX    pty_compat.o
pty_compat.cc:42:25: error: sys/stropts.h: No such file or directory
make[3]: *** [pty_compat.o] Error 1
make[3]: Leaving directory `/home/$USER/src/mosh-test/src/util'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/$USER/src/mosh-test/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/$USER/src/mosh-test'
make: *** [all] Error 2

Which is certainly a different error as locale_utils.o was compiled. So the HAVE_LANGINFO_H not being defined is one thing for sure. Now on to debug this.

@andersk

This comment has been minimized.

Show comment Hide comment
@andersk

andersk Feb 26, 2014

Member
/* #undef HAVE_M4_NORMALIZE___FCNTL_H__LANGINFO_H__LIMITS_H__LOCALE_H__NETDB_H__NETINET_IN_H__STDDEF_H__STDINT_H__INTTYPES_H__STDLIB_H__STRING_H__SYS_IOCTL_H__SYS_RESOURCE_H__SYS_SOCKET_H__SYS_STAT_H__SYS_TIME_H__TERMIOS_H__UNISTD_H__WCHAR_H__WCTYPE_H___ */
/* #undef HAVE_M4_NORMALIZE___GETTIMEOFDAY__SETRLIMIT__ISWPRINT__MEMCHR__MEMSET__NL_LANGINFO__POSIX_MEMALIGN__SETENV__SETLOCALE__SIGACTION__SOCKET__STRCHR__STRDUP__STRNCASECMP__STRTOK__STRERROR__STRTOL__WCWIDTH__CFMAKERAW__PSELECT__GETADDRINFO__GETNAMEINFO___ */

That is definitely broken. Can you paste the first few lines of config.log, which contain the Autoconf version?

Member

andersk commented Feb 26, 2014

/* #undef HAVE_M4_NORMALIZE___FCNTL_H__LANGINFO_H__LIMITS_H__LOCALE_H__NETDB_H__NETINET_IN_H__STDDEF_H__STDINT_H__INTTYPES_H__STDLIB_H__STRING_H__SYS_IOCTL_H__SYS_RESOURCE_H__SYS_SOCKET_H__SYS_STAT_H__SYS_TIME_H__TERMIOS_H__UNISTD_H__WCHAR_H__WCTYPE_H___ */
/* #undef HAVE_M4_NORMALIZE___GETTIMEOFDAY__SETRLIMIT__ISWPRINT__MEMCHR__MEMSET__NL_LANGINFO__POSIX_MEMALIGN__SETENV__SETLOCALE__SIGACTION__SOCKET__STRCHR__STRDUP__STRNCASECMP__STRTOK__STRERROR__STRTOL__WCWIDTH__CFMAKERAW__PSELECT__GETADDRINFO__GETNAMEINFO___ */

That is definitely broken. Can you paste the first few lines of config.log, which contain the Autoconf version?

@andschwa

This comment has been minimized.

Show comment Hide comment
@andschwa

andschwa Feb 26, 2014

  • autoconf (GNU Autoconf) 2.63
It was created by mosh configure 1.2.4a, which was
generated by GNU Autoconf 2.63.  Invocation command line was

  $ ./configure --enable-compile-warnings=error --prefix=$HOME/usr/

## --------- ##
## Platform. ##
## --------- ##

hostname = $HOSTNAME
uname -m = x86_64
uname -r = 2.6.32-358.18.1.el6.x86_64
uname -s = Linux
uname -v = #1 SMP Fri Aug 2 17:04:38 EDT 2013

/usr/bin/uname -p = unknown
/bin/uname -X     = unknown

/bin/arch              = x86_64
/usr/bin/arch -k       = unknown
/usr/convex/getsysinfo = unknown
/usr/bin/hostinfo      = unknown
/bin/machine           = unknown
/usr/bin/oslevel       = unknown
/bin/universe          = unknown

PATH: /usr/lib64/qt-3.3/bin
PATH: /usr/local/bin
PATH: /bin
PATH: /usr/bin
PATH: /usr/local/sbin
PATH: /usr/sbin
PATH: /sbin
PATH: /usr/local/unicon/bin
PATH: /home/$USER/bin

Sorry, $HOME, $USER and $HOSTNAME are my own censors, as I don't own the server.

  • autoconf (GNU Autoconf) 2.63
It was created by mosh configure 1.2.4a, which was
generated by GNU Autoconf 2.63.  Invocation command line was

  $ ./configure --enable-compile-warnings=error --prefix=$HOME/usr/

## --------- ##
## Platform. ##
## --------- ##

hostname = $HOSTNAME
uname -m = x86_64
uname -r = 2.6.32-358.18.1.el6.x86_64
uname -s = Linux
uname -v = #1 SMP Fri Aug 2 17:04:38 EDT 2013

/usr/bin/uname -p = unknown
/bin/uname -X     = unknown

/bin/arch              = x86_64
/usr/bin/arch -k       = unknown
/usr/convex/getsysinfo = unknown
/usr/bin/hostinfo      = unknown
/bin/machine           = unknown
/usr/bin/oslevel       = unknown
/bin/universe          = unknown

PATH: /usr/lib64/qt-3.3/bin
PATH: /usr/local/bin
PATH: /bin
PATH: /usr/bin
PATH: /usr/local/sbin
PATH: /usr/sbin
PATH: /sbin
PATH: /usr/local/unicon/bin
PATH: /home/$USER/bin

Sorry, $HOME, $USER and $HOSTNAME are my own censors, as I don't own the server.

@andschwa

This comment has been minimized.

Show comment Hide comment
@andschwa

andschwa Feb 26, 2014

BTW it is not imperative (to me) to get the master branch built on this server. I got the tag to build, and after fiddling, discovered I'm firewalled completely from listening on any ports. It's a student dev server, and I was just hoping to use mosh instead of ssh because, what's more, the admins don't allow password-less ssh key authentication. I have my own VPS and a of course local VMs. College servers aren't the best, it's shared by like... a couple hundred students.

And I mean you saw how how old GCC was.

BTW it is not imperative (to me) to get the master branch built on this server. I got the tag to build, and after fiddling, discovered I'm firewalled completely from listening on any ports. It's a student dev server, and I was just hoping to use mosh instead of ssh because, what's more, the admins don't allow password-less ssh key authentication. I have my own VPS and a of course local VMs. College servers aren't the best, it's shared by like... a couple hundred students.

And I mean you saw how how old GCC was.

@andersk

This comment has been minimized.

Show comment Hide comment
@andersk

andersk Feb 26, 2014

Member

It would appear that Autoconf 2.64 and earlier choke on our AC_CHECK_HEADERS([m4_normalize([…])]) construction. This seems to be fixed by v2.65~21. For now a workaround would be to install Autoconf 2.65 or newer. (You should be able to install it in your home directory without root access.)

Member

andersk commented Feb 26, 2014

It would appear that Autoconf 2.64 and earlier choke on our AC_CHECK_HEADERS([m4_normalize([…])]) construction. This seems to be fixed by v2.65~21. For now a workaround would be to install Autoconf 2.65 or newer. (You should be able to install it in your home directory without root access.)

@andschwa

This comment has been minimized.

Show comment Hide comment
@andschwa

andschwa Feb 26, 2014

How on earth did you figure that so fast? I'll give it a shot just so we can know for sure.

How on earth did you figure that so fast? I'll give it a shot just so we can know for sure.

@andschwa

This comment has been minimized.

Show comment Hide comment
@andschwa

andschwa Feb 26, 2014

I would test with the latest Autoconf, except make check returns 288 failed tests, which I'd rather not wrestle with.

Thanks for your help @andersk

I would test with the latest Autoconf, except make check returns 288 failed tests, which I'd rather not wrestle with.

Thanks for your help @andersk

@andersk

This comment has been minimized.

Show comment Hide comment
@andersk

andersk Feb 26, 2014

Member

Alright. Does #503 fix your problem?

Member

andersk commented Feb 26, 2014

Alright. Does #503 fix your problem?

@andschwa

This comment has been minimized.

Show comment Hide comment
@andschwa

andschwa Feb 26, 2014

Give me just a minute, just added your repo as a remote.

Give me just a minute, just added your repo as a remote.

@andschwa

This comment has been minimized.

Show comment Hide comment
@andschwa

andschwa Feb 26, 2014

Update: it indeed does! At least, it fixes the problem this issue related to. (I have some issues now with protobuf, going to investigate).

Update: it indeed does! At least, it fixes the problem this issue related to. (I have some issues now with protobuf, going to investigate).

@jean

This comment has been minimized.

Show comment Hide comment
@jean

jean Sep 26, 2014

Just a datapoint, I get this error when compiling from git, but not when starting from tarball.

First, compile protobuf:

$ git clone https://github.com/google/protobuf.git
$ cd protobuf/
$ ./autogen.sh
$ ./configure --prefix=/home/myproj
$ make check
$ make install

Now try with github checkout (at 50152bf)

$ export PKG_CONFIG_PATH=/home/myproj/lib/pkgconfig/
$ ./configure --prefix=/home/myproj
[...]
make[3]: Entering directory `/home/myproj/downloads/mosh/src/util'
  CXX    locale_utils.o
locale_utils.cc: In function ‘const char* locale_charset()’:
locale_utils.cc:78: error: ‘CODESET’ was not declared in this scope
locale_utils.cc:78: error: ‘nl_langinfo’ was not declared in this scope
make[3]: *** [locale_utils.o] Error 1
make[3]: Leaving directory `/home/myproj/downloads/mosh/src/util'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/myproj/downloads/mosh/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/myproj/downloads/mosh'
make: *** [all] Error 2

OK restart with tarball:

$ wget http://mosh.mit.edu/mosh-1.2.4.tar.gz
[...]
$ tar xzf mosh-1.2.4.tar.gz
$ cd mosh-1.2.4
$ ./configure --prefix=/home/myproj && make && make install
$ mosh --version
mosh 1.2.4

jean commented Sep 26, 2014

Just a datapoint, I get this error when compiling from git, but not when starting from tarball.

First, compile protobuf:

$ git clone https://github.com/google/protobuf.git
$ cd protobuf/
$ ./autogen.sh
$ ./configure --prefix=/home/myproj
$ make check
$ make install

Now try with github checkout (at 50152bf)

$ export PKG_CONFIG_PATH=/home/myproj/lib/pkgconfig/
$ ./configure --prefix=/home/myproj
[...]
make[3]: Entering directory `/home/myproj/downloads/mosh/src/util'
  CXX    locale_utils.o
locale_utils.cc: In function ‘const char* locale_charset()’:
locale_utils.cc:78: error: ‘CODESET’ was not declared in this scope
locale_utils.cc:78: error: ‘nl_langinfo’ was not declared in this scope
make[3]: *** [locale_utils.o] Error 1
make[3]: Leaving directory `/home/myproj/downloads/mosh/src/util'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/myproj/downloads/mosh/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/myproj/downloads/mosh'
make: *** [all] Error 2

OK restart with tarball:

$ wget http://mosh.mit.edu/mosh-1.2.4.tar.gz
[...]
$ tar xzf mosh-1.2.4.tar.gz
$ cd mosh-1.2.4
$ ./configure --prefix=/home/myproj && make && make install
$ mosh --version
mosh 1.2.4
@mamiu

This comment has been minimized.

Show comment Hide comment
@mamiu

mamiu Mar 22, 2015

To all who scroll to the bottom to get the solution:
Here it is #503

mamiu commented Mar 22, 2015

To all who scroll to the bottom to get the solution:
Here it is #503

@cgull

This comment has been minimized.

Show comment Hide comment
@cgull

cgull Dec 11, 2015

Member

Pulled #503 months ago, it's in mosh-1.2.5.

Member

cgull commented Dec 11, 2015

Pulled #503 months ago, it's in mosh-1.2.5.

@cgull cgull closed this Dec 11, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment