pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/55343: oksh fails to link on older Linux with "undefined reference to `clock_gettime'"



>Number:         55343
>Category:       pkg
>Synopsis:       oksh fails to link on older Linux with "undefined reference to `clock_gettime'"
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Jun 04 12:20:00 +0000 2020
>Originator:     Carsten Strotmann
>Release:        pkgsrc 2020Q1
>Organization:
>Environment:
Linux stella 2.6.35.4-ecafe-v4 #4 PREEMPT Sun Feb 2 15:23:37 UTC 2014 armv7l GNU/Linux
>Description:
package 'oksh' fails to link on an older Linux system (Debian 6).

The link step is missing to link against "librt"

===> Building for oksh-6.5nb1
cc -Wl,-R/usr/pkg/lib -o oksh alloc.o asprintf.o c_ksh.o c_sh.o c_test.o c_ulimit.o edit.o  emacs.o eval.o exec.o expr.o history.o io.o jobs.o lex.o mail.o  main.o misc.o path.o shf.o syn.o table.o trap.o tree.o tty.o var.o  version.o vi.o confstr.o reallocarray.o siglist.o signame.o  strlcat.o strlcpy.o strtonum.o unvis.o vis.o -lcurses
c_sh.o: In function `timex':
c_sh.c:(.text+0x18b8): undefined reference to `clock_gettime'
c_sh.c:(.text+0x1928): undefined reference to `clock_gettime'
c_sh.c:(.text+0x1acc): undefined reference to `clock_gettime'
mail.o: In function `mcheck':
mail.c:(.text+0x27c): undefined reference to `clock_gettime'
var.o: In function `setspec':
var.c:(.text+0x1130): undefined reference to `clock_gettime'
var.o:var.c:(.text+0x156c): more undefined references to `clock_gettime' follow
collect2: ld returned 1 exit status
*** Error code 1

Stop.
bmake: stopped in /usr/pkgsrc/shells/oksh/work/oksh-oksh-6.5
*** Error code 1

Stop.
bmake[1]: stopped in /usr/pkgsrc/shells/oksh
*** Error code 1

Stop.
bmake: stopped in /usr/pkgsrc/shells/oksh





>How-To-Repeat:
Try to install oksh from pkgsrc on an Debian 6 Linux system
>Fix:
This can be fixed by adding "-lrt" to the link step in the Makefile.

===> Building for oksh-6.5nb1
cc -Wl,-R/usr/pkg/lib -o oksh alloc.o asprintf.o c_ksh.o c_sh.o c_test.o c_ulimit.o edit.o  emacs.o eval.o exec.o expr.o history.o io.o jobs.o lex.o mail.o  main.o misc.o path.o shf.o syn.o table.o trap.o tree.o tty.o var.o  version.o vi.o confstr.o reallocarray.o siglist.o signame.o  strlcat.o strlcpy.o strtonum.o unvis.o vis.o -lcurses -lrt
===> Installing for oksh-6.5nb1
=> Generating pre-install file lists
install -d /usr/pkgsrc/shells/oksh/work/.destdir/usr/pkg/bin
install -d /usr/pkgsrc/shells/oksh/work/.destdir/usr/pkg/man/man1
install -c -s -m 755 oksh /usr/pkgsrc/shells/oksh/work/.destdir/usr/pkg/bin
install -c -m 644 oksh.1 /usr/pkgsrc/shells/oksh/work/.destdir/usr/pkg/man/man1/oksh.1
Please add /usr/pkg/bin/oksh to /etc/shells
=> Automatic manual page handling
=> Generating post-install file lists
=> Checking file-check results for oksh-6.5nb1
=> Creating binary package /usr/pkgsrc/shells/oksh/work/.packages/oksh-6.5nb1.tgz
===> Building binary package for oksh-6.5nb1
=> Creating binary package /usr/pkgsrc/packages/All/oksh-6.5nb1.tgz
===> Installing binary package of oksh-6.5nb1
oksh-6.5nb1: adding /usr/pkg/bin/oksh to /etc/shells

This issue has been reported upstream
https://github.com/ibara/oksh/issues/44


Home | Main Index | Thread Index | Old Index