Skip to content

Commit

Permalink
Don't install cupscgi, cupsmime, or cupsppdc shared libraries.
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelrsweet committed Oct 29, 2018
1 parent 8994836 commit 1443510
Show file tree
Hide file tree
Showing 10 changed files with 58 additions and 288 deletions.
11 changes: 8 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
*.a
*.bck
*.cgi
*.dylib
*.gz
*.o
*.so
*.so.*
*.tokens
.buildrev
autom4te.cache
Expand Down Expand Up @@ -41,6 +38,14 @@ conf/cupsd.conf
conf/mime.convs
conf/pam.std
conf/snmp.conf
cups/libcups.dylib
cups/libcups.2.dylib
cups/libcups.so
cups/libcups.so.2
cups/libcupsimage.dylib
cups/libcupsimage.2.dylib
cups/libcupsimage.so
cups/libcupsimage.so.2
cups/locale/
cups/rasterbench
cups/test.pwg
Expand Down
4 changes: 3 additions & 1 deletion CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
CHANGES - 2.3b6 - 2018-09-28
CHANGES - 2.3b6 - 2018-10-29
============================

Changes in CUPS v2.3b6
Expand Down Expand Up @@ -38,6 +38,8 @@ Changes in CUPS v2.3b6
- Fixed an issue with HTTP Digest authentication (rdar://41709086)
- The scheduler could crash when job history was purged (rdar://42198057)
- Fixed a memory leak for some IPP (extension) syntaxes.
- The `cupscgi`, `cupsmime`, and `cupsppdc` support libraries are no longer
installed as shared libraries.


Changes in CUPS v2.3b5
Expand Down
7 changes: 2 additions & 5 deletions Makedefs.in
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#
# Common makefile definitions for CUPS.
#
# Copyright 2007-2018 by Apple Inc.
# Copyright 1997-2007 by Easy Software Products, all rights reserved.
# Copyright © 2007-2018 by Apple Inc.
# Copyright © 1997-2007 by Easy Software Products, all rights reserved.
#
# Licensed under Apache License v2.0. See the file "LICENSE" for more
# information.
Expand Down Expand Up @@ -92,10 +92,7 @@ LOCALTARGET = @LOCALTARGET@
#

LIBCUPS = @LIBCUPS@
LIBCUPSCGI = @LIBCUPSCGI@
LIBCUPSIMAGE = @LIBCUPSIMAGE@
LIBCUPSMIME = @LIBCUPSMIME@
LIBCUPSPPDC = @LIBCUPSPPDC@
LIBCUPSSTATIC = @LIBCUPSSTATIC@
LIBGSSAPI = @LIBGSSAPI@
LIBMALLOC = @LIBMALLOC@
Expand Down
85 changes: 15 additions & 70 deletions cgi-bin/Makefile
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
#
# CGI makefile for CUPS.
#
# Copyright 2007-2018 by Apple Inc.
# Copyright 1997-2006 by Easy Software Products.
# Copyright © 2007-2018 by Apple Inc.
# Copyright © 1997-2006 by Easy Software Products.
#
# Licensed under Apache License v2.0. See the file "LICENSE" for more information.
# Licensed under Apache License v2.0. See the file "LICENSE" for more
# information.
#

include ../Makedefs
Expand Down Expand Up @@ -34,8 +35,7 @@ CGIS = \
jobs.cgi \
printers.cgi
LIBTARGETS = \
libcupscgi.a \
$(LIBCUPSCGI)
libcupscgi.a

UNITTARGETS = \
testcgi \
Expand Down Expand Up @@ -74,7 +74,6 @@ unittests: $(UNITTARGETS)

clean:
$(RM) $(OBJS) $(TARGETS) $(UNITTARGETS) makedocset
$(RM) libcupscgi.so libcupscgi.dylib libcupscgi.a


#
Expand Down Expand Up @@ -104,16 +103,6 @@ install-data:
#

install-exec:
if test $(LIBCUPSCGI) != libcupscgi.a; then \
echo Installing libraries in $(LIBDIR)...; \
$(INSTALL_DIR) -m 755 $(LIBDIR); \
$(INSTALL_LIB) $(LIBCUPSCGI) $(LIBDIR); \
fi
if test "x$(SYMROOT)" != "x"; then \
$(INSTALL_DIR) $(SYMROOT); \
cp $(LIBCUPSCGI) $(SYMROOT); \
dsymutil $(SYMROOT)/$(LIBCUPSCGI); \
fi
$(INSTALL_DIR) -m 755 $(SERVERBIN)/cgi-bin
for file in $(CGIS); do \
$(INSTALL_BIN) $$file $(SERVERBIN)/cgi-bin; \
Expand Down Expand Up @@ -150,50 +139,6 @@ uninstall:
$(RM) $(SERVERBIN)/cgi-bin/$$file; \
done
-$(RMDIR) $(SERVERBIN)/cgi-bin
$(RM) $(LIBDIR)/libcupscgi.1.dylib
$(RM) $(LIBDIR)/libcupscgi.a
$(RM) $(LIBDIR)/libcupscgi.dylib
$(RM) $(LIBDIR)/libcupscgi.so
$(RM) $(LIBDIR)/libcupscgi.so.1
-$(RMDIR) $(LIBDIR)


#
# libcupscgi.so.1
#

libcupscgi.so.1: $(LIBOBJS)
echo Linking $@...
$(DSO) $(ARCHFLAGS) $(LDFLAGS) $(DSOFLAGS) -o $@ $(LIBOBJS) $(LIBS)
$(RM) `basename $@ .1`
$(LN) $@ `basename $@ .1`


#
# libcupscgi.1.dylib
#

libcupscgi.1.dylib: $(LIBOBJS) libcupscgi.exp
echo Linking $@...
$(DSO) $(ARCHFLAGS) $(LDFLAGS) $(DSOFLAGS) -o $@ \
-install_name $(libdir)/$@ \
-current_version 1.0.0 \
-compatibility_version 1.0.0 \
-exported_symbols_list libcupscgi.exp \
$(LIBOBJS) $(LIBS)
$(CODE_SIGN) -s "$(CODE_SIGN_IDENTITY)" $@
$(RM) libcupscgi.dylib
$(LN) $@ libcupscgi.dylib


#
# libcupscgi.la
#

libcupscgi.la: $(LIBOBJS)
echo Linking $@...
$(LD_CC) $(ARCHFLAGS) $(LDFLAGS) $(DSOFLAGS) -o $@ $(LIBOBJS:.o=.lo) -rpath $(LIBDIR) \
-version-info 1:0 $(LIBS)


#
Expand All @@ -211,49 +156,49 @@ libcupscgi.a: $(LIBOBJS)
# admin.cgi
#

admin.cgi: admin.o ../Makedefs ../cups/$(LIBCUPS) $(LIBCUPSCGI)
admin.cgi: admin.o ../Makedefs ../cups/$(LIBCUPS) libcupscgi.a
echo Linking $@...
$(LD_CC) $(LDFLAGS) -o $@ admin.o -lcupscgi $(LIBS)
$(LD_CC) $(LDFLAGS) -o $@ admin.o libcupscgi.a $(LIBS)
$(CODE_SIGN) -s "$(CODE_SIGN_IDENTITY)" $@


#
# classes.cgi
#

classes.cgi: classes.o ../Makedefs ../cups/$(LIBCUPS) $(LIBCUPSCGI)
classes.cgi: classes.o ../Makedefs ../cups/$(LIBCUPS) libcupscgi.a
echo Linking $@...
$(LD_CC) $(LDFLAGS) -o $@ classes.o -lcupscgi $(LIBS)
$(LD_CC) $(LDFLAGS) -o $@ classes.o libcupscgi.a $(LIBS)
$(CODE_SIGN) -s "$(CODE_SIGN_IDENTITY)" $@


#
# help.cgi
#

help.cgi: help.o ../Makedefs ../cups/$(LIBCUPS) $(LIBCUPSCGI)
help.cgi: help.o ../Makedefs ../cups/$(LIBCUPS) libcupscgi.a
echo Linking $@...
$(LD_CC) $(LDFLAGS) -o $@ help.o -lcupscgi $(LIBS)
$(LD_CC) $(LDFLAGS) -o $@ help.o libcupscgi.a $(LIBS)
$(CODE_SIGN) -s "$(CODE_SIGN_IDENTITY)" $@


#
# jobs.cgi
#

jobs.cgi: jobs.o ../Makedefs ../cups/$(LIBCUPS) $(LIBCUPSCGI)
jobs.cgi: jobs.o ../Makedefs ../cups/$(LIBCUPS) libcupscgi.a
echo Linking $@...
$(LD_CC) $(LDFLAGS) -o $@ jobs.o -lcupscgi $(LIBS)
$(LD_CC) $(LDFLAGS) -o $@ jobs.o libcupscgi.a $(LIBS)
$(CODE_SIGN) -s "$(CODE_SIGN_IDENTITY)" $@


#
# printers.cgi
#

printers.cgi: printers.o ../Makedefs ../cups/$(LIBCUPS) $(LIBCUPSCGI)
printers.cgi: printers.o ../Makedefs ../cups/$(LIBCUPS) libcupscgi.a
echo Linking $@...
$(LD_CC) $(LDFLAGS) -o $@ printers.o -L. -lcupscgi $(LIBS)
$(LD_CC) $(LDFLAGS) -o $@ printers.o libcupscgi.a $(LIBS)
$(CODE_SIGN) -s "$(CODE_SIGN_IDENTITY)" $@


Expand Down
25 changes: 4 additions & 21 deletions config-scripts/cups-sharedlibs.m4
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
dnl
dnl Shared library support for CUPS.
dnl
dnl Copyright 2007-2018 by Apple Inc.
dnl Copyright 1997-2005 by Easy Software Products, all rights reserved.
dnl Copyright © 2007-2018 by Apple Inc.
dnl Copyright © 1997-2005 by Easy Software Products, all rights reserved.
dnl
dnl Licensed under Apache License v2.0. See the file "LICENSE" for more information.
dnl Licensed under Apache License v2.0. See the file "LICENSE" for more
dnl information.
dnl

PICFLAG=1
Expand All @@ -20,30 +21,21 @@ if test x$enable_shared != xno; then
case "$host_os_name" in
sunos*)
LIBCUPS="lib$cupsbase.so.2"
LIBCUPSCGI="libcupscgi.so.1"
LIBCUPSIMAGE="libcupsimage.so.2"
LIBCUPSMIME="libcupsmime.so.1"
LIBCUPSPPDC="libcupsppdc.so.1"
DSO="\$(CC)"
DSOXX="\$(CXX)"
DSOFLAGS="$DSOFLAGS -Wl,-h\`basename \$@\` -G \$(OPTIM)"
;;
linux* | gnu* | *bsd*)
LIBCUPS="lib$cupsbase.so.2"
LIBCUPSCGI="libcupscgi.so.1"
LIBCUPSIMAGE="libcupsimage.so.2"
LIBCUPSMIME="libcupsmime.so.1"
LIBCUPSPPDC="libcupsppdc.so.1"
DSO="\$(CC)"
DSOXX="\$(CXX)"
DSOFLAGS="$DSOFLAGS -Wl,-soname,\`basename \$@\` -shared \$(OPTIM)"
;;
darwin*)
LIBCUPS="lib$cupsbase.2.dylib"
LIBCUPSCGI="libcupscgi.1.dylib"
LIBCUPSIMAGE="libcupsimage.2.dylib"
LIBCUPSMIME="libcupsmime.1.dylib"
LIBCUPSPPDC="libcupsppdc.1.dylib"
DSO="\$(CC)"
DSOXX="\$(CXX)"
DSOFLAGS="$DSOFLAGS -dynamiclib -single_module -lc"
Expand All @@ -52,10 +44,7 @@ if test x$enable_shared != xno; then
echo "Warning: shared libraries may not be supported. Trying -shared"
echo " option with compiler."
LIBCUPS="lib$cupsbase.so.2"
LIBCUPSCGI="libcupscgi.so.1"
LIBCUPSIMAGE="libcupsimage.so.2"
LIBCUPSMIME="libcupsmime.so.1"
LIBCUPSPPDC="libcupsppdc.so.1"
DSO="\$(CC)"
DSOXX="\$(CXX)"
DSOFLAGS="$DSOFLAGS -Wl,-soname,\`basename \$@\` -shared \$(OPTIM)"
Expand All @@ -64,10 +53,7 @@ if test x$enable_shared != xno; then
else
PICFLAG=0
LIBCUPS="lib$cupsbase.a"
LIBCUPSCGI="libcupscgi.a"
LIBCUPSIMAGE="libcupsimage.a"
LIBCUPSMIME="libcupsmime.a"
LIBCUPSPPDC="libcupsppdc.a"
DSO=":"
DSOXX=":"
fi
Expand All @@ -77,10 +63,7 @@ AC_SUBST(DSOXX)
AC_SUBST(DSOFLAGS)
AC_SUBST(LIBCUPS)
AC_SUBST(LIBCUPSBASE)
AC_SUBST(LIBCUPSCGI)
AC_SUBST(LIBCUPSIMAGE)
AC_SUBST(LIBCUPSMIME)
AC_SUBST(LIBCUPSPPDC)
AC_SUBST(LIBCUPSSTATIC)

if test x$enable_shared = xno; then
Expand Down
21 changes: 0 additions & 21 deletions configure
Original file line number Diff line number Diff line change
Expand Up @@ -688,10 +688,7 @@ LINKCUPS
EXTLINKCUPSIMAGE
EXTLINKCUPS
LIBCUPSSTATIC
LIBCUPSPPDC
LIBCUPSMIME
LIBCUPSIMAGE
LIBCUPSCGI
LIBCUPSBASE
LIBCUPS
DSOFLAGS
Expand Down Expand Up @@ -6599,30 +6596,21 @@ if test x$enable_shared != xno; then
case "$host_os_name" in
sunos*)
LIBCUPS="lib$cupsbase.so.2"
LIBCUPSCGI="libcupscgi.so.1"
LIBCUPSIMAGE="libcupsimage.so.2"
LIBCUPSMIME="libcupsmime.so.1"
LIBCUPSPPDC="libcupsppdc.so.1"
DSO="\$(CC)"
DSOXX="\$(CXX)"
DSOFLAGS="$DSOFLAGS -Wl,-h\`basename \$@\` -G \$(OPTIM)"
;;
linux* | gnu* | *bsd*)
LIBCUPS="lib$cupsbase.so.2"
LIBCUPSCGI="libcupscgi.so.1"
LIBCUPSIMAGE="libcupsimage.so.2"
LIBCUPSMIME="libcupsmime.so.1"
LIBCUPSPPDC="libcupsppdc.so.1"
DSO="\$(CC)"
DSOXX="\$(CXX)"
DSOFLAGS="$DSOFLAGS -Wl,-soname,\`basename \$@\` -shared \$(OPTIM)"
;;
darwin*)
LIBCUPS="lib$cupsbase.2.dylib"
LIBCUPSCGI="libcupscgi.1.dylib"
LIBCUPSIMAGE="libcupsimage.2.dylib"
LIBCUPSMIME="libcupsmime.1.dylib"
LIBCUPSPPDC="libcupsppdc.1.dylib"
DSO="\$(CC)"
DSOXX="\$(CXX)"
DSOFLAGS="$DSOFLAGS -dynamiclib -single_module -lc"
Expand All @@ -6631,10 +6619,7 @@ if test x$enable_shared != xno; then
echo "Warning: shared libraries may not be supported. Trying -shared"
echo " option with compiler."
LIBCUPS="lib$cupsbase.so.2"
LIBCUPSCGI="libcupscgi.so.1"
LIBCUPSIMAGE="libcupsimage.so.2"
LIBCUPSMIME="libcupsmime.so.1"
LIBCUPSPPDC="libcupsppdc.so.1"
DSO="\$(CC)"
DSOXX="\$(CXX)"
DSOFLAGS="$DSOFLAGS -Wl,-soname,\`basename \$@\` -shared \$(OPTIM)"
Expand All @@ -6643,10 +6628,7 @@ if test x$enable_shared != xno; then
else
PICFLAG=0
LIBCUPS="lib$cupsbase.a"
LIBCUPSCGI="libcupscgi.a"
LIBCUPSIMAGE="libcupsimage.a"
LIBCUPSMIME="libcupsmime.a"
LIBCUPSPPDC="libcupsppdc.a"
DSO=":"
DSOXX=":"
fi
Expand All @@ -6659,9 +6641,6 @@ fi






if test x$enable_shared = xno; then
LINKCUPS="../cups/lib$cupsbase.a"
LINKCUPSIMAGE="../cups/libcupsimage.a"
Expand Down
Loading

0 comments on commit 1443510

Please sign in to comment.