You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi. Thank you for the work you are doing.
There seems to be an issue with the last few commits. This commit onwards, doing sudo make install throws an error, which isn't so in the previous commits.
Here is the output:
$ sudo make clean install
rm -f *.o vi
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L vi.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L ex.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L lbuf.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L sbuf.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L ren.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L led.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L uc.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L term.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L regex.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L conf.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L hund.c
cc -o vi vi.o ex.o lbuf.o sbuf.o ren.o led.o uc.o term.o regex.o conf.o hund.o -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L
/bin/ld: regex.o: in function `regexec':
regex.c:(.text+0x1b48): undefined reference to `brk_match'
/bin/ld: regex.c:(.text+0x21dd): undefined reference to `brk_match'
/bin/ld: regex.c:(.text+0x284d): undefined reference to `brk_match'
/bin/ld: regex.c:(.text+0x2ec6): undefined reference to `brk_match'
collect2: error: ld returned 1 exit status
make: *** [Makefile:11: vi] Error 1
And for the earlier commits that work:
$ git checkout fc92963
$ sudo make clean install
rm -f *.o vi
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L vi.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L ex.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L lbuf.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L sbuf.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L ren.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L led.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L uc.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L term.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L regex.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L conf.c
cc -c -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L hund.c
cc -o vi vi.o ex.o lbuf.o sbuf.o ren.o led.o uc.o term.o regex.o conf.o hund.o -pedantic -Wall -Wfatal-errors -std=c99 -D_POSIX_C_SOURCE=200809L
cp -f vi /bin
I wonder whats causing this problem (I dont know C).
Kindly look into this. Thanks.
The text was updated successfully, but these errors were encountered:
Hi @Inesgor what compiler are you using and version? I just pushed a commit that might fix the problem, thanks for the report. This is a very good catch because virtually with any modern compiler it would not give any warning about potential portability with the use of inline keyword.
Right. I just figured out how to reproduce this on my side. Basically because of default -O0 optimization compiler generates symbols but also inlines the functions, without stripping the symbols so the linker tries to find references to them, which don't exist. This does not happen on higher optimization levels. The patch above solves the said issue.
Hi. Thank you for the work you are doing.
There seems to be an issue with the last few commits.
This commit onwards, doing
sudo make install
throws an error, which isn't so in the previous commits.Here is the output:
And for the earlier commits that work:
I wonder whats causing this problem (I dont know C).
Kindly look into this. Thanks.
The text was updated successfully, but these errors were encountered: