Index: head/devel/ice/Makefile =================================================================== --- head/devel/ice/Makefile (revision 377331) +++ head/devel/ice/Makefile (revision 377332) @@ -1,144 +1,144 @@ # Created by: Stefan Ehmann # $FreeBSD$ PORTNAME= Ice PORTVERSION= 3.5.1 -PORTREVISION= 5 +PORTREVISION= 6 CATEGORIES= devel MASTER_SITES= http://download.zeroc.com/Ice/3.5/ MAINTAINER= freebsd@grem.de COMMENT= Modern alternative to object middleware such as CORBA/COM/DCOM/COM+ LICENSE= GPLv2 SLAVE_PORT?= no .if ${SLAVE_PORT} == "no" LIB_DEPENDS= libexpat.so:${PORTSDIR}/textproc/expat2 \ libmcpp.so:${PORTSDIR}/devel/mcpp USE_OPENSSL= yes .else LIB_VRS= ${PORTVERSION:R:S|.||g} LIB_DEPENDS+= libIce.so.${LIB_VRS}:${PORTSDIR}/devel/ice PLIST_SUB+= LIB_VERSION="${PORTVERSION}" LIB_VRS="${LIB_VRS}" .endif OPTIONS_DEFINE?= DEBUG DEMOS DOCS TESTS OPTIONS_DEFAULT?= DEMOS TESTS TESTS_DESC?= Build and run tests (requires lang/python) DEMOS_DESC?= Build demos .include USES+= iconv gmake .if ${PORT_OPTIONS:MTESTS} && ${SLAVE_PORT} == "no" USES+= python:build .endif USE_BDB= yes WANT_BDB_VER= 5 INVALID_BDB_VER= 40 41 42 43 44 46 47 48 6 USE_LDCONFIG= yes BUILD_WRKSRC?= ${WRKSRC}/cpp INSTALL_WRKSRC?= ${WRKSRC}/cpp CFLAGS+= -ftemplate-depth-128 -fPIC -DPIC -Wall -D_REENTRANT -I${LOCALBASE}/include .if ${PORT_OPTIONS:MDEBUG} CFLAGS+= -g .else CFLAGS+= -DNDEBUG .endif .if ${ARCH} == "ia64" BROKEN= does not compile on ia64 .endif .if ${ARCH} == "sparc64" BROKEN= fails to link .endif .if ((${ARCH} != i386) && (${ARCH} != powerpc)) MAKE_ENV+= LP64=yes .endif .if !${PORT_OPTIONS:MTESTS} MAKE_ENV+= NOTESTS=yes .endif .if !${PORT_OPTIONS:MDEMOS} MAKE_ENV+= NODEMOS=yes .endif .if !${PORT_OPTIONS:MDOCS} MAKE_ENV+= NOICEDOCS=yes .endif .include .if defined(PYTHON_REL) && ${PYTHON_REL} >= 320 PLIST_SUB+= PYTHON32="" PLIST_SUB+= PYTHONPRE32="@comment " .else PLIST_SUB+= PYTHON32="@comment " PLIST_SUB+= PYTHONPRE32="" .endif PLIST_SUB+= PYTHON_SUFFIX=${PYTHON_SUFFIX} .if ${PREFIX} != ${LOCALBASE} PYSITEDIR= ${PREFIX}${PYTHON_SITELIBDIR:S|^${LOCALBASE}||} .else PYSITEDIR= ${PYTHON_SITELIBDIR} .endif .if ${PORT_OPTIONS:MNAMESPACES} MAKE_ARGS+= USE_NAMESPACES=yes PLIST_SUB+= NAMESPACES="" PLIST_SUB+= NONAMESPACES="@comment " .else PLIST_SUB+= NAMESPACES="@comment " PLIST_SUB+= NONAMESPACES="" .endif post-patch: @${SED} 's|%%PREFIX%%|${STAGEDIR}${PREFIX}|g; \ s|%%DATADIR%%|${STAGEDIR}${DATADIR}|g; \ s|%%DOCSDIR%%|${STAGEDIR}${DOCSDIR}|g; \ s|%%ICONV_LIB%%|${ICONV_LIB}|g; \ s|%%INSTALL_PROGRAM%%|${INSTALL_PROGRAM}|g; \ s|%%INSTALL_DATA%%|${INSTALL_DATA}|g' \ ${FILESDIR}/Make.rules.FreeBSD > ${WRKSRC}/cpp/config/Make.rules.FreeBSD @${REINPLACE_CMD} 's|%%BDB_LIB_CXX_NAME%%|${BDB_LIB_CXX_NAME}|g; \ s|%%BDB_LIB_DIR%%|${BDB_LIB_DIR}|g; \ s|%%BDB_INCLUDE_DIR%%|${BDB_INCLUDE_DIR}|g; \ /install_docdir/d' \ ${WRKSRC}/cpp/config/Make.rules @${REINPLACE_CMD} '/install_configdir/d' \ ${WRKSRC}/cpp/config/Make.rules @${REINPLACE_CMD} 's|INSTALL_PROGRAM|INSTALL_DATA|g' \ ${WRKSRC}/cpp/src/ca/Makefile @${REINPLACE_CMD} '/LICENSE/s/prefix/install_slicedir/; \ s|%%INSTALL_PROGRAM%%|${INSTALL_PROGRAM}|g; ' \ ${WRKSRC}/config/Make.common.rules @${REINPLACE_CMD} 's|%%INSTALL_PROGRAM%%|${INSTALL_PROGRAM}|g; \ s|%%INSTALL_DATA%%|${INSTALL_DATA}|g; \ s|%%ICONV_LIB%%|${ICONV_LIB}|g; \ s|%%PYTHON_SITELIBDIR%%|${STAGEDIR}${PYSITEDIR}|g; \ s|%%PREFIX%%|${PREFIX}|g ; \ s|%%LOCALBASE%%|${LOCALBASE}|g' ${WRKSRC}/py/config/Make.rules @${REINPLACE_CMD} 's|%%INSTALL_PROGRAM%%|${INSTALL_PROGRAM}|g; \ s|%%INSTALL_DATA%%|${INSTALL_DATA}|g; \ s|%%PREFIX%%|${PREFIX}|g ; \ s|%%LOCALBASE%%|${LOCALBASE}|g' ${WRKSRC}/php/config/Make.rules.php .if ${PORT_OPTIONS:MTESTS} TEST_CMD= @cd ${BUILD_WRKSRC} && ${PYTHON_CMD} ./allTests.py post-build: ${TEST_CMD} regression-test test: build ${TEST_CMD} .endif .include Index: head/devel/ice/files/patch-py-modules-IcePy-Types.cpp =================================================================== --- head/devel/ice/files/patch-py-modules-IcePy-Types.cpp (revision 377331) +++ head/devel/ice/files/patch-py-modules-IcePy-Types.cpp (revision 377332) @@ -1,112 +1,229 @@ ---- py/modules/IcePy/Types.cpp.orig 2013-03-11 15:19:47.000000000 +0000 -+++ py/modules/IcePy/Types.cpp 2014-09-08 14:21:13.335195726 +0000 -@@ -1232,11 +1232,15 @@ IcePy::StructInfo::marshal(PyObject* p, const Ice::OutputStreamPtr& os, ObjectMa +--- py/modules/IcePy/Types.cpp.orig 2015-01-18 15:25:00.277654935 +0100 ++++ py/modules/IcePy/Types.cpp 2015-01-18 15:24:52.737609935 +0100 +@@ -915,7 +915,7 @@ + } + + void +-IcePy::PrimitiveInfo::print(PyObject* value, IceUtilInternal::Output& out, PrintObjectHistory*) ++IcePy::PrimitiveInfo::print(PyObject* value, PrintHelper& out, PrintObjectHistory*) { + if(!validate(value)) + { +@@ -1050,7 +1050,7 @@ + } + + void +-IcePy::EnumInfo::print(PyObject* value, IceUtilInternal::Output& out, PrintObjectHistory*) ++IcePy::EnumInfo::print(PyObject* value, PrintHelper& out, PrintObjectHistory*) + { + if(!validate(value)) + { +@@ -1232,11 +1232,15 @@ + { assert(PyObject_IsInstance(p, pythonType.get()) == 1); // validate() should have caught this. + int sizePos = -1; if(optional) { if(_variableLength) { - os->startSize(); + // BUGFIX: #5481 startSize/endSize can't be nested + //os->startSize(); + sizePos = os->pos(); + os->write(Ice::Int(0)); } else { -@@ -1266,7 +1270,9 @@ IcePy::StructInfo::marshal(PyObject* p, const Ice::OutputStreamPtr& os, ObjectMa +@@ -1266,7 +1270,9 @@ if(optional && _variableLength) { - os->endSize(); + assert(sizePos != -1); + //os->endSize(); + os->rewrite(os->pos() - sizePos - 4, sizePos); } } -@@ -1402,11 +1408,15 @@ IcePy::SequenceInfo::marshal(PyObject* p, const Ice::OutputStreamPtr& os, Object +@@ -1305,7 +1311,7 @@ + } + + void +-IcePy::StructInfo::print(PyObject* value, IceUtilInternal::Output& out, PrintObjectHistory* history) ++IcePy::StructInfo::print(PyObject* value, PrintHelper& out, PrintObjectHistory* history) { + if(!validate(value)) + { +@@ -1402,11 +1408,15 @@ + { PrimitiveInfoPtr pi = PrimitiveInfoPtr::dynamicCast(elementType); + int sizePos = -1; if(optional) { if(elementType->variableLength()) { - os->startSize(); + // BUGFIX: #5481 startSize/endSize can't be nested + //os->startSize(); + sizePos = os->pos(); + os->write(Ice::Int(0)); } else if(elementType->wireSize() > 1) { -@@ -1490,7 +1500,9 @@ IcePy::SequenceInfo::marshal(PyObject* p, const Ice::OutputStreamPtr& os, Object +@@ -1490,7 +1500,9 @@ if(optional && elementType->variableLength()) { - os->endSize(); + assert(sizePos != -1); + //os->endSize(); + os->rewrite(os->pos() - sizePos - 4, sizePos); } } -@@ -2480,11 +2492,15 @@ IcePy::DictionaryInfo::marshal(PyObject* p, const Ice::OutputStreamPtr& os, Obje +@@ -1559,7 +1571,7 @@ + } + void +-IcePy::SequenceInfo::print(PyObject* value, IceUtilInternal::Output& out, PrintObjectHistory* history) ++IcePy::SequenceInfo::print(PyObject* value, PrintHelper& out, PrintObjectHistory* history) + { + if(!validate(value)) + { +@@ -2397,7 +2409,7 @@ + } + + void +-IcePy::CustomInfo::print(PyObject* value, IceUtilInternal::Output& out, PrintObjectHistory* history) ++IcePy::CustomInfo::print(PyObject* value, PrintHelper& out, PrintObjectHistory* history) + { + if(!validate(value)) + { +@@ -2480,11 +2492,15 @@ + const Ice::Int sz = p == Py_None ? 0 : static_cast(PyDict_Size(p)); + int sizePos = -1; if(optional) { if(_variableLength) { - os->startSize(); + // BUGFIX: #5481 startSize/endSize can't be nested + //os->startSize(); + sizePos = os->pos(); + os->write(Ice::Int(0)); } else { -@@ -2523,7 +2539,9 @@ IcePy::DictionaryInfo::marshal(PyObject* p, const Ice::OutputStreamPtr& os, Obje +@@ -2523,7 +2539,9 @@ if(optional && _variableLength) { - os->endSize(); + assert(sizePos != -1); + //os->endSize(); + os->rewrite(os->pos() - sizePos - 4, sizePos); } } -@@ -2958,9 +2976,13 @@ IcePy::ProxyInfo::optionalFormat() const +@@ -2597,7 +2615,7 @@ + } + void +-IcePy::DictionaryInfo::print(PyObject* value, IceUtilInternal::Output& out, PrintObjectHistory* history) ++IcePy::DictionaryInfo::print(PyObject* value, PrintHelper& out, PrintObjectHistory* history) + { + if(!validate(value)) + { +@@ -2798,7 +2816,7 @@ + } + + void +-IcePy::ClassInfo::print(PyObject* value, IceUtilInternal::Output& out, PrintObjectHistory* history) ++IcePy::ClassInfo::print(PyObject* value, PrintHelper& out, PrintObjectHistory* history) + { + if(!validate(value)) + { +@@ -2863,7 +2881,7 @@ + } + + void +-IcePy::ClassInfo::printMembers(PyObject* value, IceUtilInternal::Output& out, PrintObjectHistory* history) ++IcePy::ClassInfo::printMembers(PyObject* value, PrintHelper& out, PrintObjectHistory* history) + { + if(base) + { +@@ -2958,9 +2976,13 @@ + void IcePy::ProxyInfo::marshal(PyObject* p, const Ice::OutputStreamPtr& os, ObjectMap*, bool optional, const Ice::StringSeq*) { + int sizePos = -1; if(optional) { - os->startSize(); + // BUGFIX: #5481 startSize/endSize can't be nested + //os->startSize(); + sizePos = os->pos(); + os->write(Ice::Int(0)); } if(p == Py_None) -@@ -2978,7 +3000,9 @@ IcePy::ProxyInfo::marshal(PyObject* p, const Ice::OutputStreamPtr& os, ObjectMap +@@ -2978,7 +3000,9 @@ if(optional) { - os->endSize(); + assert(sizePos != -1); + //os->endSize(); + os->rewrite(os->pos() - sizePos - 4, sizePos); } } +@@ -3011,7 +3035,7 @@ + } + + void +-IcePy::ProxyInfo::print(PyObject* value, IceUtilInternal::Output& out, PrintObjectHistory*) ++IcePy::ProxyInfo::print(PyObject* value, PrintHelper& out, PrintObjectHistory*) + { + if(!validate(value)) + { +@@ -3463,7 +3487,7 @@ + } + + void +-IcePy::ExceptionInfo::print(PyObject* value, IceUtilInternal::Output& out) ++IcePy::ExceptionInfo::print(PyObject* value, PrintHelper& out) + { + if(!PyObject_IsInstance(value, pythonType.get())) + { +@@ -3481,7 +3505,7 @@ + } + + void +-IcePy::ExceptionInfo::printMembers(PyObject* value, IceUtilInternal::Output& out, PrintObjectHistory* history) ++IcePy::ExceptionInfo::printMembers(PyObject* value, PrintHelper& out, PrintObjectHistory* history) + { + if(base) + { +@@ -4209,7 +4233,7 @@ + assert(info); + + ostringstream ostr; +- IceUtilInternal::Output out(ostr); ++ PrintHelper out(ostr); + PrintObjectHistory history; + history.index = 0; + info->print(value, out, &history); +@@ -4234,7 +4258,7 @@ + assert(info); + + ostringstream ostr; +- IceUtilInternal::Output out(ostr); ++ PrintHelper out(ostr); + info->print(value, out); + + string str = ostr.str(); Index: head/devel/ice/files/patch-py-modules-IcePy-Types.h =================================================================== --- head/devel/ice/files/patch-py-modules-IcePy-Types.h (nonexistent) +++ head/devel/ice/files/patch-py-modules-IcePy-Types.h (revision 377332) @@ -0,0 +1,150 @@ +--- py/modules/IcePy/Types.h.orig 2015-01-18 15:25:04.917707935 +0100 ++++ py/modules/IcePy/Types.h 2015-01-18 15:24:54.689631935 +0100 +@@ -69,6 +69,50 @@ + std::map objects; + }; + ++struct PrintHelper ++{ ++ std::ostream& os; ++ Ice::Long indent; ++ ++ PrintHelper(std::ostream& o): os(o), indent(0) {} ++ void newline() ++ { ++ os << "\n" << std::string(indent * 4, ' '); ++ os.flush(); ++ } ++ ++ void sb() ++ { ++ newline(); ++ os << "{"; ++ ++indent; ++ } ++ ++ void eb() ++ { ++ --indent; ++ newline(); ++ os << "}"; ++ } ++}; ++ ++template ++inline PrintHelper& ++operator<<(PrintHelper& ph, const T& val) ++{ ++ ph.os << val; ++ return ph; ++} ++ ++template<> ++inline PrintHelper& ++operator<<(PrintHelper& ph, const IceUtilInternal::NextLine&) ++{ ++ ph.newline(); ++ return ph; ++} ++ ++ + // + // The delayed nature of class unmarshaling in the Ice protocol requires us to + // handle unmarshaling using a callback strategy. An instance of UnmarshalCallback +@@ -127,7 +171,7 @@ + virtual void unmarshal(const Ice::InputStreamPtr&, const UnmarshalCallbackPtr&, PyObject*, void*, bool, + const Ice::StringSeq* = 0) = 0; + +- virtual void print(PyObject*, IceUtilInternal::Output&, PrintObjectHistory*) = 0; ++ virtual void print(PyObject*, PrintHelper&, PrintObjectHistory*) = 0; + }; + typedef IceUtil::Handle TypeInfoPtr; + +@@ -164,7 +208,7 @@ + virtual void unmarshal(const Ice::InputStreamPtr&, const UnmarshalCallbackPtr&, PyObject*, void*, bool, + const Ice::StringSeq* = 0); + +- virtual void print(PyObject*, IceUtilInternal::Output&, PrintObjectHistory*); ++ virtual void print(PyObject*, PrintHelper&, PrintObjectHistory*); + + const Kind kind; + }; +@@ -193,7 +237,7 @@ + virtual void unmarshal(const Ice::InputStreamPtr&, const UnmarshalCallbackPtr&, PyObject*, void*, bool, + const Ice::StringSeq* = 0); + +- virtual void print(PyObject*, IceUtilInternal::Output&, PrintObjectHistory*); ++ virtual void print(PyObject*, PrintHelper&, PrintObjectHistory*); + + const std::string id; + const PyObjectHandle pythonType; +@@ -240,7 +284,7 @@ + virtual void unmarshal(const Ice::InputStreamPtr&, const UnmarshalCallbackPtr&, PyObject*, void*, bool, + const Ice::StringSeq* = 0); + +- virtual void print(PyObject*, IceUtilInternal::Output&, PrintObjectHistory*); ++ virtual void print(PyObject*, PrintHelper&, PrintObjectHistory*); + + virtual void destroy(); + +@@ -278,7 +322,7 @@ + virtual void unmarshal(const Ice::InputStreamPtr&, const UnmarshalCallbackPtr&, PyObject*, void*, bool, + const Ice::StringSeq* = 0); + +- virtual void print(PyObject*, IceUtilInternal::Output&, PrintObjectHistory*); ++ virtual void print(PyObject*, PrintHelper&, PrintObjectHistory*); + + virtual void destroy(); + +@@ -338,7 +382,7 @@ + virtual void unmarshal(const Ice::InputStreamPtr&, const UnmarshalCallbackPtr&, PyObject*, void*, bool, + const Ice::StringSeq* = 0); + +- virtual void print(PyObject*, IceUtilInternal::Output&, PrintObjectHistory*); ++ virtual void print(PyObject*, PrintHelper&, PrintObjectHistory*); + + virtual void destroy(); + +@@ -371,7 +415,7 @@ + const Ice::StringSeq* = 0); + virtual void unmarshaled(PyObject*, PyObject*, void*); + +- virtual void print(PyObject*, IceUtilInternal::Output&, PrintObjectHistory*); ++ virtual void print(PyObject*, PrintHelper&, PrintObjectHistory*); + + virtual void destroy(); + +@@ -420,11 +464,11 @@ + virtual void unmarshal(const Ice::InputStreamPtr&, const UnmarshalCallbackPtr&, PyObject*, void*, bool, + const Ice::StringSeq* = 0); + +- virtual void print(PyObject*, IceUtilInternal::Output&, PrintObjectHistory*); ++ virtual void print(PyObject*, PrintHelper&, PrintObjectHistory*); + + virtual void destroy(); + +- void printMembers(PyObject*, IceUtilInternal::Output&, PrintObjectHistory*); ++ void printMembers(PyObject*, PrintHelper&, PrintObjectHistory*); + + const std::string id; + const Ice::Int compactId; +@@ -462,7 +506,7 @@ + virtual void unmarshal(const Ice::InputStreamPtr&, const UnmarshalCallbackPtr&, PyObject*, void*, bool, + const Ice::StringSeq* = 0); + +- virtual void print(PyObject*, IceUtilInternal::Output&, PrintObjectHistory*); ++ virtual void print(PyObject*, PrintHelper&, PrintObjectHistory*); + + virtual void destroy(); + +@@ -482,8 +526,8 @@ + void marshal(PyObject*, const Ice::OutputStreamPtr&, ObjectMap*); + PyObject* unmarshal(const Ice::InputStreamPtr&); + +- void print(PyObject*, IceUtilInternal::Output&); +- void printMembers(PyObject*, IceUtilInternal::Output&, PrintObjectHistory*); ++ void print(PyObject*, PrintHelper&); ++ void printMembers(PyObject*, PrintHelper&, PrintObjectHistory*); + + std::string id; + bool preserve; Property changes on: head/devel/ice/files/patch-py-modules-IcePy-Types.h ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property