Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#21626 closed defect (invalid)

Make error: undefined reference to 'helper_is_default_tor_running'

Reported by: jah Owned by: dgoulet
Priority: Medium Milestone:
Component: Core Tor/Torsocks Version:
Severity: Normal Keywords:
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

Build of torsocks @ HEAD (0b199d9e173a7c88adbf804a484c8320a802d74e) fails with:-

  CC       test_dns.o
  CCLD     test_dns
test_dns.o: In function `main':
/code/projects/torsocks/tests/test_dns.c:141: undefined reference to
 `helper_is_default_tor_running'
collect2: error: ld returned 1 exit status
make[2]: *** [test_dns] Error 1

Child Tickets

Attachments (1)

21626-make-output.txt (37.2 KB) - added by jah 3 years ago.

Download all attachments as: .zip

Change History (6)

comment:1 Changed 3 years ago by dgoulet

Status: newneeds_information

Very weird... are you building out of tree or really from the git? Platform? Also, make V=1 would help.

Thanks!

Changed 3 years ago by jah

Attachment: 21626-make-output.txt added

comment:2 Changed 3 years ago by jah

I'm building from the git after pulling and make clean && make distclean. Attached is make V=1.

comment:3 Changed 3 years ago by dgoulet

Can you make sure you ./autogen.sh and configure here?

Because you are suppose to see the helpers.o while compiling the test:

/bin/bash ../libtool  --tag=CC   --mode=link gcc -I../include -I../src -I../tests/utils/ -I. -g -O2 -Wall -fPIE -fwrapv --param ssp-buffer-size=1 -fstack-protector-all  -pie -z relro -z now -o test_dns test_dns.o helpers.o ../tests/utils/tap/libtap.la ../src/lib/libtorsocks.la -ldl 
libtool: link: gcc -I../include -I../src -I../tests/utils/ -I. -g -O2 -Wall -fPIE -fwrapv --param ssp-buffer-size=1 -fstack-protector-all -pie -z relro -z now -o .libs/test_dns test_dns.o helpers.o  ../tests/utils/tap/.libs/libtap.a ../src/lib/.libs/libtorsocks.so -ldl -Wl,-rpath -Wl,/usr/local/lib/torsocks

In tests/Makefile.am, everything is there and it works on our CI:

HELPER_SOURCES = helpers.c helpers.h
test_dns_SOURCES = test_dns.c $(HELPER_SOURCES)

comment:4 Changed 3 years ago by jah

Resolution: invalid
Status: needs_informationclosed

Ah, ./autogen.sh is what I missed. Builds fine now. Sorry for the noise.

comment:5 Changed 3 years ago by dgoulet

No worries. Glad you made it work!

Note: See TracTickets for help on using tickets.