[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Can't link libtiff.a static


I want to debug a program of mine using dmalloc.  For that purpose
I wanted to link all libs statically.
I tried to reduce my problem to a simple one and wrote a simple
Makefile that compiles tiffinfo from the libtiff package.

Here is this Makefile
# makefile for tiffinfo

NAME = tiffinfo



.SUFFIXES: .c .o

	$(CC) -c $(CFLAGS) $(INCLUDES) -o $@ $< $(ERROR)

default: $(NAME)

$(NAME): $(OBJS)
	$(CC)  -o $@ $(OBJS) $(LDFLAGS) $(LIBS) 

$(NAME).o:     $(NAME).c

	rm -f *.o core $(NAME) *~ *.x *.a


If you comment out the line which defines LIBDMALLOC in the beginning,
which let ld do dynamically linking all works well.
But with the LIBDMALLOC define, which enforces statically linking
the libtiff functions were not found by the linker.

I'm relatively sure that this problem doesn't happen on my Hamm
system at home.  So I think something was happen in slink that
causes this trouble, but I can't imagine any reason.

Any help appreciated


Reply to: