Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doesn't compile on OpenBSD 7.2 amd64 #23

Open
Veraellyunjie opened this issue Feb 5, 2023 · 0 comments
Open

doesn't compile on OpenBSD 7.2 amd64 #23

Veraellyunjie opened this issue Feb 5, 2023 · 0 comments

Comments

@Veraellyunjie
Copy link

git clone https://github.com/noyesno/awka
cd awka
./configure
creating cache ./config.cache
checking for gcc... gcc
checking whether we are using GNU C... yes
checking how to run the C preprocessor... gcc -E
checking for log in -lm... yes
checking checking for inline... __inline__
checking for gawk... no
checking for mawk... mawk
checking for ash... no
checking for sh... sh
checking for byacc... no
checking for bison... no
checking for yacc... yacc
checking for ar... ar
checking for ranlib... ranlib
checking for cmp... cmp
checking compiler supports void*... yes
checking compiler groks prototypes... yes
checking for working const... yes
checking for stddef.h... yes
getting size_t from <stddef.h>
checking for fcntl.h... yes
checking for errno.h... yes
checking for time.h... yes
checking for stdarg.h... yes
checking for netdb.h... yes
checking for netinet/in.h... yes
checking for sys/socket.h... yes
checking for unistd.h... yes
checking for memcpy... yes
checking for strchr... yes
checking for strstr... yes
checking for strerror... yes
checking for vfprintf... yes
checking for fmod... yes
checking for matherr... no
checking for limits.h... yes
checking for gethostbyname... yes
checking for connect... yes
checking where to find the socket library calls... the standard library
checking whether time.h and sys/time.h may both be included... yes
checking whether struct tm is in sys/time.h or time.h... time.h
checking for tm_zone in struct tm... yes
checking for time... yes
checking for mktime... yes
checking for asctime... yes
checking for localtime... yes
checking for gmtime... yes
checking for .exe extension... no
/* config.h -- generated by configure */
#ifndef CONFIG_H
#define CONFIG_H

#define HAVE_SOCKETS 1
#define HAVE_SYS_SOCKET_H
#define HAVE_UNISTD_H
#define HAVE_NETDB_H
#define HAVE_NETINET_IN_H
#define HAVE_FCNTL_H

#define awka_MATHLIB "-lm"
#define INLINE __inline__
#define SIZE_T_STDDEF_H 1
#define NO_MATHERR 1
#define NO_FPRINTF_IN_STDIO 1
#define NO_SPRINTF_IN_STDIO 1
#define awka_SOCKET_LIBS ""
#define awka_CC "gcc"
#define awka_CFLAGS "-O"
#define awka_shell "sh"

#define HAVE_REAL_PIPES 1
/* #define NO_BIN_CHARS */
/* #define MEM_DEBUG */
#endif /* CONFIG_H */
updating cache ./config.cache
creating ./config.status
creating Makefile
creating lib/Makefile
creating awka/Makefile
creating test/Makefile
creating benchmark/Makefile
gmake
cd awka; gmake
gmake[1]: Entering directory '/tmp/awka/awka'
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o translate.o translate.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o awka.o awka.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o parse.o parse.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o scan.o scan.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o memory.o memory.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o hash.o hash.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o code.o code.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o bi_funct.o bi_funct.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o da.o da.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o error.o error.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o init.o init.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o bi_vars.o bi_vars.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o cast.o cast.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o print.o print.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o kw.o kw.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o jmp.o jmp.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o field.o field.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o re_cmpl.o re_cmpl.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o preprocess.o preprocess.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o zmalloc.o zmalloc.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o fcall.o fcall.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\"   -c -o version.o version.c
gcc -O -Dawka_LIBDIR=\"/usr/local/lib\" -Dawka_INCDIR=\"/usr/local/include\" translate.o awka.o parse.o scan.o memory.o hash.o code.o bi_funct.o da.o error.o init.o bi_vars.o cast.o print.o kw.o jmp.o field.o re_cmpl.o preprocess.o zmalloc.o msg.o scancode.o fcall.o version.o -o awka
ld: error: duplicate symbol: awak_input_text
>>> defined at scan.c
>>>            scan.o:(awak_input_text)
>>> defined at code.c
>>>            code.o:(.bss+0x80)

ld: error: duplicate symbol: awak_input_text
>>> defined at scan.c
>>>            scan.o:(awak_input_text)
>>> defined at bi_funct.c
>>>            bi_funct.o:(.bss+0x0)

ld: error: duplicate symbol: line_pos
>>> defined at scan.c
>>>            scan.o:(line_pos)
>>> defined at error.c
>>>            error.o:(.bss+0x8)

ld: error: duplicate symbol: awak_input_text
>>> defined at scan.c
>>>            scan.o:(awak_input_text)
>>> defined at init.c
>>>            init.o:(.bss+0x90)

ld: error: duplicate symbol: awak_input_text
>>> defined at scan.c
>>>            scan.o:(awak_input_text)
>>> defined at bi_vars.c
>>>            bi_vars.o:(.bss+0x1F8)

ld: error: duplicate symbol: line_pos
>>> defined at scan.c
>>>            scan.o:(line_pos)
>>> defined at cast.c
>>>            cast.o:(.bss+0x0)

ld: error: duplicate symbol: line_pos
>>> defined at scan.c
>>>            scan.o:(line_pos)
>>> defined at print.c
>>>            print.o:(.bss+0x0)

ld: error: duplicate symbol: awak_input_text
>>> defined at scan.c
>>>            scan.o:(awak_input_text)
>>> defined at kw.c
>>>            kw.o:(.bss+0x0)

ld: error: duplicate symbol: awak_input_text
>>> defined at scan.c
>>>            scan.o:(awak_input_text)
>>> defined at jmp.c
>>>            jmp.o:(.bss+0x8)

ld: error: duplicate symbol: line_pos
>>> defined at scan.c
>>>            scan.o:(line_pos)
>>> defined at field.c
>>>            field.o:(.bss+0x1898)

ld: error: duplicate symbol: awak_input_text
>>> defined at scan.c
>>>            scan.o:(awak_input_text)
>>> defined at field.c
>>>            field.o:(.bss+0x18A0)

ld: error: duplicate symbol: line_pos
>>> defined at scan.c
>>>            scan.o:(line_pos)
>>> defined at re_cmpl.c
>>>            re_cmpl.o:(.bss+0x0)
collect2: error: ld returned 1 exit status
gmake[1]: *** [Makefile:44: awka] Error 1
gmake[1]: Leaving directory '/tmp/awka/awka'
gmake: *** [Makefile:48: awka_exe] Error 2

Also please note that awka from https://awka.sourceforge.net/index.html does compile fine (and does generate c code from awk code, however the generated c code doesn't compile)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant