aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2022-10-07 01:09:43 +0000
committerAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2022-10-07 01:09:43 +0000
commitc8829a8181017335bfd44a6c13f9e5f5c8472fff (patch)
tree2d1deaa70b416275f3cbded2987468aa4bcefb7c
parent8215fc2984c9c4618e918ff61f0fc52473b39cd1 (diff)
parentc57769818d86653969ccafdb1ecc4ed533c1638c (diff)
downloadlibcups-android14-tests-release.tar.gz
Change-Id: Id16aed40e600d420081d0eb91d8e73e52e3b8bb0
-rw-r--r--.gitattributes5
-rw-r--r--.gitignore156
-rw-r--r--.mailmap11
-rw-r--r--METADATA16
-rwxr-xr-xscripts/checkglobals32
-rwxr-xr-xscripts/listpublic12
-rwxr-xr-xscripts/makecups48
-rwxr-xr-xscripts/makerpm26
-rwxr-xr-xscripts/makesrcdist122
9 files changed, 420 insertions, 8 deletions
diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 00000000..2f20357d
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1,5 @@
+.git* export-ignore
+.mailmap export-ignore
+examples/testfile.pcl -text
+exampels/testfile.txt -text
+scripts export-ignore
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 00000000..a5e32e60
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,156 @@
+*.a
+*.bck
+*.cgi
+*.o
+autom4te.cache
+config.h
+config.log
+config.status
+cups-config
+Makedefs
+backend/dnssd
+backend/http
+backend/https
+backend/ipp
+backend/ipps
+backend/lpd
+backend/mdns
+backend/snmp
+backend/socket
+backend/test1284
+backend/testbackend
+backend/testsupplies
+backend/usb
+berkeley/lpc
+berkeley/lpq
+berkeley/lpr
+berkeley/lprm
+cgi-bin/testcgi
+cgi-bin/testhi
+cgi-bin/testhi.index
+cgi-bin/testtemplate
+conf/cups-files.conf
+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
+cups/test.raster
+cups/testadmin
+cups/testarray
+cups/testcache
+cups/testclient
+cups/testconflicts
+cups/testcreds
+cups/testcups
+cups/testdest
+cups/testfile
+cups/testgetdests
+cups/testhttp
+cups/testi18n
+cups/testipp
+cups/testlang
+cups/testoptions
+cups/testppd
+cups/testpwg
+cups/testraster
+cups/testsnmp
+cups/testthreads
+cups/tlscheck
+desktop/cups.desktop
+doc/index.html
+doc/*/index.html
+filter/commandtops
+filter/gziptoany
+filter/pstops
+filter/rastertoepson
+filter/rastertohp
+filter/rastertolabel
+filter/rastertopwg
+locale/checkpo
+locale/po2strings
+locale/strings2po
+man/mantohtml
+monitor/bcp
+monitor/tbcp
+notifier/dbus
+notifier/mailto
+notifier/rss
+notifier/testnotify
+packaging/cups.list
+ppdc/genstrings
+ppdc/ppd/
+ppdc/ppd2/
+ppdc/ppdc
+ppdc/ppdc-static
+ppdc/ppdhtml
+ppdc/ppdi
+ppdc/ppdi-static
+ppdc/ppdmerge
+ppdc/ppdpo
+ppdc/sample-import.drv
+ppdc/sample.c
+ppdc/testcatalog
+scheduler/convert
+scheduler/cups-deviced
+scheduler/cups-driverd
+scheduler/cups-exec
+scheduler/cups-lpd
+scheduler/cups-lpd.xinetd
+scheduler/cups.sh
+scheduler/cups.xml
+scheduler/cupsd
+scheduler/cupsfilter
+scheduler/org.cups.cups-lpd.plist
+scheduler/org.cups.cups-lpdAT.service
+scheduler/org.cups.cupsd.path
+scheduler/org.cups.cupsd.service
+scheduler/org.cups.cupsd.socket
+scheduler/testlpd
+scheduler/testmime
+scheduler/testspeed
+scheduler/testsub
+systemv/cancel
+systemv/cupsaccept
+systemv/cupsaddsmb
+systemv/cupsctl
+systemv/cupsdisable
+systemv/cupsenable
+systemv/cupsreject
+systemv/cupstestdsc
+systemv/cupstestppd
+systemv/lp
+systemv/lpadmin
+systemv/lpinfo
+systemv/lpmove
+systemv/lpoptions
+systemv/lpstat
+templates/header.tmpl
+templates/*/header.tmpl
+test/cups-str-*.html
+test/*_log-*
+tools/ippevepcl
+tools/ippeveprinter
+tools/ippeveprinter-static
+tools/ippeveps
+tools/ippfind
+tools/ippfind-static
+tools/ipptool
+tools/ipptool-static
+vcnet/.vs
+vcnet/packages
+vcnet/Win32
+vcnet/x64
+xcode/CUPS.xcodeproj/project.xcworkspace/
+xcode/CUPS.xcodeproj/xcuserdata/
+
diff --git a/.mailmap b/.mailmap
new file mode 100644
index 00000000..8638f645
--- /dev/null
+++ b/.mailmap
@@ -0,0 +1,11 @@
+# Prevent git from showing duplicate names with commands like "git shortlog"
+# See the manpage of git-shortlog for details.
+# The syntax is:
+# Name that should be used <email that should be used> Bad name <bad email>
+#
+# You can skip Bad name if it is the same as the one that should be used, and is unique.
+#
+# This file is up-to-date if the command git log --format="%aN <%aE>" | sort -u
+# gives no duplicates.
+Michael R Sweet <michaelrsweet@gmail.com> msweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
+Michael R Sweet <michaelrsweet@gmail.com> Michael Sweet <msweet@msweet-imac.local>
diff --git a/METADATA b/METADATA
index a4c4da69..cc1d0e0b 100644
--- a/METADATA
+++ b/METADATA
@@ -9,18 +9,18 @@ third_party {
value: "https://www.cups.org/"
}
url {
- type: ARCHIVE
- value: "https://github.com/apple/cups/releases/download/v2.3.3/cups-2.3.3-source.tar.gz"
+ type: GIT
+ value: "https://github.com/apple/cups/"
}
version: "v2.3.3"
- license_note: "would be RESTRICTED save for Apple license in backend/usb-darwin.c"
license_type: BY_EXCEPTION_ONLY
+ license_note: "would be RESTRICTED save for Apple license in backend/usb-darwin.c"
+ security {
+ tag: "NVD-CPE2.3:cpe:/a:cups:cups:2.3.3"
+ }
last_upgrade_date {
- year: 2020
+ year: 2022
month: 10
- day: 28
- }
- security {
- tag: "NVD-CPE2.3:cpe:/a:cups:cups:2.3.3"
+ day: 4
}
}
diff --git a/scripts/checkglobals b/scripts/checkglobals
new file mode 100755
index 00000000..4d15387e
--- /dev/null
+++ b/scripts/checkglobals
@@ -0,0 +1,32 @@
+#!/bin/sh
+#
+# Check for global symbols that don't need to be made global...
+#
+
+for file in *.o; do
+ functions=""
+
+ for function in `nm -g $file | grep "T " | awk '{print $3}'`; do
+ found=""
+ for file2 in *.o; do
+ if test "$file" = "$file2"; then
+ continue;
+ fi
+
+ found=`nm -g $file2 | grep $function`
+ if test "$found" != ""; then
+ break;
+ fi
+ done
+
+ if test -z "$found"; then
+ functions="$functions $function"
+ fi
+ done
+
+ if test -z "$functions"; then
+ echo "$file: OK"
+ else
+ echo "$file: $functions"
+ fi
+done
diff --git a/scripts/listpublic b/scripts/listpublic
new file mode 100755
index 00000000..d864e7ee
--- /dev/null
+++ b/scripts/listpublic
@@ -0,0 +1,12 @@
+#!/bin/sh
+#
+# List public API symbols...
+#
+
+for function in `nm -g *.so | grep "T " | awk '{print $3}' | grep -v '^_' | sort`; do
+ found=`grep $function\( *.h | grep -v DEPRECATED`
+
+ if test "x$found" != x; then
+ echo $function
+ fi
+done
diff --git a/scripts/makecups b/scripts/makecups
new file mode 100755
index 00000000..3c0cc951
--- /dev/null
+++ b/scripts/makecups
@@ -0,0 +1,48 @@
+#!/bin/sh
+#
+# Script to configure and make CUPS with the standard build options. When no
+# targets are specified, the "clean" and "check" targets are used.
+#
+# Usage:
+#
+# scripts/makecups [configure option(s)] [make target(s)]
+#
+
+# Scan the command-line arguments...
+confopts="--enable-debug --enable-debug-guards --enable-debug-printfs --enable-sanitizer --enable-unit-tests"
+makeopts=""
+
+while test $# -gt 0; do
+ opt="$1"
+ shift
+
+ case "$opt" in
+ -*)
+ confopts="$confopts $opt"
+ ;;
+ *)
+ makeopts="$makeopts $opt"
+ ;;
+ esac
+done
+
+if test "x$makeopts" = x; then
+ makeopts="clean check"
+fi
+
+case "`uname`" in
+ Darwin)
+ makeopts="-j`sysctl -n hw.activecpu` $makeopts"
+ ;;
+ Linux*)
+ ASAN_OPTIONS="leak_check_at_exit=false"; export ASAN_OPTIONS
+ ;;
+esac
+
+# Run the configure script...
+echo ./configure $confopts
+./configure $confopts || exit 1
+
+# Build the software...
+echo make $makeopts
+make $makeopts
diff --git a/scripts/makerpm b/scripts/makerpm
new file mode 100755
index 00000000..3fa57770
--- /dev/null
+++ b/scripts/makerpm
@@ -0,0 +1,26 @@
+#!/bin/sh -x
+#
+# Test script for making RPMs...
+#
+
+# Make sure we are running in the right directory...
+if test ! -f scripts/makerpm; then
+ echo "Run this script from the top-level CUPS source directory, e.g.:"
+ echo ""
+ echo " scripts/makerpm [rpmbuild options]"
+ echo ""
+ exit 1
+fi
+
+# Strip command-line arguments so we don't create a release tag...
+args="$*"
+shift $#
+
+# Get a snapshot of the current source...
+. scripts/makesrcdist
+
+# Build the RPM...
+echo Building rpm...
+#rm -f /usr/src/redhat/RPMS/i386/cups*.rpm
+#rm -f /usr/src/redhat/SRPMS/cups*.rpm
+rpmbuild -ta $args cups-${fileversion}-source.tar.gz
diff --git a/scripts/makesrcdist b/scripts/makesrcdist
new file mode 100755
index 00000000..33b2f37c
--- /dev/null
+++ b/scripts/makesrcdist
@@ -0,0 +1,122 @@
+#!/bin/sh
+#
+# makesrcdist - make a source distribution of CUPS.
+#
+
+TMPDIR="${TMPDIR:=/tmp}"
+
+# Make sure we are running in the right directory...
+if test ! -f scripts/makesrcdist; then
+ echo "Run this script from the top-level CUPS source directory, e.g.:"
+ echo ""
+ echo " scripts/makesrcdist $*"
+ echo ""
+ exit 1
+fi
+
+# See if we have local changes (other than this script...)
+if (git status | grep -v makesrcdist | grep -v makerpm | grep -q modified:); then
+ echo Local changes remain:
+ git status | grep -v makesrcdist | grep modified:
+ exit 1
+fi
+
+# Prep for snapshot or version release...
+if test $# = 0; then
+ # Compute version for snapshot
+ rev=`git show --oneline | head -1 | awk '{print $1}'`
+ version="2.3git"
+ fileversion="2.3git-$rev"
+ fileurl="file://$TMPDIR/cups-${fileversion}-source.tar.gz"
+ SIGNFILES=no
+else
+ # Use version from command-line
+ rev="1"
+ version=$1
+ fileversion=$1
+ fileurl="https://github.com/apple/cups/releases/download/v$fileversion/cups-${fileversion}-source.tar.gz"
+ SIGNFILES=yes
+
+ echo Validating sources...
+ cupsversionpatch=`echo $version | awk -F. '{if (NF == 3) { print $3 } else { print "0" } }'`
+ cupsversion=`printf "2.03%02d" $cupsversionpatch`
+
+ temp=`grep AC_INIT configure.ac | awk '{print $2}' | sed -e '1,$s/^\[//' -e '1,$s/\],$//'`
+ if test "$temp" != $version; then
+ echo "Still need to update version to $version in configure.ac (saw $temp)"
+ exit 1
+ fi
+
+ temp=`grep CUPS_VERSION cups/cups.h | grep -v CUPS_VERSION_ | awk '{print $4}'`
+ if test "$temp" != $cupsversion; then
+ echo "Still need to update CUPS_VERSION to $cupsversion in cups/cups.h (saw $temp)"
+ exit 1
+ fi
+
+ temp=`grep CUPS_VERSION_PATCH cups/cups.h | awk '{print $4}'`
+ if test "$temp" != $cupsversionpatch; then
+ echo "Still need to update CUPS_VERSION_PATCH to $cupsversionpatch in cups/cups.h (saw $temp)"
+ exit 1
+ fi
+
+ temp=`head -1 README.md | awk '{print $4}'`
+ if test "$temp" != "v$version"; then
+ echo "Still need to update version to v$version in README.md (saw $temp)"
+ exit 1
+ fi
+
+ temp=`head -1 INSTALL.md | awk '{print $4}'`
+ if test "$temp" != "v$version"; then
+ echo "Still need to update version to v$version in INSTALL.md (saw $temp)"
+ exit 1
+ fi
+
+ temp=`head -6 CHANGES.md | grep "Changes in" | awk '{print $4}'`
+ if test "$temp" != "v$version"; then
+ echo "Still need to add Changes in v$version in CHANGES.md (saw $temp)"
+ exit 1
+ fi
+
+ echo Creating tag for release...
+ git tag -m "Tag $version" v$version
+ git push origin v$version
+fi
+
+fileurl=`echo $fileurl | sed -e '1,$s/\\//\\\\\\//g'`
+file="$HOME/cups-$fileversion-source.tar"
+
+echo Exporting $fileversion...
+rm -rf $TMPDIR/cups-$version
+mkdir $TMPDIR/cups-$version
+git archive --format tar HEAD | (cd $TMPDIR/cups-$version; tar xf -)
+
+echo Preparing files...
+cd $TMPDIR/cups-$version
+sed -e '1,$s/@CUPS_VERSION@/'$version'/' \
+ -e '1,$s/^Source:.*/Source: '$fileurl'/' \
+ <packaging/cups.spec.in \
+ >packaging/cups.spec
+rm -rf .gitignore
+cd ..
+
+echo Archiving...
+tar cf $file cups-$version
+
+echo Compressing...
+if (which zopfli >/dev/null); then
+ zopfli $file
+ rm -f $file
+else
+ gzip -v9 $file
+fi
+
+if test $SIGNFILES = yes; then
+ echo Signing...
+ test -f $file.gz.sig && rm -f $file.gz.sig
+ gpg --detach-sign -u security@cups.org $file.gz
+fi
+
+echo Removing temporary files...
+rm -rf cups-$version
+
+echo "Done - files in $HOME."