Opened 14 years ago

Last modified 12 years ago

#48 assigned enhancement

Improved support for mingw+msys

Reported by: guest Owned by: Sam Hocevar
Priority: major Milestone:
Component: build system Version: 0.99.beta16
Keywords: Cc:
Product: libcaca


Attached patch includes the changes for adding support to mingw+msys. Unfortunately, the "make install" still fails with this message:

Making install in caca make[1]: Entering directory `/home/pc/libcaca/caca' make[2]: Entering directory `/home/pc/libcaca/caca' /bin/sh /home/pc/libcaca-0.99.beta16-new/.auto/install-sh -d /home/pc/inst_libcaca/lib .; \

for x in $library_names; do \

ln -sf $x /home/pc/inst_libcaca/lib/$(echo $x | sed 's/caca/cucul/g'); \


ln: creating symbolic link /home/pc/inst_libcaca/lib/libcucul.dll.a' to libcaca.dll.a': No such file or directory

Description of changes: caca/caca.h caca/caca0.h declaration of dllimport and dllexport is wrong. I fixed it and now the symbols are imported/exported without problems. I'm using GCC 3.4.5 and it complained about the "weak" attribute into macro CACA_ALIAS, so I adjusted it to be available only if you are using GCC 4 and newer.

tools/makefont.c the htonl() and htons() are available in Windows Sockets. So I added the test on HAVE_WINSOCK2_H. Hopefully, the configure script already checks for the presence of winsock2.h I added the macro NEED_WINSOCK2 because we must initialize winsocks, but only if we have no other choice. For example, cygwin supports both arpa/inet.h and netinet/in.h beside winsock2.h: in that case winsocks initialization is not needed at all and it would cause troubles if handled in a different manner (WSAStartup function won't be found at link stage without compiling with winsock2.h because its true name is WSAStartup@8).


Carlo Bramini

Attachments (1)

libcaca.txt (2.8 KB) - added by guest 14 years ago.
Fix for this bug

Download all attachments as: .zip

Change History (4)

Changed 14 years ago by guest

Attachment: libcaca.txt added

Fix for this bug

comment:1 Changed 13 years ago by Sam Hocevar

Component: libcacabuild system
Product: libcaca

comment:2 Changed 13 years ago by Sam Hocevar

Status: newassigned

Thanks for the patches, they're all applied (or slightly reworked). Unfortunately the main problem (msys installation) is not fixed yet. I'll have to install a test system.

comment:3 Changed 12 years ago by LRN

doing this: libtoolize -cif && ./bootstrap before configuring seems to fix the problem with ln -sf Apparently, it is related to libtool.

Note: See TracTickets for help on using tickets.