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

indefined reference to _caca_alloc2d #73

Open
Viro-Neo opened this issue Jan 30, 2023 · 3 comments
Open

indefined reference to _caca_alloc2d #73

Viro-Neo opened this issue Jan 30, 2023 · 3 comments

Comments

@Viro-Neo
Copy link

I'm using the tar version, so I launched configure and make but it displays:
make[2] : on entre dans le répertoire « /home/vpham/Applications/libcaca-0.99.beta20/src »
CCLD cacaview
/usr/bin/ld: cacaview-common-image.o: in function load_image': /home/vpham/Applications/libcaca-0.99.beta20/src/common-image.c:164: undefined reference to _caca_alloc2d'
collect2: error: ld returned 1 exit status
make[2]: *** [Makefile:583 : cacaview] Erreur 1
make[2] : on quitte le répertoire « /home/vpham/Applications/libcaca-0.99.beta20/src »
make[1]: *** [Makefile:546 : all-recursive] Erreur 1
make[1] : on quitte le répertoire « /home/vpham/Applications/libcaca-0.99.beta20 »
make: *** [Makefile:440 : all] Erreur 2

@Micha0
Copy link

Micha0 commented Sep 4, 2023

I fixed it by making _caca_alloc2d a public exported symbol. Just add the function definition to caca/caca.h (line 244 seems to be perfect)

@GuyVDM
Copy link

GuyVDM commented Dec 11, 2023

I fixed it by making _caca_alloc2d a public exported symbol. Just add the function definition to caca/caca.h (line 244 seems to be perfect)

Could you show an example, I'm semi new to this library and have the same problem but i'm not sure how to convert it to a public exported symbol :o

@robert-dodier
Copy link

For the record, I've bumped into this same problem. I guess it's fixable by moving the definition of _caca_alloc2d into one of the source files that gets put into the library -- I gather caca/caca.c isn't.

I'll try to figure something out, but @Micha0 if you can post a patch, that would be really terrific.

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

4 participants