#
# "$Id: Makefile 7924 2008-09-10 17:36:13Z mike $"
#
-# Backend makefile for the Common UNIX Printing System (CUPS).
+# Backend makefile for CUPS.
#
-# Copyright 2007-2009 by Apple Inc.
+# Copyright 2007-2011 by Apple Inc.
# Copyright 1997-2007 by Easy Software Products, all rights reserved.
#
# These coded instructions, statements, and computer programs are the
include ../Makedefs
+#
+# Object files...
+#
+
RBACKENDS = ipp lpd $(DNSSD_BACKEND)
-UBACKENDS = $(PAP) $(LEGACY_BACKENDS) serial snmp socket usb
-TARGETS = test1284 testbackend testsupplies \
- libbackend.a $(RBACKENDS) $(UBACKENDS)
+UBACKENDS = $(LEGACY_BACKENDS) serial snmp socket usb
+UNITTESTS = test1284 testbackend testsupplies
+TARGETS = libbackend.a $(RBACKENDS) $(UBACKENDS)
LIBOBJS = ieee1284.o network.o runloop.o snmp-supplies.o
-OBJS = ipp.o lpd.o dnssd.o pap.o parallel.o scsi.o serial.o snmp.o \
+OBJS = ipp.o lpd.o dnssd.o parallel.o serial.o snmp.o \
socket.o test1284.o testbackend.o testsupplies.o usb.o
# Make unit tests...
#
-unittests:
+unittests: $(UNITTESTS)
#
#
clean:
- $(RM) $(OBJS) $(TARGETS) $(LIBOBJS) http mdns
+ $(RM) $(OBJS) $(TARGETS) $(UNITTESTS) $(LIBOBJS) http mdns
#
# Install programs...
#
-install-exec:
+install-exec: $(INSTALLXPC)
+ echo Installing backends in $(SERVERBIN)/backend
$(INSTALL_DIR) -m 755 $(SERVERBIN)/backend
for file in $(RBACKENDS); do \
$(LIBTOOL) $(INSTALL_BIN) -m 700 $$file $(SERVERBIN)/backend; \
for file in $(UBACKENDS); do \
$(INSTALL_BIN) $$file $(SERVERBIN)/backend; \
done
- $(RM) $(SERVERBIN)/backend/http
- $(LN) ipp $(SERVERBIN)/backend/http
+ for file in $(IPPALIASES); do \
+ $(RM) $(SERVERBIN)/backend/$$file; \
+ $(LN) ipp $(SERVERBIN)/backend/$$file; \
+ done
if test "x$(DNSSD_BACKEND)" != x; then \
$(RM) $(SERVERBIN)/backend/mdns; \
$(LN) $(DNSSD_BACKEND) $(SERVERBIN)/backend/mdns; \
done \
fi
+install-xpc: ipp
+ echo Installing XPC backends in $(SERVERBIN)/apple
+ $(INSTALL_DIR) -m 755 $(SERVERBIN)/apple
+ $(LIBTOOL) $(INSTALL_BIN) ipp $(SERVERBIN)/apple
+ for file in $(IPPALIASES); do \
+ $(RM) $(SERVERBIN)/apple/$$file; \
+ $(LN) ipp $(SERVERBIN)/apple/$$file; \
+ done
+
#
# Install headers...
#
uninstall:
+ $(RM) $(SERVERBIN)/apple/ipp
+ for file in $(IPPALIASES); do \
+ $(RM) $(SERVERBIN)/apple/$$file; \
+ done
+ -$(RMDIR) $(SERVERBIN)/apple
for file in $(RBACKENDS) $(UBACKENDS); do \
$(RM) $(SERVERBIN)/backend/$$file; \
done
- $(RM) $(SERVERBIN)/backend/http
+ for file in $(IPPALIASES); do \
+ $(RM) $(SERVERBIN)/backend/$$file; \
+ done
-$(RMDIR) $(SERVERBIN)/backend
-$(RMDIR) $(SERVERBIN)
# test1284
#
-test1284: test1284.o ../cups/libcups.a
+test1284: test1284.o ../cups/$(LIBCUPSSTATIC)
echo Linking $@...
- $(CC) $(LDFLAGS) -o test1284 test1284.o ../cups/libcups.a \
+ $(CC) $(LDFLAGS) -o test1284 test1284.o ../cups/$(LIBCUPSSTATIC) \
$(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ)
# testbackend
#
-testbackend: testbackend.o ../cups/libcups.a
+testbackend: testbackend.o ../cups/$(LIBCUPSSTATIC)
echo Linking $@...
- $(CC) $(LDFLAGS) -o testbackend testbackend.o ../cups/libcups.a \
+ $(CC) $(LDFLAGS) -o testbackend testbackend.o ../cups/$(LIBCUPSSTATIC) \
$(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ)
# testsupplies
#
-testsupplies: testsupplies.o libbackend.a ../cups/libcups.a
+testsupplies: testsupplies.o libbackend.a ../cups/$(LIBCUPSSTATIC)
echo Linking $@...
$(CC) $(LDFLAGS) -o testsupplies testsupplies.o libbackend.a \
- ../cups/libcups.a $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) \
+ ../cups/$(LIBCUPSSTATIC) $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) \
$(COMMONLIBS) $(LIBZ)
$(CC) $(LDFLAGS) -o lpd lpd.o libbackend.a $(LIBS)
-#
-# pap
-#
-
-pap: pap.o ../cups/$(LIBCUPS)
- echo Linking $@...
- $(CC) $(LDFLAGS) -o pap pap.o $(BACKLIBS) $(LIBS) -framework AppleTalk
-
-
#
# parallel
#
$(CC) $(LDFLAGS) -o parallel parallel.o libbackend.a $(LIBS)
-#
-# scsi
-#
-
-scsi: scsi.o ../cups/$(LIBCUPS)
- echo Linking $@...
- $(CC) $(LDFLAGS) -o scsi scsi.o $(LIBS)
-
-scsi.o: scsi.c scsi-irix.c scsi-linux.c
-
-
#
# serial
#