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

Compilation problem with put_log function #746

Open
amorirReverse opened this issue Oct 14, 2024 · 0 comments
Open

Compilation problem with put_log function #746

amorirReverse opened this issue Oct 14, 2024 · 0 comments

Comments

@amorirReverse
Copy link

Good morning,
I have a problem. when I try to use your project and compile it, it tells me that log_put is not defined but it is defined in the project with the LOG macro. here are screenshots.

`vagrant@bullseye:/vagrant/libs/libnfc$ make
make all-recursive
make[1]: Entering directory '/vagrant/libs/libnfc'
Making all in libnfc
make[2]: Entering directory '/vagrant/libs/libnfc/libnfc'
Making all in chips
make[3]: Entering directory '/vagrant/libs/libnfc/libnfc/chips'
CC libnfcchips_la-pn53x.lo
CCLD libnfcchips.la
make[3]: Leaving directory '/vagrant/libs/libnfc/libnfc/chips'
Making all in buses
make[3]: Entering directory '/vagrant/libs/libnfc/libnfc/buses'
CC libnfcbuses_la-empty.lo
CC libnfcbuses_la-spi.lo
CC libnfcbuses_la-uart.lo
CC libnfcbuses_la-usbbus.lo
CC libnfcbuses_la-i2c.lo
CCLD libnfcbuses.la
make[3]: Leaving directory '/vagrant/libs/libnfc/libnfc/buses'
Making all in drivers
make[3]: Entering directory '/vagrant/libs/libnfc/libnfc/drivers'
CC libnfcdrivers_la-acr122_usb.lo
acr122_usb.c: In function ‘acr122_usb_receive’:
acr122_usb.c:615:14: warning: variable ‘status’ set but not used [-Wunused-but-set-variable]
615 | int error, status;
| ^~~~~~
CC libnfcdrivers_la-acr122s.lo
CC libnfcdrivers_la-arygon.lo
CC libnfcdrivers_la-pn53x_usb.lo
CC libnfcdrivers_la-pn532_uart.lo
CC libnfcdrivers_la-pn532_spi.lo
CC libnfcdrivers_la-pn532_i2c.lo
CCLD libnfcdrivers.la
make[3]: Leaving directory '/vagrant/libs/libnfc/libnfc/drivers'
Making all in .
make[3]: Entering directory '/vagrant/libs/libnfc/libnfc'
CC libnfc_la-conf.lo
In file included from conf.c:28:
config.h:5: warning: "SYSCONFDIR" redefined
5 | #define SYSCONFDIR "/etc"
|
: note: this is the location of the previous definition
CC libnfc_la-iso14443-subr.lo
In file included from iso14443-subr.c:33:
config.h:5: warning: "SYSCONFDIR" redefined
5 | #define SYSCONFDIR "/etc"
|
: note: this is the location of the previous definition
CC libnfc_la-mirror-subr.lo
In file included from mirror-subr.c:33:
config.h:5: warning: "SYSCONFDIR" redefined
5 | #define SYSCONFDIR "/etc"
|
: note: this is the location of the previous definition
CC libnfc_la-nfc.lo
In file included from nfc.c:75:
config.h:5: warning: "SYSCONFDIR" redefined
5 | #define SYSCONFDIR "/etc"
|
: note: this is the location of the previous definition
nfc.c: In function ‘nfc_register_driver’:
nfc.c:210:105: warning: ISO C99 requires at least one argument for the "..." in a variadic macro
210 | , NFC_LOG_PRIORITY_DEBUG, "nfc_register_driver returning NFC_EINVARG");
| ^

nfc.c: In function ‘nfc_device_validate_modulation’:
nfc.c:1306:118: warning: ISO C99 requires at least one argument for the "..." in a variadic macro
1306 | RIORITY_DEBUG, "nfc_device_validate_modulation returning NFC_EINVARG");
| ^

nfc.c:1310:114: warning: ISO C99 requires at least one argument for the "..." in a variadic macro
1310 | RIORITY_DEBUG, "nfc_device_validate_modulation returning NFC_EINVARG");
| ^

CC libnfc_la-nfc-device.lo
In file included from nfc-device.c:36:
config.h:5: warning: "SYSCONFDIR" redefined
5 | #define SYSCONFDIR "/etc"
|
: note: this is the location of the previous definition
CC libnfc_la-nfc-emulation.lo
CC libnfc_la-nfc-internal.lo
In file included from log.h:31,
from nfc-internal.h:43,
from nfc-internal.c:34:
config.h:5: warning: "SYSCONFDIR" redefined
5 | #define SYSCONFDIR "/etc"
|
: note: this is the location of the previous definition
CC libnfc_la-target-subr.lo
CC libnfc_la-log.lo
In file included from log.h:31,
from log.c:27:
config.h:5: warning: "SYSCONFDIR" redefined
5 | #define SYSCONFDIR "/etc"
|
: note: this is the location of the previous definition
CC libnfc_la-log-internal.lo
In file included from log-internal.h:31,
from log-internal.c:28:
config.h:5: warning: "SYSCONFDIR" redefined
5 | #define SYSCONFDIR "/etc"
|
: note: this is the location of the previous definition
CCLD libnfc.la
make[3]: Leaving directory '/vagrant/libs/libnfc/libnfc'
make[2]: Leaving directory '/vagrant/libs/libnfc/libnfc'
Making all in utils
make[2]: Entering directory '/vagrant/libs/libnfc/utils'
CC nfc-barcode.o
CC nfc-utils.lo
CCLD libnfcutils.la
CCLD nfc-barcode
/usr/bin/ld: ../libnfc/.libs/libnfc.so: undefined reference to log_put' collect2: error: ld returned 1 exit status make[2]: *** [Makefile:546: nfc-barcode] Error 1 make[2]: Leaving directory '/vagrant/libs/libnfc/utils' make[1]: *** [Makefile:487: all-recursive] Error 1 make[1]: Leaving directory '/vagrant/libs/libnfc' make: *** [Makefile:394: all] Error 2 vagrant@bullseye:/vagrant/libs/libnfc$

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