view postproc/Makefile @ 17566:f580a7755ac5

Patch by Stefan Huehner / stefan % huehner ! org \ patch replaces '()' for the correct '(void)' in function declarations/prototypes which have no parameters. The '()' syntax tell thats there is a variable list of arguments, so that the compiler cannot check this. The extra CFLAG '-Wstrict-declarations' shows those cases. Comments about a similar patch applied to ffmpeg: That in C++ these mean the same, but in ANSI C the semantics are different; function() is an (obsolete) K&R C style forward declaration, it basically means that the function can have any number and any types of parameters, effectively completely preventing the compiler from doing any sort of type checking. -- Erik Slagter Defining functions with unspecified arguments is allowed but bad. With arguments unspecified the compiler can't report an error/warning if the function is called with incorrect arguments. -- M\ns Rullg\rd
author rathann
date Thu, 09 Feb 2006 14:08:03 +0000
parents ce1ba8fd57e7
children
line wrap: on
line source


include ../config.mak

SWSLIB = libswscale.a

SWSSRCS=swscale.c rgb2rgb.c yuv2rgb.c

SWSOBJS=$(SWSSRCS:.c=.o)

ifeq ($(TARGET_ALTIVEC),yes)
SWSOBJS +=  yuv2rgb_altivec.o
endif

CFLAGS  = $(OPTFLAGS) $(MLIB_INC) -I. -I.. $(EXTRA_INC)
# -I/usr/X11R6/include/

.SUFFIXES: .c .o

# .PHONY: all clean

.c.o:
	$(CC) -c $(CFLAGS) -I.. -o $@ $<

all:    $(SWSLIB)

$(SWSLIB):     $(SWSOBJS)
	$(AR) r $(SWSLIB) $(SWSOBJS)
	$(RANLIB) $(SWSLIB)

clean:
	rm -f *.o *.a *~ *.so cs_test swscale-example

distclean: clean
	rm -f .depend

dep:    depend

depend:
	$(CC) -MM $(CFLAGS) $(SWSSRCS) 1>.depend

cs_test: cs_test.o $(SWSLIB)
	$(CC) cs_test.o $(SWSLIB) ../cpudetect.o -DFOR_MENCODER ../mp_msg.c -o cs_test -W -Wall

swscale-example: swscale-example.o $(SWSLIB)
	$(CC) swscale-example.o $(SWSLIB) ../libmpcodecs/img_format.o -lm -o swscale-example -W -Wall
#
# include dependency files if they exist
#
ifneq ($(wildcard .depend),)
include .depend
endif