Sweden-Number/programs/avitools/Makefile.in

89 lines
2.7 KiB
Makefile
Raw Normal View History

DEFS = @DLLFLAGS@ -DSTRICT -DNONAMELESSUNION -DNONAMELESSSTRUCT $(EXTRADEFS)
2000-11-11 00:45:20 +01:00
LDDLLFLAGS = @LDDLLFLAGS@
TOPSRCDIR = @top_srcdir@
TOPOBJDIR = ../..
SRCDIR = @srcdir@
VPATH = @srcdir@
MODULE = none
PROGRAMS = aviinfo.exe aviplay.exe icinfo.exe
ALL_LIBS = $(LIBWINE) $(LIBS)
C_SRCS = \
aviinfo.c \
aviplay.c \
icinfo.c
@MAKE_RULES@
all: $(PROGRAMS:%=%$(DLLEXT)) $(PROGRAMS:.exe=$(EXEEXT))
aviinfo.exe.spec.c: aviinfo.o $(WINEBUILD)
$(LDPATH) $(WINEBUILD) $(DEFS) -o $@ -exe aviinfo.exe -mgui aviinfo.o -L$(DLLDIR) -lkernel32
aviplay.exe.spec.c: aviplay.o $(WINEBUILD)
$(LDPATH) $(WINEBUILD) $(DEFS) -o $@ -exe aviplay.exe -mgui aviplay.o -L$(DLLDIR) -lddraw -lkernel32
icinfo.exe.spec.c: icinfo.o $(WINEBUILD)
$(LDPATH) $(WINEBUILD) $(DEFS) -o $@ -exe icinfo.exe -mgui icinfo.o -L$(DLLDIR) -lmsvfw32 -lkernel32
2000-11-11 00:45:20 +01:00
aviinfo.exe.so: aviinfo.o aviinfo.exe.spec.o
$(LDSHARED) $(LDDLLFLAGS) -o $@ aviinfo.o aviinfo.exe.spec.o $(ALL_LIBS)
2000-11-11 00:45:20 +01:00
aviplay.exe.so: aviplay.o aviplay.exe.spec.o
$(LDSHARED) $(LDDLLFLAGS) -o $@ aviplay.o aviplay.exe.spec.o $(ALL_LIBS)
2000-11-11 00:45:20 +01:00
icinfo.exe.so: icinfo.o icinfo.exe.spec.o
$(LDSHARED) $(LDDLLFLAGS) -o $@ icinfo.o icinfo.exe.spec.o $(ALL_LIBS)
aviinfo.exe: aviinfo.o
$(CC) -o $@ aviinfo.o -lkernel32 $(ALL_LIBS)
aviplay.exe: aviplay.o
$(CC) -o $@ aviplay.o -lddraw -lkernel32 $(ALL_LIBS)
icinfo.exe: icinfo.o
$(CC) -o $@ icinfo.o -lmsvfw32 -lkernel32 $(ALL_LIBS)
$(PROGRAMS:.exe=): $(WINEWRAPPER)
$(RM) $@ && $(LN_S) $(WINEWRAPPER) $@
2000-11-11 00:45:20 +01:00
# Rules for installation
2000-11-11 00:45:20 +01:00
.PHONY: install_prog install_prog.so uninstall_prog uninstall_prog.so
2000-11-11 00:45:20 +01:00
install_prog.so: $(PROGRAMS:%=%.so)
$(MKINSTALLDIRS) $(dlldir)
$(INSTALL_PROGRAM) aviinfo.exe.so $(dlldir)/aviinfo.exe.so
$(INSTALL_PROGRAM) aviplay.exe.so $(dlldir)/aviplay.exe.so
$(INSTALL_PROGRAM) icinfo.exe.so $(dlldir)/icinfo.exe.so
install_prog: $(PROGRAMS)
$(MKINSTALLDIRS) $(bindir)
$(INSTALL_PROGRAM) aviinfo.exe $(bindir)/aviinfo.exe
$(INSTALL_PROGRAM) aviplay.exe $(bindir)/aviplay.exe
$(INSTALL_PROGRAM) icinfo.exe $(bindir)/icinfo.exe
uninstall_prog.so:
$(RM) $(PROGRAMS:%=$(dlldir)/%.so)
uninstall_prog:
$(RM) $(PROGRAMS:%=$(bindir)/%)
install:: install_prog$(DLLEXT)
uninstall:: uninstall_prog$(DLLEXT)
clean::
$(RM) $(PROGRAMS:.exe=)
# Rules for checking that no imports are missing
CHECKLINK_RPATH = library tsx11 unicode
2000-11-11 00:45:20 +01:00
checklink:: $(PROGRAMS:%=%.so)
$(CC) -o checklink $(CHECKLINK_RPATH:%=-Wl,-rpath,$(TOPOBJDIR)/%) $(TOPSRCDIR)/library/checklink.c aviinfo.exe.so && $(RM) checklink
$(CC) -o checklink $(CHECKLINK_RPATH:%=-Wl,-rpath,$(TOPOBJDIR)/%) $(TOPSRCDIR)/library/checklink.c aviplay.exe.so && $(RM) checklink
$(CC) -o checklink $(CHECKLINK_RPATH:%=-Wl,-rpath,$(TOPOBJDIR)/%) $(TOPSRCDIR)/library/checklink.c icinfo.exe.so && $(RM) checklink
### Dependencies: