sm-commit AT lists.ibiblio.org
Subject: Source Mage code commit list
List archive
[SM-Commit] GIT changes to devel-xorg-modular grimoire by Eric Sandall (84ba7cd690fb9bf2eb54e6affcb380e953dbe0fd)
- From: Eric Sandall <scm AT sourcemage.org>
- To: sm-commit AT lists.ibiblio.org
- Subject: [SM-Commit] GIT changes to devel-xorg-modular grimoire by Eric Sandall (84ba7cd690fb9bf2eb54e6affcb380e953dbe0fd)
- Date: Tue, 7 Aug 2012 19:39:45 -0500
GIT changes to devel-xorg-modular grimoire by Eric Sandall
<sandalle AT sourcemage.org>:
graphics-libs/cimg/DETAILS | 4
graphics-libs/cimg/HISTORY | 3
graphics/gmic/BUILD | 1
graphics/gmic/DETAILS | 4
graphics/gmic/HISTORY | 6
graphics/gmic/INSTALL | 1
graphics/gmic/PRE_BUILD | 6
graphics/gmic/opencv-buildfix.patch | 32
graphics/gmic/patch-configure | 113 -
graphics/gmic/patch-src_Makefile | 56
graphics/graphicsmagick/DETAILS | 4
graphics/graphicsmagick/HISTORY | 3
kde4-look/oxygen-gtk2/DETAILS | 4
kde4-look/oxygen-gtk2/HISTORY | 5
kde4-look/oxygen-gtk3/DETAILS | 4
kde4-look/oxygen-gtk3/HISTORY | 3
libs/nspr/DETAILS | 4
libs/nspr/HISTORY | 3
net/openntpd/BUILD | 6
net/openntpd/DETAILS | 1
net/openntpd/HISTORY | 6
net/openntpd/PRE_BUILD | 4
net/openntpd/linux-adjtimex.patch | 168 ++
printer/pycups/DETAILS | 8
printer/pycups/HISTORY | 4
printer/pycups/PRE_BUILD | 3
printer/pycups/pycups-1.9.61-cups-1.6.patch | 1675
----------------------------
printer/system-config-printer/DETAILS | 2
printer/system-config-printer/HISTORY | 3
science-libs/eigen3/DETAILS | 6
science-libs/eigen3/HISTORY | 3
x11-libs/wine/DETAILS | 2
x11-libs/wine/HISTORY | 3
33 files changed, 277 insertions(+), 1873 deletions(-)
New commits:
commit a00d0241288e7e50c1ea3041951a6e67a962e54f
Author: Eric Sandall <sandalle AT sourcemage.org>
Commit: Eric Sandall <sandalle AT sourcemage.org>
wine: Updated devel to 1.5.10
commit fbda0e8121ac392a699cdf5b3c26e25048b52e67
Author: Ladislav Hagara <hgr AT vabo.cz>
Commit: Ladislav Hagara <hgr AT vabo.cz>
system-config-printer 1.3.11
commit 9bcc62057929d9deb64291ed937c4bc42f2f1d6e
Author: Ladislav Hagara <hgr AT vabo.cz>
Commit: Ladislav Hagara <hgr AT vabo.cz>
pycups 1.9.62
commit 470c308b694ef9239a7b19eca9f0e11c2d2b1aa3
Author: Ladislav Hagara <hgr AT vabo.cz>
Commit: Ladislav Hagara <hgr AT vabo.cz>
cimg 1.5.0
commit ada39424394df134dd360f8b9a7aff89a6b5ee9f
Author: Ladislav Hagara <hgr AT vabo.cz>
Commit: Ladislav Hagara <hgr AT vabo.cz>
graphicsmagick 1.3.16
commit cd710f48894a3b27f86f996d7a09831b775dcd15
Author: Ladislav Hagara <hgr AT vabo.cz>
Commit: Ladislav Hagara <hgr AT vabo.cz>
gmic 1.5.1.7
commit 7f02254350379a81d4e093b97873304cfa6a189d
Author: Ladislav Hagara <hgr AT vabo.cz>
Commit: Ladislav Hagara <hgr AT vabo.cz>
nspr 4.9.2
commit d9d4915d6223740e03a54ee9553742749f1901b8
Author: Vlad Glagolev <stealth AT sourcemage.org>
Commit: Vlad Glagolev <stealth AT sourcemage.org>
openntpd: applied a patch to fix time sync on modern systems
commit 1421ebe23bbaded1e7a11542b8a6c76f94a23dcd
Author: Treeve Jelbert <treeve AT sourcemage.org>
Commit: Treeve Jelbert <treeve AT sourcemage.org>
eigen3: => 3.1.1
commit b53dc59b333933eb9eac361d5db127e6456ad0f4
Author: Julien ROZO <julien AT rozo.org>
Commit: Julien ROZO <julien AT rozo.org>
oxygen-gtk3: updated version to 1.1.0
commit 84e3aedb487e88650e829e84f8e8a0a438361dc0
Author: Julien ROZO <julien AT rozo.org>
Commit: Julien ROZO <julien AT rozo.org>
oxygen-gtk2: updated version to 1.3.0
diff --git a/graphics-libs/cimg/DETAILS b/graphics-libs/cimg/DETAILS
index d8a2979..21e60ae 100755
--- a/graphics-libs/cimg/DETAILS
+++ b/graphics-libs/cimg/DETAILS
@@ -1,6 +1,6 @@
SPELL=cimg
- VERSION=1.4.9
-
SOURCE_HASH=sha512:619959466d04869d4da7a1b0d5f1fc1c854bfb0edf5049d3b2d5d810796a1bd178a0821b79c9c1ae7ea195353efa272d0fe1ccb6e53b192245109d393fd1124c
+ VERSION=1.5.0
+
SOURCE_HASH=sha512:48a98f9d50bd091f5692023ef96ad25c9a76366ece9acae2cb751cbcd97a2b99eb941d2ef902dbcd2c0fc3de5041561a0f600f369ef7c14edfcac7a95372c2aa
SOURCE=CImg-${VERSION}.zip
SOURCE_URL[0]=${SOURCEFORGE_URL}/${SPELL}/${SOURCE}
SOURCE_DIRECTORY=${BUILD_DIRECTORY}/CImg-${VERSION}
diff --git a/graphics-libs/cimg/HISTORY b/graphics-libs/cimg/HISTORY
index 89c2fde..5b9ca3e 100644
--- a/graphics-libs/cimg/HISTORY
+++ b/graphics-libs/cimg/HISTORY
@@ -1,3 +1,6 @@
+2012-08-07 Ladislav Hagara <hgr AT vabo.cz>
+ * DETAILS: 1.5.0
+
2012-02-06 Ladislav Hagara <hgr AT vabo.cz>
* DETAILS: 1.4.9
diff --git a/graphics/gmic/BUILD b/graphics/gmic/BUILD
new file mode 100755
index 0000000..c4011d5
--- /dev/null
+++ b/graphics/gmic/BUILD
@@ -0,0 +1 @@
+PATH=$PATH:/usr/bin/qt4 make -C src all
diff --git a/graphics/gmic/DETAILS b/graphics/gmic/DETAILS
index 71c635b..aeac322 100755
--- a/graphics/gmic/DETAILS
+++ b/graphics/gmic/DETAILS
@@ -1,9 +1,9 @@
SPELL=gmic
- VERSION=1.5.0.4
+ VERSION=1.5.1.7
SOURCE="${SPELL}_${VERSION}.tar.gz"
SOURCE_URL[0]=$SOURCEFORGE_URL/project/${SPELL}/${SOURCE}
SOURCE_URL[1]=$SOURCEFORGE_URL/project/${SPELL}/old/${SOURCE}
-
SOURCE_HASH=sha512:35b37dd257e0b9558ea04a3886f39af6adece219fe6390917a90fcbfedde356ddd8301e53f90bcff60d986de7822e79cf3c2372e06b997a4763cde3349c021c6
+
SOURCE_HASH=sha512:1ed7b7ea4e00e418d3fe37c9a04a5805bfbbc358b50fe213c02ca5d040af9e9cb6a6e4df7b32fa695f2988eda8a176933af9d6aabbe51d7418aee7a180f2a2d3
SOURCE_DIRECTORY="${BUILD_DIRECTORY}/${SPELL}-${VERSION}"
WEB_SITE="http://gmic.sourceforge.net/"
LICENSE[0]="CeCILL"
diff --git a/graphics/gmic/HISTORY b/graphics/gmic/HISTORY
index 4b67b42..6d3e973 100644
--- a/graphics/gmic/HISTORY
+++ b/graphics/gmic/HISTORY
@@ -1,3 +1,9 @@
+2012-08-07 Ladislav Hagara <hgr AT vabo.cz>
+ * DETAILS: 1.5.1.7
+ * patch-configure, patch-src_Makefile: removed
+ * PRE_BUILD, opencv-buildfix.patch: patch from Arch added
+ * BUILD, INSTALL: added
+
2011-10-31 Bor Kraljič <pyrobor AT ver.si>
* DETAILS: added "old" url as SOURCE_URL[1]
diff --git a/graphics/gmic/INSTALL b/graphics/gmic/INSTALL
new file mode 100755
index 0000000..ed46188
--- /dev/null
+++ b/graphics/gmic/INSTALL
@@ -0,0 +1 @@
+make -C src install
diff --git a/graphics/gmic/PRE_BUILD b/graphics/gmic/PRE_BUILD
index 3347453..86b5bee 100755
--- a/graphics/gmic/PRE_BUILD
+++ b/graphics/gmic/PRE_BUILD
@@ -1,5 +1,3 @@
-default_pre_build &&
+default_pre_build &&
cd ${SOURCE_DIRECTORY} &&
-sedit 's:-lcv -lhighgui:-lopencv_legacy:' configure &&
-patch -p0 < ${SCRIPT_DIRECTORY}/patch-configure &&
-patch -p0 < ${SCRIPT_DIRECTORY}/patch-src_Makefile
+patch -p1 < ${SPELL_DIRECTORY}/opencv-buildfix.patch
diff --git a/graphics/gmic/opencv-buildfix.patch
b/graphics/gmic/opencv-buildfix.patch
new file mode 100644
index 0000000..da32314
--- /dev/null
+++ b/graphics/gmic/opencv-buildfix.patch
@@ -0,0 +1,32 @@
+diff -wbBur gmic-1.5.1.7/src/Makefile gmic-1.5.1.7.q/src/Makefile
+--- gmic-1.5.1.7/src/Makefile 2012-07-26 12:59:34.000000000 +0400
++++ gmic-1.5.1.7.q/src/Makefile 2012-08-03 14:03:10.000000000 +0400
+@@ -296,7 +296,7 @@
+
+ zart: lib
+ ifneq ($(OS),Darwin)
+- cd ../zart && qmake-qt4 zart.pro && $(MAKE) && strip zart
++ cd ../zart && qmake zart.pro && $(MAKE) && strip zart
+ else
+ cd ../zart && qmake zart.pro && $(MAKE) "CFLAGS=$(STD_MACOSX_CFLAGS)
$(OPT_CFLAGS)" "LDFLAGS=$(STD_MACOSX_LDFLAGS) $(OPT_LDFLAGS)"
+ endif
+@@ -403,6 +403,7 @@
+ mkdir -p $(DESTDIR)$(USR)/share/man/fr/man1/
+ cp -f ../man/gmic.1.gz $(DESTDIR)$(USR)/share/man/man1/gmic.1.gz
+ cp -f ../man/gmic.1.gz $(DESTDIR)$(USR)/share/man/fr/man1/gmic.1.gz
++ if test -d /usr/share/bash-completion/completions; then mkdir -p
$(DESTDIR)/usr/share/bash-completion/completions/; cp -f
gmic_bashcompletion.sh $(DESTDIR)/usr/share/bash-completion/completions/gmic;
fi
+ if test -d /etc/bash_completion.d/; then mkdir -p
$(DESTDIR)/etc/bash_completion.d/; cp -f gmic_bashcompletion.sh
$(DESTDIR)/etc/bash_completion.d/gmic; fi
+ if test -d /opt/local/etc/bash_completion.d/; then mkdir -p
$(DESTDIR)/opt/local/etc/bash_completion.d/; cp -f gmic_bashcompletion.sh
$(DESTDIR)/opt/local/etc/bash_completion.d/gmic; fi
+
+diff -wbBur gmic-1.5.1.7/zart/zart.pro gmic-1.5.1.7.q/zart/zart.pro
+--- gmic-1.5.1.7/zart/zart.pro 2012-07-26 12:59:33.000000000 +0400
++++ gmic-1.5.1.7.q/zart/zart.pro 2012-08-03 12:32:27.000000000 +0400
+@@ -34,7 +34,7 @@
+ FORMS = ui/MainWindow.ui ui/DialogAbout.ui ui/DialogLicence.ui
+
+ !macx {
+- LIBS += -lX11 ../src/libgmic.a -lcxcore -lcv -lml -lhighgui -lml
-lfftw3
++ LIBS += -lX11 ../src/libgmic.a `pkg-config --libs opencv`
-lopencv_core -lopencv_ml -lopencv_highgui -lfftw3
+ } else {
+ LIBS += -lX11 ../src/libgmic.a `pkg-config opencv --libs` -lfftw3
+ }
diff --git a/graphics/gmic/patch-configure b/graphics/gmic/patch-configure
deleted file mode 100644
index a74f447..0000000
--- a/graphics/gmic/patch-configure
+++ /dev/null
@@ -1,113 +0,0 @@
-$FreeBSD: ports/graphics/gimp-gmic-plugin/files/patch-configure,v 1.3
2011/09/04 15:59:39 crees Exp $
-
-Unfortunately we can't do the usual patch configure.ac and run autoconf --
the
-tarball doesn't contain the autotools sources ><
-
---- configure.orig 2011-08-23 18:18:22.000000000 +0400
-+++ configure 2011-08-30 22:27:42.000000000 +0400
-@@ -5104,105 +5104,6 @@
-
- fi
-
--{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for cvSobel in -lcv" >&5
--$as_echo_n "checking for cvSobel in -lcv... " >&6; }
--if test "${ac_cv_lib_cv_cvSobel+set}" = set; then :
-- $as_echo_n "(cached) " >&6
--else
-- ac_check_lib_save_LIBS=$LIBS
--LIBS="-lcv $LIBS"
--cat confdefs.h - <<_ACEOF >conftest.$ac_ext
--/* end confdefs.h. */
--
--/* Override any GCC internal prototype to avoid an error.
-- Use char because int might match the return type of a GCC
-- builtin and then its argument prototype would still apply. */
--#ifdef __cplusplus
--extern "C"
--#endif
--char cvSobel ();
--int
--main ()
--{
--return cvSobel ();
-- ;
-- return 0;
--}
--_ACEOF
--if ac_fn_c_try_link "$LINENO"; then :
-- ac_cv_lib_cv_cvSobel=yes
--else
-- ac_cv_lib_cv_cvSobel=no
--fi
--rm -f core conftest.err conftest.$ac_objext \
-- conftest$ac_exeext conftest.$ac_ext
--LIBS=$ac_check_lib_save_LIBS
--fi
--{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cv_cvSobel" >&5
--$as_echo "$ac_cv_lib_cv_cvSobel" >&6; }
--if test "x$ac_cv_lib_cv_cvSobel" = x""yes; then :
-- cat >>confdefs.h <<_ACEOF
--#define HAVE_LIBCV 1
--_ACEOF
--
-- LIBS="-lcv $LIBS"
--
--else
--
-- echo "***"
-- echo "** Fatal Error : Header or library files for 'OpenCV (core)' are
missing but are mandatory to compile G'MIC. **"
-- echo "***"
-- exit -1
--
--fi
--
--{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lhighgui" >&5
--$as_echo_n "checking for main in -lhighgui... " >&6; }
--if test "${ac_cv_lib_highgui_main+set}" = set; then :
-- $as_echo_n "(cached) " >&6
--else
-- ac_check_lib_save_LIBS=$LIBS
--LIBS="-lhighgui $LIBS"
--cat confdefs.h - <<_ACEOF >conftest.$ac_ext
--/* end confdefs.h. */
--
--
--int
--main ()
--{
--return main ();
-- ;
-- return 0;
--}
--_ACEOF
--if ac_fn_c_try_link "$LINENO"; then :
-- ac_cv_lib_highgui_main=yes
--else
-- ac_cv_lib_highgui_main=no
--fi
--rm -f core conftest.err conftest.$ac_objext \
-- conftest$ac_exeext conftest.$ac_ext
--LIBS=$ac_check_lib_save_LIBS
--fi
--{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_highgui_main"
>&5
--$as_echo "$ac_cv_lib_highgui_main" >&6; }
--if test "x$ac_cv_lib_highgui_main" = x""yes; then :
-- cat >>confdefs.h <<_ACEOF
--#define HAVE_LIBHIGHGUI 1
--_ACEOF
--
-- LIBS="-lhighgui $LIBS"
--
--else
--
-- echo "***"
-- echo "** Fatal Error : Header or library files for 'OpenCV (highgui)'
are missing but are mandatory to compile G'MIC. **"
-- echo "***"
-- exit -1
--
--fi
--
--
- # Checks for header files.
- ac_ext=c
- ac_cpp='$CPP $CPPFLAGS'
diff --git a/graphics/gmic/patch-src_Makefile
b/graphics/gmic/patch-src_Makefile
deleted file mode 100644
index c79fcd4..0000000
--- a/graphics/gmic/patch-src_Makefile
+++ /dev/null
@@ -1,56 +0,0 @@
-$FreeBSD: ports/graphics/gimp-gmic-plugin/files/patch-src_Makefile,v 1.3
2011/09/04 15:59:39 crees Exp $
-
---- src/Makefile.orig 2011-08-23 18:18:27.000000000 +0400
-+++ src/Makefile 2011-08-30 22:32:02.000000000 +0400
-@@ -142,15 +142,6 @@
- ZLIB_CFLAGS = -Dcimg_use_zlib
- ZLIB_LDFLAGS = -lz
-
--# Flags to enable native support of webcams, using the OpenCV library.
--OPENCV_CFLAGS = -Dcimg_use_opencv -I$(USR)/include/opencv
--ifeq ($(OS),Darwin)
--OPENCV_LDFLAGS = -lopencv_core -lopencv_highgui # Use this for OpenCV
2.2.0 !
--else
--OPENCV_LDFLAGS = -lcv -lhighgui
--# OPENCV_LDFLAGS = -lopencv_core -lopencv_highgui # Use this for OpenCV
2.2.0 !
--endif
--
- # Flags to enable native support of most classical image file formats,
using the GraphicsMagick++ library.
- MAGICK_CFLAGS = -Dcimg_use_magick -I$(USR)/include/GraphicsMagick
- ifeq ($(OS),Darwin)
-@@ -236,6 +227,14 @@
- $(MAKE) gimp
- $(MAKE) lib
- else
-+ifeq ($(OS),FreeBSD)
-+ @echo "**"
-+ @echo "** FreeBSD configuration"
-+ @echo "**"
-+ $(MAKE) freebsd
-+ $(MAKE) bashcompletion
-+ $(MAKE) gimp
-+else
- ifeq ($(OS),Darwin)
- @echo "**"
- @echo "** MacOSX configuration"
-@@ -252,9 +251,10 @@
- $(MAKE) gimp
- endif
- endif
-+endif
-
- gimp:
-- $(MAKE) "CFLAGS=$(STD_GIMP_CFLAGS) $(OPT_CFLAGS)"
"LDFLAGS+=$(STD_GIMP_LDFLAGS) $(OPT_LDFLAGS)" "STRIP_EXE=1" gmic_gimp
-+ $(MAKE) "CFLAGS+=$(STD_GIMP_CFLAGS)" "LDFLAGS+=$(STD_GIMP_LDFLAGS)"
"STRIP_EXE=1" gmic_gimp
-
- lib:
- $(MAKE) "CFLAGS=$(STD_LIB_CFLAGS) $(OPT_CFLAGS)"
"LDFLAGS+=$(STD_LIB_LDFLAGS)" gmic_lib
-@@ -269,6 +269,9 @@
- linux:
- $(MAKE) "CFLAGS=$(STD_UNIX_CFLAGS) $(OPT_CFLAGS)"
"LDFLAGS=$(STD_UNIX_LDFLAGS)" "STRIP_EXE=1" gmic_gmic
-
-+freebsd:
-+ $(MAKE) "CFLAGS+=$(STD_UNIX_CFLAGS)" "LDFLAGS+=$(STD_UNIX_LDFLAGS)"
"STRIP_EXE=1" gmic_gmic
-+
- custom:
- $(MAKE) "CFLAGS=$(CUST_UNIX_CFLAGS) $(OPT_CFLAGS)"
"LDFLAGS=$(CUST_UNIX_LDFLAGS)" "STRIP_EXE=1" gmic_gmic
diff --git a/graphics/graphicsmagick/DETAILS b/graphics/graphicsmagick/DETAILS
index e953b7e..59ec795 100755
--- a/graphics/graphicsmagick/DETAILS
+++ b/graphics/graphicsmagick/DETAILS
@@ -6,8 +6,8 @@
# SOURCE=GraphicsMagick-${VERSION}.tar.bz2
#
SOURCE_URL[0]=ftp://ftp.${SPELL}.org/pub/GraphicsMagick/snapshots/${SOURCE}
#else
- VERSION=1.3.14
-
SOURCE_HASH=sha512:0755131d088ae5038637c989addbac668f9a0ca742c034938e07326ece6140cbb110b57c06dd1f3291296b9b99e69c9dc8272ebdfb1f772f2dac3a2e8f549cd2
+ VERSION=1.3.16
+
SOURCE_HASH=sha512:c7f08225672f4a070a9dd6dd3a4e43476ab26516e3137bde0cf9c9ff2980444ca1382ec6cddd93491f9f085ed3178d2bbe118f4c69c02251d017dc62eb1be88c
SOURCE=GraphicsMagick-${VERSION}.tar.bz2
SOURCE_URL[0]=ftp://ftp.${SPELL}.org/pub/GraphicsMagick/${SOURCE}
SOURCE_URL[1]=${SOURCEFORGE_URL}/${SPELL}/${SOURCE}
diff --git a/graphics/graphicsmagick/HISTORY b/graphics/graphicsmagick/HISTORY
index b78e788..96a07fc 100644
--- a/graphics/graphicsmagick/HISTORY
+++ b/graphics/graphicsmagick/HISTORY
@@ -1,3 +1,6 @@
+2012-08-07 Ladislav Hagara <hgr AT vabo.cz>
+ * DETAILS: 1.3.16
+
2012-02-26 Ladislav Hagara <hgr AT vabo.cz>
* DETAILS: 1.3.14
diff --git a/kde4-look/oxygen-gtk2/DETAILS b/kde4-look/oxygen-gtk2/DETAILS
index 96938b0..219e715 100755
--- a/kde4-look/oxygen-gtk2/DETAILS
+++ b/kde4-look/oxygen-gtk2/DETAILS
@@ -1,8 +1,8 @@
SPELL=oxygen-gtk2
- VERSION=1.2.5
+ VERSION=1.3.0
SOURCE=${SPELL}-${VERSION}.tar.bz2
SOURCE_URL[0]=$KDE_URL/stable/${SPELL}/${VERSION}/src/${SOURCE}
-
SOURCE_HASH=sha512:9b6968539dbde0ea7ca939166a85e086ba6eed5b6c6e8191109105dba57b4b727fc069256459d96bf2bfac9299d5add8ffbe1a4539ef7e8c2eabbfa7851822f7
+
SOURCE_HASH=sha512:18833fe056e711a99b1f52957e5b1c2e68cd4954b78370b8bccf9d1947e0ce3e0e6d6a0bf764984bea6e6bd89f48e590d6838590339e102cf0f1d118e0ccc253
SOURCE_DIRECTORY="${BUILD_DIRECTORY}/${SPELL}-${VERSION}"
WEB_SITE="http://kde-look.org/content/show.php/?content=136216"
LICENSE[0]=LGPL
diff --git a/kde4-look/oxygen-gtk2/HISTORY b/kde4-look/oxygen-gtk2/HISTORY
index 612de69..ea118c3 100644
--- a/kde4-look/oxygen-gtk2/HISTORY
+++ b/kde4-look/oxygen-gtk2/HISTORY
@@ -1,4 +1,7 @@
-2012-07-17 Julien "_kaze_" ROZO <julien AT rozo.org>
+2012-08-06 Julien "_kaze_" ROZO <julien AT rozo.org>
+ * DETAILS: updated version to 1.3.0
+
+2012-06-07 Julien "_kaze_" ROZO <julien AT rozo.org>
* DETAILS: updated version to 1.2.5
2012-06-07 Julien "_kaze_" ROZO <julien AT rozo.org>
diff --git a/kde4-look/oxygen-gtk3/DETAILS b/kde4-look/oxygen-gtk3/DETAILS
index 14c03e9..8f9fe23 100755
--- a/kde4-look/oxygen-gtk3/DETAILS
+++ b/kde4-look/oxygen-gtk3/DETAILS
@@ -1,8 +1,8 @@
SPELL=oxygen-gtk3
- VERSION=1.0.5
+ VERSION=1.1.0
SOURCE="${SPELL}-${VERSION}.tar.bz2"
SOURCE_URL[0]=$KDE_URL/stable/${SPELL}/${VERSION}/src/${SOURCE}
-
SOURCE_HASH=sha512:d0afd8cd30a8a3dbf7cf9f253f185c7e9f14fe2b6ebffe818396ec692235202910149130a745c55a3b83b8863212edce6abef28575abfaddf2af40e201c14daa
+
SOURCE_HASH=sha512:6524c2dd6c5792bb386a25f6bb9bd6f1c92d600392f70ad83e5f8031dbf1f9b66e8ac1d7ffaf9e2ed9aa92fcb440dd394808fc34e4b2908841947b35a48236cb
SOURCE_DIRECTORY="${BUILD_DIRECTORY}/${SPELL}-${VERSION}"
WEB_SITE="http://kde-look.org/content/show.php/?content=136216"
LICENSE[0]=LGPL
diff --git a/kde4-look/oxygen-gtk3/HISTORY b/kde4-look/oxygen-gtk3/HISTORY
index 38ea5aa..a4d0a65 100644
--- a/kde4-look/oxygen-gtk3/HISTORY
+++ b/kde4-look/oxygen-gtk3/HISTORY
@@ -1,3 +1,6 @@
+2012-08-06 Julien "_kaze_" ROZO <julien AT rozo.org>
+ * DETAILS: updated version to 1.1.0
+
2012-07-17 Julien "_kaze_" ROZO <julien AT rozo.org>
* DETAILS: updated version to 1.0.5
diff --git a/libs/nspr/DETAILS b/libs/nspr/DETAILS
index d0f2f76..1b55775 100755
--- a/libs/nspr/DETAILS
+++ b/libs/nspr/DETAILS
@@ -1,11 +1,11 @@
SPELL=nspr
- VERSION=4.9.1
+ VERSION=4.9.2
SOURCE=$SPELL-$VERSION.tar.gz
SOURCE_DIRECTORY="$BUILD_DIRECTORY/$SPELL-$VERSION"
SOURCE_URL[0]=http://ftp.mozilla.org/pub/mozilla.org/nspr/releases/v$VERSION/src/$SOURCE
WEB_SITE=http://www.mozilla.org/projects/nspr/
ENTERED=20050512
-
SOURCE_HASH=sha512:b7613eb5f97d9d8d0254d454fb516a672664fbf46b34eb03cc51a9b3af11d8cbdc117691c068f8e64a8255aadfd28b2814eda53edcd97a643b26b94b5adec341
+
SOURCE_HASH=sha512:1f1f35fc2b9ead7e3b4ef93a02f13c0bcccc314bf9cfad67e6ddb755aaf6ab411499b0b57b94b032e2c7ee21fc7c114ca447e24825b79611f720f88eb37bd348
# SOURCE_GPG=gurus.gpg:$SOURCE.sig:WORKS_FOR_ME
LICENSE[0]=MPL
GATHER_DOCS=no
diff --git a/libs/nspr/HISTORY b/libs/nspr/HISTORY
index 17308ed..e43c2f5 100644
--- a/libs/nspr/HISTORY
+++ b/libs/nspr/HISTORY
@@ -1,3 +1,6 @@
+2012-08-07 Ladislav Hagara <hgr AT vabo.cz>
+ * DETAILS: 4.9.2
+
2012-06-05 Ladislav Hagara <hgr AT vabo.cz>
* DETAILS: 4.9.1
diff --git a/net/openntpd/BUILD b/net/openntpd/BUILD
index a125806..6384556 100755
--- a/net/openntpd/BUILD
+++ b/net/openntpd/BUILD
@@ -1,3 +1,7 @@
create_account ntp &&
-OPTS="$OPTS --with-privsep-user=ntp" &&
+
+OPTS="--with-privsep-user=ntp \
+ --with-adjtimex \
+ $OPTS" &&
+
default_build
diff --git a/net/openntpd/DETAILS b/net/openntpd/DETAILS
index 9f1b3eb..75aa94c 100755
--- a/net/openntpd/DETAILS
+++ b/net/openntpd/DETAILS
@@ -1,5 +1,6 @@
SPELL=openntpd
VERSION=3.9p1
+ PATCHLEVEL=1
SOURCE_HASH=sha512:e19e7242b67c8d12fbf0a78cd29dae4248afff5b5308069b190b663a9f9426666aad20f8c9ec70fabf8d2e5c2a2e61052191fe4ccc132c62a7decd8c498c2a13
SOURCE=$SPELL-$VERSION.tar.gz
SOURCE_URL[0]=ftp://ftp.openbsd.org/pub/OpenBSD/OpenNTPD/$SOURCE
diff --git a/net/openntpd/HISTORY b/net/openntpd/HISTORY
index 7c7df60..5ab26b3 100644
--- a/net/openntpd/HISTORY
+++ b/net/openntpd/HISTORY
@@ -1,3 +1,9 @@
+2012-08-07 Vlad Glagolev <stealth AT sourcemage.org>
+ * DETAILS: PATCHLEVEL=1
+ * BUILD: apply adjtimex flag, readbility++
+ * PRE_BUILD: added, to apply the patch
+ * linux-adjtimex.patch: added, to fix time sync on modern systems
+
2008-09-29 Elisamuel Resto <ryuji AT sourcemage.org>
* DETAILS: added 4 mirrors
diff --git a/net/openntpd/PRE_BUILD b/net/openntpd/PRE_BUILD
new file mode 100755
index 0000000..7c4bd48
--- /dev/null
+++ b/net/openntpd/PRE_BUILD
@@ -0,0 +1,4 @@
+default_pre_build &&
+cd "$SOURCE_DIRECTORY" &&
+
+patch -p1 < "$SPELL_DIRECTORY/linux-adjtimex.patch"
diff --git a/net/openntpd/linux-adjtimex.patch
b/net/openntpd/linux-adjtimex.patch
new file mode 100644
index 0000000..e7b72da
--- /dev/null
+++ b/net/openntpd/linux-adjtimex.patch
@@ -0,0 +1,168 @@
+Only in openntpd-3.9p1.old: configure
+diff -ur --unidirectional-new-file openntpd-3.9p1.old/configure.ac
openntpd-3.9p1/configure.ac
+--- openntpd-3.9p1.old/configure.ac 2006-05-14 07:29:23.000000000 +0200
++++ openntpd-3.9p1/configure.ac 2008-02-07 13:13:18.066366142 +0100
+@@ -583,6 +583,11 @@
+ [ builtin_arc4random=$withval ]
+ )
+
++AC_ARG_WITH(adjtimex,
++ [ --with-adjtimex Use adjtimex to adjust kernel
skew],
++ [ AC_DEFINE(USE_ADJTIMEX, [], [Use adjust skew with adjtimex
(experimental)]) ]
++ )
++
+ AC_ARG_WITH(mantype,
+ [ --with-mantype=man|cat|doc Set man page type],
+ [
+diff -ur --unidirectional-new-file openntpd-3.9p1.old/defines.h
openntpd-3.9p1/defines.h
+--- openntpd-3.9p1.old/defines.h 2006-05-14 07:29:21.000000000 +0200
++++ openntpd-3.9p1/defines.h 2008-02-07 13:14:34.488711868 +0100
+@@ -20,6 +20,10 @@
+ # define setproctitle(x)
+ #endif
+
++#ifdef USE_ADJTIMEX
++# define adjtime(a,b) (_compat_adjtime((a),(b)))
++#endif
++
+ #if !defined(SA_LEN)
+ # if defined(HAVE_STRUCT_SOCKADDR_SA_LEN)
+ # define SA_LEN(x) ((x)->sa_len)
+Only in openntpd-3.9p1.old: ntpd.0
+Only in openntpd-3.9p1.old: ntpd.conf.0
+diff -ur --unidirectional-new-file
openntpd-3.9p1.old/openbsd-compat/Makefile.in
openntpd-3.9p1/openbsd-compat/Makefile.in
+--- openntpd-3.9p1.old/openbsd-compat/Makefile.in 2006-05-14
07:29:19.000000000 +0200
++++ openntpd-3.9p1/openbsd-compat/Makefile.in 2008-02-07 13:31:39.499728930
+0100
+@@ -9,7 +9,7 @@
+ COMPAT= atomicio.o bsd-arc4random.o bsd-misc.o bsd-poll.o \
+ bsd-snprintf.o bsd-getifaddrs.o bsd-setresuid.o \
+ bsd-setresgid.o fake-rfc2553.o
+-PORT= port-qnx.o
++PORT= port-linux.o port-qnx.o
+
+ VPATH=@srcdir@
+ CC=@CC@
+diff -ur --unidirectional-new-file
openntpd-3.9p1.old/openbsd-compat/openbsd-compat.h
openntpd-3.9p1/openbsd-compat/openbsd-compat.h
+--- openntpd-3.9p1.old/openbsd-compat/openbsd-compat.h 2006-05-14
07:29:19.000000000 +0200
++++ openntpd-3.9p1/openbsd-compat/openbsd-compat.h 2008-02-07
13:17:00.272366764 +0100
+@@ -46,6 +46,11 @@
+ __attribute__((__format__ (printf, 2, 3)));
+ #endif
+
++#ifdef USE_ADJTIMEX
++# include <sys/time.h>
++int _compat_adjtime(const struct timeval *, struct timeval *);
++#endif
++
+ #ifndef HAVE_INET_PTON
+ int inet_pton(int, const char *, void *);
+ #endif
+diff -ur --unidirectional-new-file
openntpd-3.9p1.old/openbsd-compat/port-linux.c
openntpd-3.9p1/openbsd-compat/port-linux.c
+--- openntpd-3.9p1.old/openbsd-compat/port-linux.c 1970-01-01
01:00:00.000000000 +0100
++++ openntpd-3.9p1/openbsd-compat/port-linux.c 2008-02-07 13:24:43.800366563
+0100
+@@ -0,0 +1,105 @@
++
++
++/*
++ * Copyright (c) 2004 Darren Tucker <dtucker at zip com au>
++ *
++ * Permission to use, copy, modify, and distribute this software for any
++ * purpose with or without fee is hereby granted, provided that the above
++ * copyright notice and this permission notice appear in all copies.
++ *
++ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
++ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
++ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
++ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
++ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
++ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
++ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
++ */
++
++#include "includes.h"
++
++#ifdef USE_ADJTIMEX
++#include <sys/timex.h>
++#include <errno.h>
++#ifdef adjtime
++# undef adjtime
++#endif
++
++#include "ntpd.h"
++
++/* scale factor used by adjtimex freq param. 1 ppm = 65536 */
++#define ADJTIMEX_FREQ_SCALE 65536
++
++/* maximum change to skew per adjustment, in PPM */
++#define MAX_SKEW_DELTA 5.0
++
++int
++_compat_adjtime(const struct timeval *delta, struct timeval *olddelta)
++{
++ static struct timeval tlast = {0,0};
++ static double tskew = 0;
++ static int synced = -1;
++ struct timeval tnow, tdelta;
++ double skew = 0, newskew, deltaskew, adjust, interval = 0;
++ struct timex tmx;
++ int result, saved_errno;
++
++ gettimeofday(&tnow, NULL);
++ adjust = (double)delta->tv_sec;
++ adjust += (double)delta->tv_usec / 1000000;
++
++ /* Even if the caller doesn't care about the olddelta, we do */
++ if (olddelta == NULL)
++ olddelta = &tdelta;
++
++ result = adjtime(delta, olddelta);
++ saved_errno = errno;
++
++ if (olddelta->tv_sec == 0 && olddelta->tv_usec == 0 &&
++ synced != INT_MAX)
++ synced++;
++ else
++ synced = 0;
++
++ /*
++ * do skew calculations if we have synced
++ */
++ if (synced == 0 ) {
++ tmx.modes = 0;
++ if (adjtimex(&tmx) == -1)
++ log_warn("adjtimex get failed");
++ else
++ tskew = (double)tmx.freq / ADJTIMEX_FREQ_SCALE;
++ } else if (synced >= 1) {
++ interval = (double)(tnow.tv_sec - tlast.tv_sec);
++ interval += (double)(tnow.tv_usec - tlast.tv_usec) / 1000000;
++
++ skew = (adjust * 1000000) / interval;
++ newskew = ((tskew * synced) + skew) / synced;
++ deltaskew = newskew - tskew;
++
++ if (deltaskew > MAX_SKEW_DELTA) {
++ log_info("skew change %0.3lf exceeds limit",
deltaskew);
++ tskew += MAX_SKEW_DELTA;
++ } else if (deltaskew < -MAX_SKEW_DELTA) {
++ log_info("skew change %0.3lf exceeds limit",
deltaskew);
++ tskew -= MAX_SKEW_DELTA;
++ } else {
++ tskew = newskew;
++ }
++
++ /* Adjust the kernel skew. */
++ tmx.freq = (long)(tskew * ADJTIMEX_FREQ_SCALE);
++ tmx.modes = ADJ_FREQUENCY;
++ if (adjtimex(&tmx) == -1)
++ log_warn("adjtimex set freq failed");
++ }
++
++ log_debug("interval %0.3lf skew %0.3lf total skew %0.3lf", interval,
++ skew, tskew);
++
++ tlast = tnow;
++ errno = saved_errno;
++ return result;
++}
++#endif
diff --git a/printer/pycups/DETAILS b/printer/pycups/DETAILS
index cfe3353..c628cc7 100755
--- a/printer/pycups/DETAILS
+++ b/printer/pycups/DETAILS
@@ -1,11 +1,11 @@
SPELL=pycups
- VERSION=1.9.61
-
SOURCE_HASH=sha512:fa30fd6089426d15ee2994772b7969371da290c1eebfb0894fe3039cfb3fd92df216b4d7546ca3be9c8cde88b65846f14a03d39e63d9ea474a469f933aee1752
+ VERSION=1.9.62
+
SOURCE_HASH=sha512:2a988d403e828b5210d5e88a136adbaa626bd978d151b734371386a08a3bfac7258b1ea83913b55a62dd12ca60c0cdd60a0eebafd0505b264ffbfc80a190247d
SOURCE=$SPELL-$VERSION.tar.bz2
- SOURCE2=$SOURCE.asc
+ SOURCE2=$SOURCE.sig
SOURCE_DIRECTORY=$BUILD_DIRECTORY/$SPELL-$VERSION
SOURCE_URL[0]=http://cyberelk.net/tim/data/pycups/$SOURCE
- SOURCE2_URL[0]=${SOURCE_URL[0]}.asc
+ SOURCE2_URL[0]=${SOURCE_URL[0]}.sig
# SOURCE_GPG=timwaugh.gpg:$SOURCE.asc:UPSTREAM_KEY
SOURCE2_IGNORE=signature
WEB_SITE=http://cyberelk.net/tim/software/pycups/
diff --git a/printer/pycups/HISTORY b/printer/pycups/HISTORY
index d5f8580..92b7b3e 100644
--- a/printer/pycups/HISTORY
+++ b/printer/pycups/HISTORY
@@ -1,3 +1,7 @@
+2012-08-07 Ladislav Hagara <hgr AT vabo.cz>
+ * DETAILS: 1.9.62, asc -> sig
+ * PRE_BUILD, pycups-1.9.61-cups-1.6.patch: patch removed, fixed
upstream
+
2012-07-31 Sukneet Basuta <sukneet AT sourcemage.org>
* PRE_BUILD: apply patch to fix compatibility with cups 1.6
* pycups-1.9.61-cups-1.6.patch: from upstream git, fixes pycups for
cups 1.6
diff --git a/printer/pycups/PRE_BUILD b/printer/pycups/PRE_BUILD
index e59d434..a682ab3 100755
--- a/printer/pycups/PRE_BUILD
+++ b/printer/pycups/PRE_BUILD
@@ -1,5 +1,4 @@
default_pre_build &&
cd $SOURCE_DIRECTORY &&
-sed -i 's:mv build/lib:ln -sf build/lib:' $SOURCE_DIRECTORY/Makefile &&
-patch -p1 < $SPELL_DIRECTORY/pycups-1.9.61-cups-1.6.patch
+sed -i 's:mv build/lib:ln -sf build/lib:' $SOURCE_DIRECTORY/Makefile
diff --git a/printer/pycups/pycups-1.9.61-cups-1.6.patch
b/printer/pycups/pycups-1.9.61-cups-1.6.patch
deleted file mode 100644
index 705a713..0000000
--- a/printer/pycups/pycups-1.9.61-cups-1.6.patch
+++ /dev/null
@@ -1,1675 +0,0 @@
-From fd985079fd7075cfc7148918bd48eeafa143cf6b Mon Sep 17 00:00:00 2001
-From: Jiri Popelka <jpopelka AT redhat.com>
-Date: Wed, 11 Jul 2012 12:00:41 +0200
-Subject: [PATCH] Use ippGet/ippSet (accessors) for IPP API.
-
-CUPS 1.6 makes various structures private and
-introduces these ippGet and ippSet functions
-for all of the fields in these structures.
-http://www.cups.org/str.php?L3928
-
-We define (same signatures) our own accessors
-when CUPS < 1.6.
----
- cupsconnection.c | 579
+++++++++++++++++++++++++++--------------------------
- cupsipp.c | 46 +++---
- cupsmodule.c | 136 +++++++++++++
- cupsmodule.h | 28 +++
- 4 files changed, 482 insertions(+), 307 deletions(-)
-
-diff --git a/cupsconnection.c b/cupsconnection.c
-index 93305f0..5c9d1a5 100644
---- a/cupsconnection.c
-+++ b/cupsconnection.c
-@@ -477,10 +477,10 @@ do_printer_request (Connection *self, PyObject *args,
PyObject *kwds,
- return NULL;
- }
-
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-- cupsLastError ());
-+ ippGetStatusCode (answer) :
-+ cupsLastError ());
- if (answer)
- ippDelete (answer);
- debugprintf("<- do_printer_request (error)\n");
-@@ -562,7 +562,11 @@ PyObject_from_attr_value (ipp_attribute_t *attr, int i)
- {
- PyObject *val = NULL;
- char unknown[100];
-- switch (attr->value_tag) {
-+ int lower, upper;
-+ int xres, yres;
-+ ipp_res_t units;
-+
-+ switch (ippGetValueTag(attr)) {
- case IPP_TAG_NAME:
- case IPP_TAG_TEXT:
- case IPP_TAG_KEYWORD:
-@@ -570,19 +574,20 @@ PyObject_from_attr_value (ipp_attribute_t *attr, int i)
- case IPP_TAG_CHARSET:
- case IPP_TAG_MIMETYPE:
- case IPP_TAG_LANGUAGE:
-- val = PyObj_from_UTF8 (attr->values[i].string.text);
-+ val = PyObj_from_UTF8 (ippGetString (attr, i, NULL));
- break;
- case IPP_TAG_INTEGER:
- case IPP_TAG_ENUM:
-- val = PyInt_FromLong (attr->values[i].integer);
-+ val = PyInt_FromLong (ippGetInteger (attr, i));
- break;
- case IPP_TAG_BOOLEAN:
-- val = PyBool_FromLong (attr->values[i].integer);
-+ val = PyBool_FromLong (ippGetInteger (attr, i));
- break;
- case IPP_TAG_RANGE:
-+ lower = ippGetRange (attr, i, &upper);
- val = Py_BuildValue ("(ii)",
-- attr->values[i].range.lower,
-- attr->values[i].range.upper);
-+ lower,
-+ upper);
- break;
- case IPP_TAG_NOVALUE:
- Py_INCREF (Py_None);
-@@ -594,14 +599,15 @@ PyObject_from_attr_value (ipp_attribute_t *attr, int i)
- val = PyString_FromString ("(IPP_TAG_DATE)");
- break;
- case IPP_TAG_RESOLUTION:
-+ xres = ippGetResolution(attr, i, &yres, &units);
- val = Py_BuildValue ("(iii)",
-- attr->values[i].resolution.xres,
-- attr->values[i].resolution.yres,
-- attr->values[i].resolution.units);
-+ xres,
-+ yres,
-+ units);
- break;
- default:
- snprintf (unknown, sizeof (unknown),
-- "(unknown IPP value tag 0x%x)", attr->value_tag);
-+ "(unknown IPP value tag 0x%x)", ippGetValueTag(attr));
- val = PyString_FromString (unknown);
- break;
- }
-@@ -615,7 +621,7 @@ PyList_from_attr_values (ipp_attribute_t *attr)
- PyObject *list = PyList_New (0);
- int i;
- debugprintf ("-> PyList_from_attr_values()\n");
-- for (i = 0; i < attr->num_values; i++) {
-+ for (i = 0; i < ippGetCount (attr); i++) {
- PyObject *val = PyObject_from_attr_value (attr, i);
- if (val) {
- PyList_Append (list, val);
-@@ -657,8 +663,8 @@ Connection_getPrinters (Connection *self)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-- if (answer && answer->request.status.status_code == IPP_NOT_FOUND) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_FOUND) {
- // No printers.
- debugprintf ("<- Connection_getPrinters() = {} (no printers)\n");
- ippDelete (answer);
-@@ -666,7 +672,7 @@ Connection_getPrinters (Connection *self)
- }
-
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -675,71 +681,71 @@ Connection_getPrinters (Connection *self)
- }
-
- result = PyDict_New ();
-- for (attr = answer->attrs; attr; attr = attr->next) {
-+ for (attr = ippFirstAttribute (answer); attr; attr = ippNextAttribute
(answer)) {
- PyObject *dict;
- char *printer = NULL;
-
-- while (attr && attr->group_tag != IPP_TAG_PRINTER)
-- attr = attr->next;
-+ while (attr && ippGetGroupTag (attr) != IPP_TAG_PRINTER)
-+ attr = ippNextAttribute (answer);
-
- if (!attr)
- break;
-
- dict = PyDict_New ();
-- for (; attr && attr->group_tag == IPP_TAG_PRINTER;
-- attr = attr->next) {
-+ for (; attr && ippGetGroupTag (attr) == IPP_TAG_PRINTER;
-+ attr = ippNextAttribute (answer)) {
- PyObject *val = NULL;
-
-- debugprintf ("Attribute: %s\n", attr->name);
-- if (!strcmp (attr->name, "printer-name") &&
-- attr->value_tag == IPP_TAG_NAME)
-- printer = attr->values[0].string.text;
-- else if ((!strcmp (attr->name, "printer-type") ||
-- !strcmp (attr->name, "printer-state")) &&
-- attr->value_tag == IPP_TAG_ENUM) {
-- int ptype = attr->values[0].integer;
-+ debugprintf ("Attribute: %s\n", ippGetName (attr));
-+ if (!strcmp (ippGetName (attr), "printer-name") &&
-+ ippGetValueTag (attr) == IPP_TAG_NAME)
-+ printer = (char *) ippGetString (attr, 0, NULL);
-+ else if ((!strcmp (ippGetName (attr), "printer-type") ||
-+ !strcmp (ippGetName (attr), "printer-state")) &&
-+ ippGetValueTag (attr) == IPP_TAG_ENUM) {
-+ int ptype = ippGetInteger (attr, 0);
- val = PyInt_FromLong (ptype);
- }
-- else if ((!strcmp (attr->name,
-+ else if ((!strcmp (ippGetName (attr),
- "printer-make-and-model") ||
-- !strcmp (attr->name, "printer-info") ||
-- !strcmp (attr->name, "printer-location") ||
-- !strcmp (attr->name, "printer-state-message")) &&
-- attr->value_tag == IPP_TAG_TEXT) {
-- val = PyObj_from_UTF8 (attr->values[0].string.text);
-+ !strcmp (ippGetName (attr), "printer-info") ||
-+ !strcmp (ippGetName (attr), "printer-location") ||
-+ !strcmp (ippGetName (attr), "printer-state-message")) &&
-+ ippGetValueTag (attr) == IPP_TAG_TEXT) {
-+ val = PyObj_from_UTF8 (ippGetString (attr, 0, NULL));
- }
-- else if (!strcmp (attr->name,
-+ else if (!strcmp (ippGetName (attr),
- "printer-state-reasons") &&
-- attr->value_tag == IPP_TAG_KEYWORD) {
-+ ippGetValueTag (attr) == IPP_TAG_KEYWORD) {
- val = PyList_from_attr_values (attr);
- }
-- else if (!strcmp (attr->name,
-+ else if (!strcmp (ippGetName (attr),
- "printer-is-accepting-jobs") &&
-- attr->value_tag == IPP_TAG_BOOLEAN) {
-- int b = attr->values[0].boolean;
-+ ippGetValueTag (attr) == IPP_TAG_BOOLEAN) {
-+ int b = ippGetBoolean (attr, 0);
- val = PyInt_FromLong (b);
- }
-- else if ((!strcmp (attr->name,
-+ else if ((!strcmp (ippGetName (attr),
- "printer-up-time") ||
-- !strcmp (attr->name,
-+ !strcmp (ippGetName (attr),
- "queued-job-count")) &&
-- attr->value_tag == IPP_TAG_INTEGER) {
-- int u = attr->values[0].integer;
-+ ippGetValueTag (attr) == IPP_TAG_INTEGER) {
-+ int u = ippGetInteger (attr, 0);
- val = PyInt_FromLong (u);
- }
-- else if ((!strcmp (attr->name, "device-uri") ||
-- !strcmp (attr->name, "printer-uri-supported")) &&
-- attr->value_tag == IPP_TAG_URI) {
-- val = PyObj_from_UTF8 (attr->values[0].string.text);
-+ else if ((!strcmp (ippGetName (attr), "device-uri") ||
-+ !strcmp (ippGetName (attr), "printer-uri-supported")) &&
-+ ippGetValueTag (attr) == IPP_TAG_URI) {
-+ val = PyObj_from_UTF8 (ippGetString (attr, 0, NULL));
- }
-- else if (!strcmp (attr->name, "printer-is-shared") &&
-- attr->value_tag == IPP_TAG_BOOLEAN) {
-- val = PyBool_FromLong (attr->values[0].boolean);
-+ else if (!strcmp (ippGetName (attr), "printer-is-shared") &&
-+ ippGetValueTag (attr) == IPP_TAG_BOOLEAN) {
-+ val = PyBool_FromLong (ippGetBoolean (attr, 0));
- }
-
- if (val) {
-- debugprintf ("Added %s to dict\n", attr->name);
-- PyDict_SetItemString (dict, attr->name, val);
-+ debugprintf ("Added %s to dict\n", ippGetName (attr));
-+ PyDict_SetItemString (dict, ippGetName (attr), val);
- Py_DECREF (val);
- }
- }
-@@ -780,8 +786,8 @@ Connection_getClasses (Connection *self)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-- if (answer && answer->request.status.status_code == IPP_NOT_FOUND) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_FOUND) {
- // No classes.
- debugprintf ("<- Connection_getClasses() = {} (no classes)\n");
- ippDelete (answer);
-@@ -789,7 +795,7 @@ Connection_getClasses (Connection *self)
- }
-
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -798,28 +804,28 @@ Connection_getClasses (Connection *self)
- }
-
- result = PyDict_New ();
-- for (attr = answer->attrs; attr; attr = attr->next) {
-+ for (attr = ippFirstAttribute (answer); attr; attr = ippNextAttribute
(answer)) {
- PyObject *members = NULL;
- char *classname = NULL;
- char *printer_uri = NULL;
-
-- while (attr && attr->group_tag != IPP_TAG_PRINTER)
-- attr = attr->next;
-+ while (attr && ippGetGroupTag (attr) != IPP_TAG_PRINTER)
-+ attr = ippNextAttribute (answer);
-
- if (!attr)
- break;
-
-- for (; attr && attr->group_tag == IPP_TAG_PRINTER;
-- attr = attr->next) {
-- debugprintf ("Attribute: %s\n", attr->name);
-- if (!strcmp (attr->name, "printer-name") &&
-- attr->value_tag == IPP_TAG_NAME)
-- classname = attr->values[0].string.text;
-- else if (!strcmp (attr->name, "printer-uri-supported") &&
-- attr->value_tag == IPP_TAG_URI)
-- printer_uri = attr->values[0].string.text;
-- else if (!strcmp (attr->name, "member-names") &&
-- attr->value_tag == IPP_TAG_NAME) {
-+ for (; attr && ippGetGroupTag (attr) == IPP_TAG_PRINTER;
-+ attr = ippNextAttribute (answer)) {
-+ debugprintf ("Attribute: %s\n", ippGetName (attr));
-+ if (!strcmp (ippGetName (attr), "printer-name") &&
-+ ippGetValueTag (attr) == IPP_TAG_NAME)
-+ classname = (char *) ippGetString (attr, 0, NULL);
-+ else if (!strcmp (ippGetName (attr), "printer-uri-supported") &&
-+ ippGetValueTag (attr) == IPP_TAG_URI)
-+ printer_uri = (char *) ippGetString (attr, 0, NULL);
-+ else if (!strcmp (ippGetName (attr), "member-names") &&
-+ ippGetValueTag (attr) == IPP_TAG_NAME) {
- Py_XDECREF (members);
- members = PyList_from_attr_values (attr);
- }
-@@ -1057,9 +1063,9 @@ do_getPPDs (Connection *self, PyObject *args, PyObject
*kwds, int all_lists)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -1068,24 +1074,24 @@ do_getPPDs (Connection *self, PyObject *args,
PyObject *kwds, int all_lists)
- }
-
- result = PyDict_New ();
-- for (attr = answer->attrs; attr; attr = attr->next) {
-+ for (attr = ippFirstAttribute (answer); attr; attr = ippNextAttribute
(answer)) {
- PyObject *dict;
- char *ppdname = NULL;
-
-- while (attr && attr->group_tag != IPP_TAG_PRINTER)
-- attr = attr->next;
-+ while (attr && ippGetGroupTag (attr) != IPP_TAG_PRINTER)
-+ attr = ippNextAttribute (answer);
-
- if (!attr)
- break;
-
- dict = PyDict_New ();
-- for (; attr && attr->group_tag == IPP_TAG_PRINTER;
-- attr = attr->next) {
-+ for (; attr && ippGetGroupTag (attr) == IPP_TAG_PRINTER;
-+ attr = ippNextAttribute (answer)) {
- PyObject *val = NULL;
-- debugprintf ("Attribute: %s\n", attr->name);
-- if (!strcmp (attr->name, "ppd-name") &&
-- attr->value_tag == IPP_TAG_NAME)
-- ppdname = attr->values[0].string.text;
-+ debugprintf ("Attribute: %s\n", ippGetName (attr));
-+ if (!strcmp (ippGetName (attr), "ppd-name") &&
-+ ippGetValueTag (attr) == IPP_TAG_NAME)
-+ ppdname = (char *) ippGetString (attr, 0, NULL);
- else {
- if (all_lists)
- val = PyList_from_attr_values (attr);
-@@ -1093,8 +1099,8 @@ do_getPPDs (Connection *self, PyObject *args, PyObject
*kwds, int all_lists)
- val = PyObject_from_attr_value (attr, 0);
-
- if (val) {
-- debugprintf ("Adding %s to ppd dict\n", attr->name);
-- PyDict_SetItemString (dict, attr->name, val);
-+ debugprintf ("Adding %s to ppd dict\n", ippGetName (attr));
-+ PyDict_SetItemString (dict, ippGetName (attr), val);
- Py_DECREF (val);
- }
- }
-@@ -1201,10 +1207,10 @@ Connection_getDocument (Connection *self, PyObject
*args)
- Connection_end_allow_threads (self);
-
- close (fd);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- unlink (docfilename);
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -1214,11 +1220,11 @@ Connection_getDocument (Connection *self, PyObject
*args)
-
- if ((attr = ippFindAttribute (answer, "document-format",
- IPP_TAG_MIMETYPE)) != NULL)
-- format = attr->values[0].string.text;
-+ format = ippGetString (attr, 0, NULL);
-
- if ((attr = ippFindAttribute (answer, "document-name",
- IPP_TAG_NAME)) != NULL)
-- name = attr->values[0].string.text;
-+ name = ippGetString (attr, 0, NULL);
-
- dict = PyDict_New ();
-
-@@ -1362,9 +1368,9 @@ Connection_getDevices (Connection *self, PyObject
*args, PyObject *kwds)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -1373,31 +1379,31 @@ Connection_getDevices (Connection *self, PyObject
*args, PyObject *kwds)
- }
-
- result = PyDict_New ();
-- for (attr = answer->attrs; attr; attr = attr->next) {
-+ for (attr = ippFirstAttribute (answer); attr; attr = ippNextAttribute
(answer)) {
- PyObject *dict;
- char *device_uri = NULL;
-
-- while (attr && attr->group_tag != IPP_TAG_PRINTER)
-- attr = attr->next;
-+ while (attr && ippGetGroupTag (attr) != IPP_TAG_PRINTER)
-+ attr = ippNextAttribute (answer);
-
- if (!attr)
- break;
-
- dict = PyDict_New ();
-- for (; attr && attr->group_tag == IPP_TAG_PRINTER;
-- attr = attr->next) {
-+ for (; attr && ippGetGroupTag (attr) == IPP_TAG_PRINTER;
-+ attr = ippNextAttribute (answer)) {
- PyObject *val = NULL;
-
-- debugprintf ("Attribute: %s\n", attr->name);
-- if (!strcmp (attr->name, "device-uri") &&
-- attr->value_tag == IPP_TAG_URI)
-- device_uri = attr->values[0].string.text;
-+ debugprintf ("Attribute: %s\n", ippGetName (attr));
-+ if (!strcmp (ippGetName (attr), "device-uri") &&
-+ ippGetValueTag (attr) == IPP_TAG_URI)
-+ device_uri = (char *) ippGetString (attr, 0, NULL);
- else
- val = PyObject_from_attr_value (attr, 0);
-
- if (val) {
-- debugprintf ("Adding %s to device dict\n", attr->name);
-- PyDict_SetItemString (dict, attr->name, val);
-+ debugprintf ("Adding %s to device dict\n", ippGetName (attr));
-+ PyDict_SetItemString (dict, ippGetName (attr), val);
- Py_DECREF (val);
- }
- }
-@@ -1523,9 +1529,9 @@ Connection_getJobs (Connection *self, PyObject *args,
PyObject *kwds)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -1534,56 +1540,56 @@ Connection_getJobs (Connection *self, PyObject
*args, PyObject *kwds)
- }
-
- result = PyDict_New ();
-- for (attr = answer->attrs; attr; attr = attr->next) {
-+ for (attr = ippFirstAttribute (answer); attr; attr = ippNextAttribute
(answer)) {
- PyObject *dict;
- int job_id = -1;
-
-- while (attr && attr->group_tag != IPP_TAG_JOB)
-- attr = attr->next;
-+ while (attr && ippGetGroupTag (attr) != IPP_TAG_JOB)
-+ attr = ippNextAttribute (answer);
-
- if (!attr)
- break;
-
- dict = PyDict_New ();
-- for (; attr && attr->group_tag == IPP_TAG_JOB;
-- attr = attr->next) {
-+ for (; attr && ippGetGroupTag (attr) == IPP_TAG_JOB;
-+ attr = ippNextAttribute (answer)) {
- PyObject *val = NULL;
-
-- debugprintf ("Attribute: %s\n", attr->name);
-- if (!strcmp (attr->name, "job-id") &&
-- attr->value_tag == IPP_TAG_INTEGER)
-- job_id = attr->values[0].integer;
-- else if (((!strcmp (attr->name, "job-k-octets") ||
-- !strcmp (attr->name, "job-priority") ||
-- !strcmp (attr->name, "time-at-creation") ||
-- !strcmp (attr->name, "time-at-processing") ||
-- !strcmp (attr->name, "time-at-completed") ||
-- !strcmp (attr->name, "job-media-sheets") ||
-- !strcmp (attr->name, "job-media-sheets-completed")) &&
-- attr->value_tag == IPP_TAG_INTEGER) ||
-- (!strcmp (attr->name, "job-state") &&
-- attr->value_tag == IPP_TAG_ENUM))
-- val = PyInt_FromLong (attr->values[0].integer);
-- else if ((!strcmp (attr->name, "job-name") &&
-- attr->value_tag == IPP_TAG_NAME) ||
-- (!strcmp (attr->name, "job-originating-user-name") &&
-- attr->value_tag == IPP_TAG_NAME) ||
-- (!strcmp (attr->name, "job-printer-uri") &&
-- attr->value_tag == IPP_TAG_URI))
-- val = PyObj_from_UTF8 (attr->values[0].string.text);
-- else if (!strcmp (attr->name, "job-preserved") &&
-- attr->value_tag == IPP_TAG_BOOLEAN)
-- val = PyBool_FromLong (attr->values[0].integer);
-+ debugprintf ("Attribute: %s\n", ippGetName (attr));
-+ if (!strcmp (ippGetName (attr), "job-id") &&
-+ ippGetValueTag (attr) == IPP_TAG_INTEGER)
-+ job_id = ippGetInteger (attr, 0);
-+ else if (((!strcmp (ippGetName (attr), "job-k-octets") ||
-+ !strcmp (ippGetName (attr), "job-priority") ||
-+ !strcmp (ippGetName (attr), "time-at-creation") ||
-+ !strcmp (ippGetName (attr), "time-at-processing") ||
-+ !strcmp (ippGetName (attr), "time-at-completed") ||
-+ !strcmp (ippGetName (attr), "job-media-sheets") ||
-+ !strcmp (ippGetName (attr), "job-media-sheets-completed")) &&
-+ ippGetValueTag (attr) == IPP_TAG_INTEGER) ||
-+ (!strcmp (ippGetName (attr), "job-state") &&
-+ ippGetValueTag (attr) == IPP_TAG_ENUM))
-+ val = PyInt_FromLong (ippGetInteger (attr, 0));
-+ else if ((!strcmp (ippGetName (attr), "job-name") &&
-+ ippGetValueTag (attr) == IPP_TAG_NAME) ||
-+ (!strcmp (ippGetName (attr), "job-originating-user-name") &&
-+ ippGetValueTag (attr) == IPP_TAG_NAME) ||
-+ (!strcmp (ippGetName (attr), "job-printer-uri") &&
-+ ippGetValueTag (attr) == IPP_TAG_URI))
-+ val = PyObj_from_UTF8 (ippGetString (attr, 0, NULL));
-+ else if (!strcmp (ippGetName (attr), "job-preserved") &&
-+ ippGetValueTag (attr) == IPP_TAG_BOOLEAN)
-+ val = PyBool_FromLong (ippGetInteger (attr, 0));
- else {
-- if (attr->num_values > 1)
-+ if (ippGetCount (attr) > 1)
- val = PyList_from_attr_values (attr);
- else
- val = PyObject_from_attr_value (attr, 0);
- }
-
- if (val) {
-- debugprintf ("Adding %s to job dict\n", attr->name);
-- PyDict_SetItemString (dict, attr->name, val);
-+ debugprintf ("Adding %s to job dict\n", ippGetName (attr));
-+ PyDict_SetItemString (dict, ippGetName (attr), val);
- Py_DECREF (val);
- }
- }
-@@ -1643,9 +1649,9 @@ Connection_getJobAttributes (Connection *self,
PyObject *args, PyObject *kwds)
- Connection_end_allow_threads (self);
- if (requested_attrs)
- free_requested_attrs (n_attrs, attrs);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -1654,12 +1660,12 @@ Connection_getJobAttributes (Connection *self,
PyObject *args, PyObject *kwds)
- }
-
- result = PyDict_New ();
-- for (attr = answer->attrs; attr; attr = attr->next) {
-+ for (attr = ippFirstAttribute (answer); attr; attr = ippNextAttribute
(answer)) {
- PyObject *obj;
-
-- debugprintf ("Attr: %s\n", attr->name);
-- if (attr->num_values > 1 ||
-- !strcmp (attr->name, "job-printer-state-reasons"))
-+ debugprintf ("Attr: %s\n", ippGetName (attr));
-+ if (ippGetCount (attr) > 1 ||
-+ !strcmp (ippGetName (attr), "job-printer-state-reasons"))
- obj = PyList_from_attr_values (attr);
- else
- obj = PyObject_from_attr_value (attr, 0);
-@@ -1668,7 +1674,7 @@ Connection_getJobAttributes (Connection *self,
PyObject *args, PyObject *kwds)
- // Can't represent this.
- continue;
-
-- PyDict_SetItemString (result, attr->name, obj);
-+ PyDict_SetItemString (result, ippGetName (attr), obj);
- Py_DECREF (obj);
- }
-
-@@ -1701,9 +1707,9 @@ Connection_cancelJob (Connection *self, PyObject
*args, PyObject *kwds)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/jobs/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -1774,7 +1780,7 @@ Connection_cancelAllJobs (Connection *self, PyObject
*args, PyObject *kwds)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/admin/");
- Connection_end_allow_threads (self);
-- if (answer && answer->request.status.status_code == IPP_NOT_POSSIBLE) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_POSSIBLE) {
- ippDelete (answer);
- if (uriobj)
- break;
-@@ -1790,9 +1796,9 @@ Connection_cancelAllJobs (Connection *self, PyObject
*args, PyObject *kwds)
- if (uriobj)
- free (uri);
-
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -1864,9 +1870,9 @@ Connection_moveJob (Connection *self, PyObject *args,
PyObject *kwds)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/jobs");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -1931,9 +1937,9 @@ Connection_authenticateJob (Connection *self, PyObject
*args)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/jobs/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -1977,9 +1983,9 @@ Connection_setJobHoldUntil (Connection *self, PyObject
*args)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/jobs/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -2017,9 +2023,9 @@ Connection_restartJob (Connection *self, PyObject
*args, PyObject *kwds)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/jobs/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -2314,9 +2320,9 @@ Connection_addPrinter (Connection *self, PyObject
*args, PyObject *kwds)
- return NULL;
- }
-
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -2364,9 +2370,9 @@ Connection_setPrinterDevice (Connection *self,
PyObject *args)
- return NULL;
- }
-
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -2411,7 +2417,7 @@ Connection_setPrinterInfo (Connection *self, PyObject
*args)
- return NULL;
- }
-
-- if (answer && answer->request.status.status_code == IPP_NOT_POSSIBLE) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_POSSIBLE) {
- // Perhaps it's a class, not a printer.
- ippDelete (answer);
- request = add_modify_class_request (name);
-@@ -2420,9 +2426,9 @@ Connection_setPrinterInfo (Connection *self, PyObject
*args)
-
- free (name);
- free (info);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -2467,7 +2473,7 @@ Connection_setPrinterLocation (Connection *self,
PyObject *args)
- return NULL;
- }
-
-- if (answer && answer->request.status.status_code == IPP_NOT_POSSIBLE) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_POSSIBLE) {
- // Perhaps it's a class, not a printer.
- ippDelete (answer);
- request = add_modify_class_request (name);
-@@ -2476,9 +2482,9 @@ Connection_setPrinterLocation (Connection *self,
PyObject *args)
-
- free (name);
- free (location);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -2516,7 +2522,7 @@ Connection_setPrinterShared (Connection *self,
PyObject *args)
- return NULL;
- }
-
-- if (answer && answer->request.status.status_code == IPP_NOT_POSSIBLE) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_POSSIBLE) {
- // Perhaps it's a class, not a printer.
- ippDelete (answer);
- request = add_modify_class_request (name);
-@@ -2524,9 +2530,9 @@ Connection_setPrinterShared (Connection *self,
PyObject *args)
- }
-
- free (name);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -2571,8 +2577,8 @@ Connection_setPrinterJobSheets (Connection *self,
PyObject *args)
- for (i = 0; i < 2; i++) {
- a = ippAddStrings (request, IPP_TAG_PRINTER, IPP_TAG_NAME,
- "job-sheets-default", 2, NULL, NULL);
-- a->values[0].string.text = strdup (start);
-- a->values[1].string.text = strdup (end);
-+ ippSetString(request, &a, 0, strdup (start));
-+ ippSetString(request, &a, 1, strdup (end));
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/admin/");
- Connection_end_allow_threads (self);
-@@ -2582,7 +2588,7 @@ Connection_setPrinterJobSheets (Connection *self,
PyObject *args)
- return NULL;
- }
-
-- if (answer && answer->request.status.status_code == IPP_NOT_POSSIBLE) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_POSSIBLE) {
- ippDelete (answer);
- // Perhaps it's a class, not a printer.
- request = add_modify_class_request (name);
-@@ -2592,9 +2598,9 @@ Connection_setPrinterJobSheets (Connection *self,
PyObject *args)
- free (name);
- free (start);
- free (end);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -2639,7 +2645,7 @@ Connection_setPrinterErrorPolicy (Connection *self,
PyObject *args)
- return NULL;
- }
-
-- if (answer && answer->request.status.status_code == IPP_NOT_POSSIBLE) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_POSSIBLE) {
- ippDelete (answer);
- // Perhaps it's a class, not a printer.
- request = add_modify_class_request (name);
-@@ -2648,9 +2654,9 @@ Connection_setPrinterErrorPolicy (Connection *self,
PyObject *args)
-
- free (name);
- free (policy);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -2695,7 +2701,7 @@ Connection_setPrinterOpPolicy (Connection *self,
PyObject *args)
- return NULL;
- }
-
-- if (answer && answer->request.status.status_code == IPP_NOT_POSSIBLE) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_POSSIBLE) {
- ippDelete (answer);
- // Perhaps it's a class, not a printer.
- request = add_modify_class_request (name);
-@@ -2704,9 +2710,9 @@ Connection_setPrinterOpPolicy (Connection *self,
PyObject *args)
-
- free (name);
- free (policy);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -2750,21 +2756,21 @@ do_requesting_user_names (Connection *self, PyObject
*args,
- int k;
- PyErr_SetString (PyExc_TypeError, "String required");
- for (k = 0; k < j; k++) {
-- free (attr->values[k].string.text);
-- attr->values[k].string.text = NULL;
-+ free ((void *)ippGetString (attr, k, NULL));
-+ ippSetString(request, &attr, k, NULL);
- }
- ippDelete (request);
- return NULL;
- }
-- attr->values[j].string.text = strdup (PyString_AsString (username));
-+ ippSetString(request, &attr, j, strdup (PyString_AsString
(username)));
- }
- } else {
- attr = ippAddStrings (request, IPP_TAG_PRINTER, IPP_TAG_NAME,
- requeststr, 1, NULL, NULL);
- if (strstr (requeststr, "denied"))
-- attr->values[0].string.text = strdup ("none");
-+ ippSetString(request, &attr, 0, strdup ("none"));
- else
-- attr->values[0].string.text = strdup ("all");
-+ ippSetString(request, &attr, 0, strdup ("all"));
- }
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/admin/");
-@@ -2775,7 +2781,7 @@ do_requesting_user_names (Connection *self, PyObject
*args,
- return NULL;
- }
-
-- if (answer && answer->request.status.status_code == IPP_NOT_POSSIBLE) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_POSSIBLE) {
- ippDelete (answer);
- // Perhaps it's a class, not a printer.
- request = add_modify_class_request (name);
-@@ -2783,9 +2789,9 @@ do_requesting_user_names (Connection *self, PyObject
*args,
- }
-
- free (name);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -2872,7 +2878,7 @@ Connection_addPrinterOptionDefault (Connection *self,
PyObject *args)
- opt, len, NULL, NULL);
- for (j = 0; j < len; j++) {
- PyObject *each = PySequence_GetItem (pyvalue, j);
-- attr->values[j].string.text = PyObject_to_string (each);
-+ ippSetString(request, &attr, j, PyObject_to_string (each));
- }
- } else
- ippAddString (request, IPP_TAG_PRINTER, IPP_TAG_NAME,
-@@ -2887,7 +2893,7 @@ Connection_addPrinterOptionDefault (Connection *self,
PyObject *args)
- return NULL;
- }
-
-- if (answer && answer->request.status.status_code == IPP_NOT_POSSIBLE) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_POSSIBLE) {
- ippDelete (answer);
- // Perhaps it's a class, not a printer.
- request = add_modify_class_request (name);
-@@ -2896,9 +2902,9 @@ Connection_addPrinterOptionDefault (Connection *self,
PyObject *args)
-
- free (name);
- free (option);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -2950,7 +2956,7 @@ Connection_deletePrinterOptionDefault (Connection
*self, PyObject *args)
- return NULL;
- }
-
-- if (answer && answer->request.status.status_code == IPP_NOT_POSSIBLE) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_POSSIBLE) {
- ippDelete (answer);
- // Perhaps it's a class, not a printer.
- request = add_modify_class_request (name);
-@@ -2959,9 +2965,9 @@ Connection_deletePrinterOptionDefault (Connection
*self, PyObject *args)
-
- free (name);
- free (option);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -3048,7 +3054,7 @@ Connection_getPrinterAttributes (Connection *self,
PyObject *args,
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/");
- Connection_end_allow_threads (self);
-- if (answer && answer->request.status.status_code == IPP_NOT_POSSIBLE) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_POSSIBLE) {
- ippDelete (answer);
- if (uriobj)
- break;
-@@ -3067,9 +3073,9 @@ Connection_getPrinterAttributes (Connection *self,
PyObject *args,
- if (requested_attrs)
- free_requested_attrs (n_attrs, attrs);
-
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -3079,28 +3085,28 @@ Connection_getPrinterAttributes (Connection *self,
PyObject *args,
- }
-
- ret = PyDict_New ();
-- for (attr = answer->attrs; attr; attr = attr->next) {
-- while (attr && attr->group_tag != IPP_TAG_PRINTER)
-- attr = attr->next;
-+ for (attr = ippFirstAttribute (answer); attr; attr = ippNextAttribute
(answer)) {
-+ while (attr && ippGetGroupTag (attr) != IPP_TAG_PRINTER)
-+ attr = ippNextAttribute (answer);
-
- if (!attr)
- break;
-
-- for (; attr && attr->group_tag == IPP_TAG_PRINTER;
-- attr = attr->next) {
-- size_t namelen = strlen (attr->name);
-- int is_list = attr->num_values > 1;
-+ for (; attr && ippGetGroupTag (attr) == IPP_TAG_PRINTER;
-+ attr = ippNextAttribute (answer)) {
-+ size_t namelen = strlen (ippGetName (attr));
-+ int is_list = ippGetCount (attr) > 1;
-
-- debugprintf ("Attribute: %s\n", attr->name);
-+ debugprintf ("Attribute: %s\n", ippGetName (attr));
- // job-sheets-default is special, since it is always two values.
- // Make it a tuple.
-- if (!strcmp (attr->name, "job-sheets-default") &&
-- attr->value_tag == IPP_TAG_NAME) {
-+ if (!strcmp (ippGetName (attr), "job-sheets-default") &&
-+ ippGetValueTag (attr) == IPP_TAG_NAME) {
- PyObject *startobj, *endobj, *tuple;
- const char *start, *end;
-- start = attr->values[0].string.text;
-- if (attr->num_values >= 2)
-- end = attr->values[1].string.text;
-+ start = ippGetString (attr, 0, NULL);
-+ if (ippGetCount (attr) >= 2)
-+ end = ippGetString (attr, 1, NULL);
- else
- end = "";
-
-@@ -3134,7 +3140,7 @@ Connection_getPrinterAttributes (Connection *self,
PyObject *args,
- NULL
- };
-
-- switch (attr->value_tag) {
-+ switch (ippGetValueTag (attr)) {
- case IPP_TAG_NAME:
- case IPP_TAG_TEXT:
- case IPP_TAG_KEYWORD:
-@@ -3145,12 +3151,12 @@ Connection_getPrinterAttributes (Connection *self,
PyObject *args,
- case IPP_TAG_ENUM:
- case IPP_TAG_INTEGER:
- case IPP_TAG_RESOLUTION:
-- is_list = !strcmp (attr->name + namelen - 10, "-supported");
-+ is_list = !strcmp (ippGetName (attr) + namelen - 10, "-supported");
-
- if (!is_list) {
- const char **opt;
- for (opt = multivalue_options; !is_list && *opt; opt++)
-- is_list = !strcmp (attr->name, *opt);
-+ is_list = !strcmp (ippGetName (attr), *opt);
- }
-
- default:
-@@ -3160,11 +3166,11 @@ Connection_getPrinterAttributes (Connection *self,
PyObject *args,
-
- if (is_list) {
- PyObject *list = PyList_from_attr_values (attr);
-- PyDict_SetItemString (ret, attr->name, list);
-+ PyDict_SetItemString (ret, ippGetName (attr), list);
- Py_DECREF (list);
- } else {
- PyObject *val = PyObject_from_attr_value (attr, i);
-- PyDict_SetItemString (ret, attr->name, val);
-+ PyDict_SetItemString (ret, ippGetName (attr), val);
- }
- }
-
-@@ -3213,8 +3219,8 @@ Connection_addPrinterToClass (Connection *self,
PyObject *args)
- printers = ippFindAttribute (answer, "member-names", IPP_TAG_NAME);
- if (printers) {
- int i;
-- for (i = 0; i < printers->num_values; i++) {
-- if (!strcasecmp (printers->values[i].string.text, printername)) {
-+ for (i = 0; i < ippGetCount (printers); i++) {
-+ if (!strcasecmp (ippGetString (printers, i, NULL), printername)) {
- ippDelete (answer);
- PyErr_SetString (PyExc_RuntimeError, "Printer already in class");
- free (printername);
-@@ -3237,11 +3243,13 @@ Connection_addPrinterToClass (Connection *self,
PyObject *args)
- ipp_attribute_t *attr;
- int i;
- attr = ippAddStrings (request, IPP_TAG_PRINTER, IPP_TAG_URI,
-- "member-uris", printers->num_values + 1,
-+ "member-uris", ippGetCount (printers) + 1,
- NULL, NULL);
-- for (i = 0; i < printers->num_values; i++)
-- attr->values[i].string.text = strdup
(printers->values[i].string.text);
-- attr->values[printers->num_values].string.text = strdup (printeruri);
-+ for (i = 0; i < ippGetCount (printers); i++)
-+ ippSetString(request, &attr, i,
-+ strdup (ippGetString (printers, i, NULL)));
-+ ippSetString(request, &attr, ippGetCount (printers), strdup
(printeruri));
-+
- }
-
- ippDelete (answer);
-@@ -3261,9 +3269,9 @@ Connection_addPrinterToClass (Connection *self,
PyObject *args)
- return NULL;
- }
-
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -3322,19 +3330,19 @@ Connection_deletePrinterFromClass (Connection *self,
PyObject *args)
- }
-
- printers = ippFindAttribute (answer, "member-names", IPP_TAG_NAME);
-- for (i = 0; printers && i < printers->num_values; i++)
-- if (!strcasecmp (printers->values[i].string.text, printername))
-+ for (i = 0; printers && i < ippGetCount (printers); i++)
-+ if (!strcasecmp (ippGetString (printers, i, NULL), printername))
- break;
-
- free (printername);
-- if (!printers || i == printers->num_values) {
-+ if (!printers || i == ippGetCount (printers)) {
- ippDelete (answer);
- PyErr_SetString (PyExc_RuntimeError, "Printer not in class");
- return NULL;
- }
-
- printers = ippFindAttribute (answer, "member-uris", IPP_TAG_URI);
-- if (!printers || i >= printers->num_values) {
-+ if (!printers || i >= ippGetCount (printers)) {
- ippDelete (answer);
- PyErr_SetString (PyExc_RuntimeError, "No member URIs returned");
- return NULL;
-@@ -3345,21 +3353,21 @@ Connection_deletePrinterFromClass (Connection *self,
PyObject *args)
- "printer-uri", NULL, classuri);
-
- // Only printer in class? Delete the class.
-- if (printers->num_values == 1)
-- request->request.op.operation_id = CUPS_DELETE_CLASS;
-+ if (ippGetCount (printers) == 1)
-+ ippSetOperation (request, CUPS_DELETE_CLASS);
- else {
- // Trim the printer from the list.
- ipp_attribute_t *newlist;
- int j;
- newlist = ippAddStrings (request, IPP_TAG_PRINTER, IPP_TAG_URI,
-- "member-uris", printers->num_values - 1,
-+ "member-uris", ippGetCount (printers) - 1,
- NULL, NULL);
- for (j = 0; j < i; j++)
-- newlist->values[j].string.text =
-- strdup (printers->values[j].string.text);
-- for (j = i; j < newlist->num_values; j++)
-- newlist->values[j].string.text =
-- strdup (printers->values[j + 1].string.text);
-+ ippSetString(request, &newlist, j,
-+ strdup (ippGetString (printers, j, NULL)));
-+ for (j = i; j < ippGetCount(newlist); j++)
-+ ippSetString(request, &newlist, j,
-+ strdup (ippGetString (printers, j+1, NULL)));
- }
-
- ippDelete (answer);
-@@ -3372,9 +3380,9 @@ Connection_deletePrinterFromClass (Connection *self,
PyObject *args)
- return NULL;
- }
-
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -3408,9 +3416,9 @@ Connection_deleteClass (Connection *self, PyObject
*args)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/admin/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -3698,7 +3706,7 @@ Connection_printTestPage (Connection *self, PyObject
*args, PyObject *kwds)
- Connection_begin_allow_threads (self);
- answer = cupsDoFileRequest (self->http, request, resource, file);
- Connection_end_allow_threads (self);
-- if (answer && answer->request.status.status_code == IPP_NOT_POSSIBLE) {
-+ if (answer && ippGetStatusCode (answer) == IPP_NOT_POSSIBLE) {
- ippDelete (answer);
- // Perhaps it's a class, not a printer.
- snprintf (uri, sizeof (uri), "ipp://localhost/classes/%s", printer);
-@@ -3715,9 +3723,9 @@ Connection_printTestPage (Connection *self, PyObject
*args, PyObject *kwds)
- if (userobj)
- free (user);
-
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
- set_ipp_error (answer ?
-- answer->request.status.status_code :
-+ ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -3726,7 +3734,7 @@ Connection_printTestPage (Connection *self, PyObject
*args, PyObject *kwds)
-
- attr = ippFindAttribute (answer, "job-id", IPP_TAG_INTEGER);
- if (attr)
-- jobid = attr->values[0].integer;
-+ jobid = ippGetInteger (attr, 0);
-
- ippDelete (answer);
- return Py_BuildValue ("i", jobid);
-@@ -3922,8 +3930,8 @@ Connection_getSubscriptions (Connection *self,
PyObject *args, PyObject *kwds)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-- set_ipp_error (answer ? answer->request.status.status_code :
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
-+ set_ipp_error (answer ? ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -3932,14 +3940,14 @@ Connection_getSubscriptions (Connection *self,
PyObject *args, PyObject *kwds)
- }
-
- result = PyList_New (0);
-- for (attr = answer->attrs; attr; attr = attr->next)
-- if (attr->group_tag == IPP_TAG_SUBSCRIPTION)
-+ for (attr = ippFirstAttribute (answer); attr; attr = ippNextAttribute
(answer))
-+ if (ippGetGroupTag (attr) == IPP_TAG_SUBSCRIPTION)
- break;
-
- subscription = NULL;
-- for (; attr; attr = attr->next) {
-+ for (; attr; attr = ippNextAttribute (answer)) {
- PyObject *obj;
-- if (attr->group_tag == IPP_TAG_ZERO) {
-+ if (ippGetGroupTag (attr) == IPP_TAG_ZERO) {
- // End of subscription.
- if (subscription) {
- PyList_Append (result, subscription);
-@@ -3950,7 +3958,7 @@ Connection_getSubscriptions (Connection *self,
PyObject *args, PyObject *kwds)
- continue;
- }
-
-- if (attr->num_values > 1 || !strcmp (attr->name, "notify-events"))
-+ if (ippGetCount (attr) > 1 || !strcmp (ippGetName (attr),
"notify-events"))
- obj = PyList_from_attr_values (attr);
- else
- obj = PyObject_from_attr_value (attr, 0);
-@@ -3962,7 +3970,7 @@ Connection_getSubscriptions (Connection *self,
PyObject *args, PyObject *kwds)
- if (!subscription)
- subscription = PyDict_New ();
-
-- PyDict_SetItemString (subscription, attr->name, obj);
-+ PyDict_SetItemString (subscription, ippGetName (attr), obj);
- Py_DECREF (obj);
- }
-
-@@ -4060,7 +4068,8 @@ Connection_createSubscription (Connection *self,
PyObject *args,
- n, NULL, NULL);
- for (i = 0; i < n; i++) {
- PyObject *event = PyList_GetItem (events, i);
-- attr->values[i].string.text = strdup (PyString_AsString (event));
-+ //attr->values[i].string.text = strdup (PyString_AsString (event));
-+ ippSetString(request, &attr, i, strdup (PyString_AsString (event)));
- }
- }
-
-@@ -4079,8 +4088,8 @@ Connection_createSubscription (Connection *self,
PyObject *args,
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-- set_ipp_error (answer ? answer->request.status.status_code :
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
-+ set_ipp_error (answer ? ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -4089,14 +4098,14 @@ Connection_createSubscription (Connection *self,
PyObject *args,
- }
-
- i = -1;
-- for (attr = answer->attrs; attr; attr = attr->next) {
-- if (attr->group_tag == IPP_TAG_SUBSCRIPTION) {
-- if (attr->value_tag == IPP_TAG_INTEGER &&
-- !strcmp (attr->name, "notify-subscription-id"))
-- i = attr->values[0].integer;
-- else if (attr->value_tag == IPP_TAG_ENUM &&
-- !strcmp (attr->name, "notify-status-code"))
-- debugprintf ("notify-status-code = %d\n", attr->values[0].integer);
-+ for (attr = ippFirstAttribute (answer); attr; attr = ippNextAttribute
(answer)) {
-+ if (ippGetGroupTag (attr) == IPP_TAG_SUBSCRIPTION) {
-+ if (ippGetValueTag (attr) == IPP_TAG_INTEGER &&
-+ !strcmp (ippGetName (attr), "notify-subscription-id"))
-+ i = ippGetInteger (attr, 0);
-+ else if (ippGetValueTag (attr) == IPP_TAG_ENUM &&
-+ !strcmp (ippGetName (attr), "notify-status-code"))
-+ debugprintf ("notify-status-code = %d\n", ippGetInteger (attr, 0));
- }
- }
-
-@@ -4162,7 +4171,8 @@ Connection_getNotifications (Connection *self,
PyObject *args, PyObject *kwds)
- "notify-subscription-ids", num_ids, NULL);
- for (i = 0; i < num_ids; i++) {
- PyObject *id = PyList_GetItem (subscription_ids, i);
-- attr->values[i].integer = PyInt_AsLong (id);
-+ //attr->values[i].integer = PyInt_AsLong (id);
-+ ippSetInteger (request, &attr, i, PyInt_AsLong (id));
- }
-
- if (sequence_numbers) {
-@@ -4170,15 +4180,16 @@ Connection_getNotifications (Connection *self,
PyObject *args, PyObject *kwds)
- "notify-sequence-numbers", num_seqs, NULL);
- for (i = 0; i < num_seqs; i++) {
- PyObject *num = PyList_GetItem (sequence_numbers, i);
-- attr->values[i].integer = PyInt_AsLong (num);
-+ //attr->values[i].integer = PyInt_AsLong (num);
-+ ippSetInteger (request, &attr, i, PyInt_AsLong (num));
- }
- }
-
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-- set_ipp_error (answer ? answer->request.status.status_code :
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
-+ set_ipp_error (answer ? ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -4191,27 +4202,27 @@ Connection_getNotifications (Connection *self,
PyObject *args, PyObject *kwds)
- // Result-wide attributes.
- attr = ippFindAttribute (answer, "notify-get-interval", IPP_TAG_INTEGER);
- if (attr) {
-- PyObject *val = PyInt_FromLong (attr->values[0].integer);
-- PyDict_SetItemString (result, attr->name, val);
-+ PyObject *val = PyInt_FromLong (ippGetInteger (attr, 0));
-+ PyDict_SetItemString (result, ippGetName (attr), val);
- Py_DECREF (val);
- }
-
- attr = ippFindAttribute (answer, "printer-up-time", IPP_TAG_INTEGER);
- if (attr) {
-- PyObject *val = PyInt_FromLong (attr->values[0].integer);
-- PyDict_SetItemString (result, attr->name, val);
-+ PyObject *val = PyInt_FromLong (ippGetInteger (attr, 0));
-+ PyDict_SetItemString (result, ippGetName (attr), val);
- Py_DECREF (val);
- }
-
- events = PyList_New (0);
-- for (attr = answer->attrs; attr; attr = attr->next)
-- if (attr->group_tag == IPP_TAG_EVENT_NOTIFICATION)
-+ for (attr = ippFirstAttribute (answer); attr; attr = ippNextAttribute
(answer))
-+ if (ippGetGroupTag (attr) == IPP_TAG_EVENT_NOTIFICATION)
- break;
-
- event = NULL;
-- for (; attr; attr = attr->next) {
-+ for (; attr; attr = ippNextAttribute (answer)) {
- PyObject *obj;
-- if (attr->group_tag == IPP_TAG_ZERO) {
-+ if (ippGetGroupTag (attr) == IPP_TAG_ZERO) {
- // End of event notification.
- if (event) {
- PyList_Append (events, event);
-@@ -4222,10 +4233,10 @@ Connection_getNotifications (Connection *self,
PyObject *args, PyObject *kwds)
- continue;
- }
-
-- if (attr->num_values > 1 ||
-- !strcmp (attr->name, "notify-events") ||
-- !strcmp (attr->name, "printer-state-reasons") ||
-- !strcmp (attr->name, "job-printer-state-reasons"))
-+ if (ippGetCount (attr) > 1 ||
-+ !strcmp (ippGetName (attr), "notify-events") ||
-+ !strcmp (ippGetName (attr), "printer-state-reasons") ||
-+ !strcmp (ippGetName (attr), "job-printer-state-reasons"))
- obj = PyList_from_attr_values (attr);
- else
- obj = PyObject_from_attr_value (attr, 0);
-@@ -4237,7 +4248,7 @@ Connection_getNotifications (Connection *self,
PyObject *args, PyObject *kwds)
- if (!event)
- event = PyDict_New ();
-
-- PyDict_SetItemString (event, attr->name, obj);
-+ PyDict_SetItemString (event, ippGetName (attr), obj);
- Py_DECREF (obj);
- }
-
-@@ -4281,8 +4292,8 @@ Connection_renewSubscription (Connection *self,
PyObject *args, PyObject *kwds)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-- set_ipp_error (answer ? answer->request.status.status_code :
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
-+ set_ipp_error (answer ? ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-@@ -4316,8 +4327,8 @@ Connection_cancelSubscription (Connection *self,
PyObject *args)
- Connection_begin_allow_threads (self);
- answer = cupsDoRequest (self->http, request, "/");
- Connection_end_allow_threads (self);
-- if (!answer || answer->request.status.status_code > IPP_OK_CONFLICT) {
-- set_ipp_error (answer ? answer->request.status.status_code :
-+ if (!answer || ippGetStatusCode (answer) > IPP_OK_CONFLICT) {
-+ set_ipp_error (answer ? ippGetStatusCode (answer) :
- cupsLastError ());
- if (answer)
- ippDelete (answer);
-diff --git a/cupsipp.c b/cupsipp.c
-index 16bf8c8..ac34004 100644
---- a/cupsipp.c
-+++ b/cupsipp.c
-@@ -370,18 +370,18 @@ IPPRequest_getAttributes (IPPRequest *self, void
*closure)
- {
- PyObject *attrs = PyList_New (0);
- ipp_attribute_t *attr;
-- for (attr = self->ipp->attrs; attr; attr = attr->next)
-+ for (attr = ippFirstAttribute (self->ipp); attr; attr =
ippNextAttribute(self->ipp))
- {
- PyObject *largs = NULL;
- PyObject *lkwlist = NULL;
- PyObject *values = NULL;
- IPPAttribute *attribute = NULL;
-
-- debugprintf ("%s: ", attr->name);
-- if (attr->value_tag == IPP_TAG_ZERO ||
-- attr->value_tag == IPP_TAG_NOVALUE ||
-- attr->value_tag == IPP_TAG_NOTSETTABLE ||
-- attr->value_tag == IPP_TAG_ADMINDEFINE) {
-+ debugprintf ("%s: ", ippGetName (attr));
-+ if (ippGetValueTag (attr) == IPP_TAG_ZERO ||
-+ ippGetValueTag (attr) == IPP_TAG_NOVALUE ||
-+ ippGetValueTag (attr) == IPP_TAG_NOTSETTABLE ||
-+ ippGetValueTag (attr) == IPP_TAG_ADMINDEFINE) {
- debugprintf ("no value\n");
- } else {
- PyObject *value = NULL;
-@@ -392,25 +392,25 @@ IPPRequest_getAttributes (IPPRequest *self, void
*closure)
- if (!values)
- goto fail_add;
-
-- for (i = 0; i < attr->num_values; i++) {
-- switch (attr->value_tag) {
-+ for (i = 0; i < ippGetCount (attr); i++) {
-+ switch (ippGetValueTag (attr)) {
- case IPP_TAG_INTEGER:
- case IPP_TAG_ENUM:
- case IPP_TAG_RANGE:
-- value = PyInt_FromLong (attr->values[i].integer);
-- debugprintf ("i%d", attr->values[i].integer);
-+ value = PyInt_FromLong (ippGetInteger (attr, i));
-+ debugprintf ("i%d", ippGetInteger (attr, i));
- break;
-
- case IPP_TAG_BOOLEAN:
-- value = PyBool_FromLong (attr->values[i].boolean);
-- debugprintf ("b%d", attr->values[i].integer);
-+ value = PyBool_FromLong (ippGetBoolean (attr, i));
-+ debugprintf ("b%d", ippGetInteger (attr, i));
- break;
-
- case IPP_TAG_TEXT:
-- value = PyUnicode_Decode (attr->values[i].string.text,
-- strlen (attr->values[i].string.text),
-+ value = PyUnicode_Decode (ippGetString (attr, i, NULL),
-+ strlen (ippGetString (attr, i, NULL)),
- "utf-8", NULL);
-- debugprintf ("u%s", attr->values[i].string.text);
-+ debugprintf ("u%s", ippGetString (attr, i, NULL));
- break;
-
- case IPP_TAG_NAME:
-@@ -419,14 +419,14 @@ IPPRequest_getAttributes (IPPRequest *self, void
*closure)
- case IPP_TAG_MIMETYPE:
- case IPP_TAG_CHARSET:
- case IPP_TAG_LANGUAGE:
-- value = PyString_FromString (attr->values[i].string.text);
-- debugprintf ("s%s", attr->values[i].string.text);
-+ value = PyString_FromString (ippGetString (attr, i, NULL));
-+ debugprintf ("s%s", ippGetString (attr, i, NULL));
- break;
-
- default:
- value = NULL;
- unknown_value_tag = 1;
-- debugprintf ("Unable to encode value tag %d\n", attr->value_tag);
-+ debugprintf ("Unable to encode value tag %d\n", ippGetValueTag
(attr));
- }
-
- if (!value)
-@@ -458,15 +458,15 @@ IPPRequest_getAttributes (IPPRequest *self, void
*closure)
-
- if (values) {
- largs = Py_BuildValue ("(iisO)",
-- attr->group_tag,
-- attr->value_tag,
-- attr->name,
-+ ippGetGroupTag (attr),
-+ ippGetValueTag (attr),
-+ ippGetName (attr),
- values);
- Py_DECREF (values);
- values = NULL;
- } else
-- largs = Py_BuildValue ("(iis)", attr->group_tag, attr->value_tag,
-- attr->name ? attr->name : "");
-+ largs = Py_BuildValue ("(iis)", ippGetGroupTag (attr), ippGetValueTag
(attr),
-+ ippGetName (attr) ? ippGetName (attr) : "");
-
- if (!largs)
- goto fail_add;
-diff --git a/cupsmodule.c b/cupsmodule.c
-index 005ee23..1aba77d 100644
---- a/cupsmodule.c
-+++ b/cupsmodule.c
-@@ -52,6 +52,10 @@ static pthread_once_t tls_key_once = PTHREAD_ONCE_INIT;
- # define IPP_PKI_ERROR 0x1001
- #endif /* CUPS < 1.5 */
-
-+#if (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR > 5)
-+# define CUPS_SERVER_REMOTE_PRINTERS "_remote_printers"
-+#endif /* CUPS > 1.5 */
-+
- //////////////////////
- // Worker functions //
- //////////////////////
-@@ -203,6 +207,138 @@ do_password_callback (const char *prompt)
- }
- #endif /* !HAVE_CUPS_1_4 */
-
-+#ifndef HAVE_CUPS_1_6
-+int
-+ippGetBoolean(ipp_attribute_t *attr,
-+ int element)
-+{
-+ return (attr->values[element].boolean);
-+}
-+
-+int
-+ippGetCount(ipp_attribute_t *attr)
-+{
-+ return (attr->num_values);
-+}
-+
-+ipp_tag_t
-+ippGetGroupTag(ipp_attribute_t *attr)
-+{
-+ return (attr->group_tag);
-+}
-+
-+int
-+ippGetInteger(ipp_attribute_t *attr,
-+ int element)
-+{
-+ return (attr->values[element].integer);
-+}
-+
-+const char *
-+ippGetName(ipp_attribute_t *attr)
-+{
-+ return (attr->name);
-+}
-+
-+ipp_op_t
-+ippGetOperation(ipp_t *ipp)
-+{
-+ return (ipp->request.op.operation_id);
-+}
-+
-+int
-+ippGetRange(ipp_attribute_t *attr,
-+ int element,
-+ int *uppervalue)
-+{
-+ if (uppervalue)
-+ *uppervalue = attr->values[element].range.upper;
-+
-+ return (attr->values[element].range.lower);
-+}
-+
-+int
-+ippGetResolution(
-+ ipp_attribute_t *attr,
-+ int element,
-+ int *yres,
-+ ipp_res_t *units)
-+{
-+ if (yres)
-+ *yres = attr->values[element].resolution.yres;
-+
-+ if (units)
-+ *units = attr->values[element].resolution.units;
-+
-+ return (attr->values[element].resolution.xres);
-+}
-+
-+ipp_status_t
-+ippGetStatusCode(ipp_t *ipp)
-+{
-+ return (ipp->request.status.status_code);
-+}
-+
-+const char *
-+ippGetString(ipp_attribute_t *attr,
-+ int element,
-+ const char **language)
-+{
-+ return (attr->values[element].string.text);
-+}
-+
-+ipp_tag_t
-+ippGetValueTag(ipp_attribute_t *attr)
-+{
-+ return (attr->value_tag);
-+}
-+
-+ipp_attribute_t *
-+ippFirstAttribute(ipp_t *ipp)
-+{
-+ if (!ipp)
-+ return (NULL);
-+ return (ipp->current = ipp->attrs);
-+}
-+
-+ipp_attribute_t *
-+ippNextAttribute(ipp_t *ipp)
-+{
-+ if (!ipp || !ipp->current)
-+ return (NULL);
-+ return (ipp->current = ipp->current->next);
-+}
-+
-+int
-+ippSetInteger(ipp_t *ipp,
-+ ipp_attribute_t **attr,
-+ int element,
-+ int intvalue)
-+{
-+ (*attr)->values[element].integer = intvalue;
-+ return (1);
-+}
-+
-+int
-+ippSetOperation(ipp_t *ipp,
-+ ipp_op_t op)
-+{
-+ ipp->request.op.operation_id = op;
-+ return (1);
-+}
-+
-+int
-+ippSetString(ipp_t *ipp,
-+ ipp_attribute_t **attr,
-+ int element,
-+ const char *strvalue)
-+{
-+ (*attr)->values[element].string.text = (char *) strvalue;
-+ return (1);
-+}
-+
-+#endif
-+
- //////////////////////////
- // Module-level methods //
- //////////////////////////
-diff --git a/cupsmodule.h b/cupsmodule.h
-index 593f429..c30d0e3 100644
---- a/cupsmodule.h
-+++ b/cupsmodule.h
-@@ -49,6 +49,10 @@ extern void debugprintf (const char *fmt, ...) FORMAT
((__printf__, 1, 2));
- #define HAVE_CUPS_1_4 1
- #endif
-
-+#if (CUPS_VERSION_MAJOR > 1) || (CUPS_VERSION_MINOR > 5)
-+#define HAVE_CUPS_1_6 1
-+#endif
-+
- #ifndef HAVE_CUPS_1_2
- #error pycups requires CUPS 1.2.x
- #endif
-@@ -65,4 +69,28 @@ struct TLS
-
- extern struct TLS *get_TLS (void);
-
-+#ifndef HAVE_CUPS_1_6
-+int ippGetBoolean(ipp_attribute_t *attr, int element);
-+int ippGetCount(ipp_attribute_t *attr);
-+ipp_tag_t ippGetGroupTag(ipp_attribute_t *attr);
-+int ippGetInteger(ipp_attribute_t *attr, int element);
-+const char * ippGetName(ipp_attribute_t *attr);
-+ipp_op_t ippGetOperation(ipp_t *ipp);
-+int ippGetRange(ipp_attribute_t *attr, int element, int *uppervalue);
-+int ippGetResolution(ipp_attribute_t *attr, int element,
-+ int *yres, ipp_res_t *units);
-+ipp_status_t ippGetStatusCode(ipp_t *ipp);
-+const char * ippGetString(ipp_attribute_t *attr, int element,
-+ const char **language);
-+ipp_tag_t ippGetValueTag(ipp_attribute_t *attr);
-+ipp_attribute_t * ippFirstAttribute(ipp_t *ipp);
-+ipp_attribute_t * ippNextAttribute(ipp_t *ipp);
-+int ippSetInteger(ipp_t *ipp, ipp_attribute_t **attr,
-+ int element, int intvalue);
-+int ippSetOperation(ipp_t *ipp, ipp_op_t op);
-+int ippSetString(ipp_t *ipp, ipp_attribute_t **attr,
-+ int element, const char *strvalue);
-+#endif
-+
-+
- #endif /* HAVE_CUPSMODULE_H */
---
-1.7.2.1
-
diff --git a/printer/system-config-printer/DETAILS
b/printer/system-config-printer/DETAILS
index e58c5e4..d7c85e3 100755
--- a/printer/system-config-printer/DETAILS
+++ b/printer/system-config-printer/DETAILS
@@ -1,5 +1,5 @@
SPELL=system-config-printer
- VERSION=1.3.9
+ VERSION=1.3.11
SOURCE=$SPELL-$VERSION.tar.xz
SOURCE2=$SOURCE.sig
SOURCE2_IGNORE=signature
diff --git a/printer/system-config-printer/HISTORY
b/printer/system-config-printer/HISTORY
index 70e2b96..f90a35a 100644
--- a/printer/system-config-printer/HISTORY
+++ b/printer/system-config-printer/HISTORY
@@ -1,3 +1,6 @@
+2012-08-07 Ladislav Hagara <hgr AT vabo.cz>
+ * DETAILS: 1.3.11
+
2012-06-25 Sukneet Basuta <sukneet AT sourcemage.org>
* DEPENDS: added depends desktop-file-utils (for desktop file install)
diff --git a/science-libs/eigen3/DETAILS b/science-libs/eigen3/DETAILS
index a01fa8b..947f2fc 100755
--- a/science-libs/eigen3/DETAILS
+++ b/science-libs/eigen3/DETAILS
@@ -1,9 +1,9 @@
SPELL=eigen3
SPELLX=eigen
- VERSION=3.1.0
-
SOURCE_HASH=sha512:dbe39e5a0314d658b7d34f5a4216d4b11a92a37dd35e1d54d68ee2ec653af3b6a6d1107bff87d705660c04749ab15deaaf31adcbb0ae4b69b82beb94cc71b345
+ VERSION=3.1.1
+
SOURCE_HASH=sha512:099310095c2b0a0e5e6af389414ab35c73828699d489813d527345307bc4cdc7f40eca24cb798fb2b29f3048938ae82219b0e3a410e64f32724bd0d27a134d50
SOURCE=$VERSION.tar.bz2
-SOURCE_DIRECTORY=$BUILD_DIRECTORY/eigen-eigen-ca142d0540d3
+SOURCE_DIRECTORY=$BUILD_DIRECTORY/eigen-eigen-43d9075b23ef
SOURCE_URL[0]=https://bitbucket.org/$SPELLX/$SPELLX/get/$SOURCE
WEB_SITE=http://eigen.tuxfamily.org
LICENSE[0]=LGPL
diff --git a/science-libs/eigen3/HISTORY b/science-libs/eigen3/HISTORY
index b918c1e..40cf620 100644
--- a/science-libs/eigen3/HISTORY
+++ b/science-libs/eigen3/HISTORY
@@ -1,3 +1,6 @@
+2012-08-06 Treeve Jelbert <treeve AT sourcemage.org>
+ * DETAILS: version 3.1.1
+
2012-06-27 Treeve Jelbert <treeve AT sourcemage.org>
* DETAILS: version 3.1.0
diff --git a/x11-libs/wine/DETAILS b/x11-libs/wine/DETAILS
index 6c3917c..dcf6873 100755
--- a/x11-libs/wine/DETAILS
+++ b/x11-libs/wine/DETAILS
@@ -12,7 +12,7 @@ SOURCE_DIRECTORY="$BUILD_DIRECTORY/$SPELL-git"
FORCE_DOWNLOAD=1
else
if [[ $WINE_BRANCH == devel ]]; then
- VERSION=1.5.8
+ VERSION=1.5.10
else
VERSION=1.4.1
fi
diff --git a/x11-libs/wine/HISTORY b/x11-libs/wine/HISTORY
index d58412f..8ea9771 100644
--- a/x11-libs/wine/HISTORY
+++ b/x11-libs/wine/HISTORY
@@ -1,3 +1,6 @@
+2012-08-07 Eric Sandall <sandalle AT sourcemage.org>
+ * DETAILS: Updated devel to 1.5.10
+
2012-07-09 Eric Sandall <sandalle AT sourcemage.org>
* DETAILS: Updated devel to 1.5.8
- [SM-Commit] GIT changes to devel-xorg-modular grimoire by Eric Sandall (84ba7cd690fb9bf2eb54e6affcb380e953dbe0fd), Eric Sandall, 08/07/2012
Archive powered by MHonArc 2.6.24.