Problems locating -lintl in 4.2.1 on HP-UX/IA

Albert Chin samba-technical at mlists.thewrittenword.com
Wed May 20 12:55:20 MDT 2015


I am trying to build 4.2.1 on HP-UX 11.23/IA. I replaced
buildtools/wafsamba/hpuxcc.py to use the HP C compiler. When running
python buildtools/bin/waf configure, it cannot find the 'intl' gettext
library. The reason for this is that even though I pass:
  CC=cc CFLAGS="+O2" CPPFLAGS="-I/opt/TWWfsw/gettext018/include \
  -I/opt/TWWfsw/libz12/include" \
  LDFLAGS="-L/opt/TWWfsw/gettext018/lib \
  -Wl,+s,+b,/opt/TWWfsw/gettext018/include:\
  /opt/TWWfsw/libiconv113/lib:\
  /opt/TWWfsw/python27/lib/python2.7/config" \
  PKG_CONFIG_PATH="/opt/TWWfsw/libz12/lib/pkgconfig" \
  /opt/TWWfsw/python27/bin/python buildtools/bin/waf configure \
  --with-gettext=/opt/TWWfsw/gettext018 \
  --with-libiconv=/opt/TWWfsw/libiconv113
the command-line to locate the gettext -lintl library is incorrect.
>From bin/config.log:
  Checking for library intl
  ==>

  int main() {
          return 0;
  }

  <==
  [1/2] Compiling test.c
  ['cc', '+O2', '-I/opt/TWWfsw/libiconv113/include', '-I/opt/TWWfsw/gettext018/include', '-I/opt/TWWfsw/libz12/include', '-D_SAMBA_BUILD_=4', '-DHAVE_CONFIG_H=1', '-D_GNU_SOURCE=1', '-D_XOPEN_SOURCE_EXTENDED=1', '../test.c', '-c', '-o', 'default/test_1.o']
  [2/2] Linking default/testprog
  ld: Can't find library for -lintl
  Fatal error.
  ['cc', 'default/test_1.o', '-o', '/opt/build/china/samba-4.2.1/bin/.conf_check_0/testbuild/default/testprog', '-L/opt/TWWfsw/libiconv113/lib', '-lintl', '-L/opt/TWWfsw/gettext018/lib', '-Wl,+s,+b,/opt/TWWfsw/gettext018/include:/opt/TWWfsw/libiconv113/lib:/opt/TWWfsw/python27/lib/python2.7/config']
  command returned 'Build failed:  -> task failed (err #1): \n\t{task: cc_link test_1.o -> testprog}'not found

Note '-lintl' appears *after* -L/opt/TWWfsw/gettext018/lib. How do I
make '-lintl' appear after user-supplied LDFLAGS from the
command-line?

-- 
albert chin (china at thewrittenword.com)


More information about the samba-technical mailing list