[99043] trunk/dports/textproc/sphinx

ryandesign at macports.org ryandesign at macports.org
Wed Oct 24 17:55:56 PDT 2012


Revision: 99043
          http://trac.macports.org//changeset/99043
Author:   ryandesign at macports.org
Date:     2012-10-24 17:55:56 -0700 (Wed, 24 Oct 2012)
Log Message:
-----------
sphinx: update to 2.0.6 (#32457); add mysql51, mysql55, mariadb, percona, postgresql82, postgresql92 variants (#36720)

Modified Paths:
--------------
    trunk/dports/textproc/sphinx/Portfile
    trunk/dports/textproc/sphinx/files/endian.patch

Removed Paths:
-------------
    trunk/dports/textproc/sphinx/files/src_sphinxexpr.cpp.patch

Modified: trunk/dports/textproc/sphinx/Portfile
===================================================================
--- trunk/dports/textproc/sphinx/Portfile	2012-10-24 22:49:05 UTC (rev 99042)
+++ trunk/dports/textproc/sphinx/Portfile	2012-10-25 00:55:56 UTC (rev 99043)
@@ -4,8 +4,7 @@
 PortSystem          1.0
 
 name                sphinx
-version             0.9.9
-revision            1
+version             2.0.6
 categories          textproc net
 license             GPL-2
 platforms           darwin
@@ -23,67 +22,102 @@
 
 homepage            http://sphinxsearch.com/
 master_sites        ${homepage}files/
+distname            ${name}-${version}-release
 
-checksums           sha1    8c739b96d756a50972c27c7004488b55d7458015 \
-                    rmd160  ed3cd1a9328114c1d2a6325cce5520065076c275
+checksums           rmd160  6fd53230457e62a6aabcb5321265abd8ea324cf6 \
+                    sha256  de943c397efda706661b3a12e12e9f8cc8a03bf6c02c5a6ba967a06384feede2
 
 depends_lib         port:expat \
                     port:libiconv
 
-patchfiles          endian.patch \
-                    src_sphinxexpr.cpp.patch
+patchfiles          endian.patch
 
-configure.args      --mandir=${prefix}/share/man \
-                    --datadir=${prefix}/share/doc \
+configure.args      --datadir=${prefix}/share/doc \
                     --sysconfdir=${prefix}/etc/sphinx \
-                    --without-mysql \
-                    ac_cv_search_iconv=-liconv
+                    --without-mysql
 
 test.run            yes
 
-variant postgres conflicts postgresql83 postgresql84 postgresql90 postgresql91 description {Enable PostgreSQL 8.2 support} {
+variant postgres requires postgresql82 description {Legacy compatibility variant} {}
+
+variant postgresql82 conflicts postgresql83 postgresql84 postgresql90 postgresql91 postgresql92 description {Enable PostgreSQL 8.2 support} {
     depends_lib-append      port:postgresql82
     configure.args-append   --with-pgsql \
                             --with-pgsql-includes=${prefix}/include/postgresql82 \
                             --with-pgsql-libs=${prefix}/lib/postgresql82
 }
 
-variant postgresql83 conflicts postgres postgresql84 postgresql90 postgresql91 description {Enable PostgreSQL 8.3 support} {
+variant postgresql83 conflicts postgresql82 postgresql84 postgresql90 postgresql91 postgresql92 description {Enable PostgreSQL 8.3 support} {
     depends_lib-append      port:postgresql83
     configure.args-append   --with-pgsql \
                             --with-pgsql-includes=${prefix}/include/postgresql83 \
                             --with-pgsql-libs=${prefix}/lib/postgresql83
 }
 
-variant postgresql84 conflicts postgres postgresql83 postgresql90 postgresql91 description {Enable PostgreSQL 8.4 support} {
+variant postgresql84 conflicts postgresql82 postgresql83 postgresql90 postgresql91 postgresql92 description {Enable PostgreSQL 8.4 support} {
     depends_lib-append      port:postgresql84
     configure.args-append   --with-pgsql \
                             --with-pgsql-includes=${prefix}/include/postgresql84 \
                             --with-pgsql-libs=${prefix}/lib/postgresql84
 }
 
-variant postgresql90 conflicts postgres postgresql83 postgresql84 postgresql91 description {Enable PostgreSQL 9.0 support} {
+variant postgresql90 conflicts postgresql82 postgresql83 postgresql84 postgresql91 postgresql92 description {Enable PostgreSQL 9.0 support} {
     depends_lib-append      port:postgresql90
     configure.args-append   --with-pgsql \
                             --with-pgsql-includes=${prefix}/include/postgresql90 \
                             --with-pgsql-libs=${prefix}/lib/postgresql90
 }
 
-variant postgresql91 conflicts postgres postgresql83 postgresql84 postgresql90 description {Enable PostgreSQL 9.1 support} {
+variant postgresql91 conflicts postgresql82 postgresql83 postgresql84 postgresql90 postgresql92 description {Enable PostgreSQL 9.1 support} {
     depends_lib-append      port:postgresql91
     configure.args-append   --with-pgsql \
                             --with-pgsql-includes=${prefix}/include/postgresql91 \
                             --with-pgsql-libs=${prefix}/lib/postgresql91
 }
 
-variant mysql5 description {Enable MySQL 5 support} {
+variant postgresql92 conflicts postgresql82 postgresql83 postgresql84 postgresql90 postgresql91 description {Enable PostgreSQL 9.2 support} {
+    depends_lib-append      port:postgresql91
+    configure.args-append   --with-pgsql \
+                            --with-pgsql-includes=${prefix}/include/postgresql91 \
+                            --with-pgsql-libs=${prefix}/lib/postgresql91
+}
+
+variant mysql5 conflicts mysql51 mysql55 mariadb percona description {Enable MySQL 5 support} {
     depends_lib-append      path:bin/mysql_config5:mysql5
     configure.args-delete   --without-mysql
     configure.args-append   --with-mysql-includes=${prefix}/include/mysql5/mysql \
                             --with-mysql-libs=${prefix}/lib/mysql5/mysql
 }
 
-if {![variant_isset postgres] && ![variant_isset postgresql83] && ![variant_isset postgresql84] && ![variant_isset postgresql90] && ![variant_isset mysql5]} {
+variant mysql51 conflicts mysql5 mysql55 mariadb percona description {Enable MySQL 5.1 support} {
+    depends_lib-append      port:mysql51
+    configure.args-delete   --without-mysql
+    configure.args-append   --with-mysql-includes=${prefix}/include/mysql51/mysql \
+                            --with-mysql-libs=${prefix}/lib/mysql51/mysql
+}
+
+variant mysql55 conflicts mysql5 mysql51 mariadb percona description {Enable MySQL 5.5 support} {
+    depends_lib-append      port:mysql55
+    configure.args-delete   --without-mysql
+    configure.args-append   --with-mysql-includes=${prefix}/include/mysql55/mysql \
+                            --with-mysql-libs=${prefix}/lib/mysql55/mysql
+}
+
+variant mariadb conflicts mysql5 mysql51 mysql55 percona description {Enable MariaDB support} {
+    depends_lib-append      port:mariadb
+    configure.args-delete   --without-mysql
+    configure.args-append   --with-mysql-includes=${prefix}/include/mariadb/mysql \
+                            --with-mysql-libs=${prefix}/lib/mariadb/mysql
+}
+
+variant percona conflicts mysql5 mysql51 mysql55 mariadb description {Enable Percona support} {
+    depends_lib-append      port:percona
+    configure.args-delete   --without-mysql
+    configure.args-append   --with-mysql-includes=${prefix}/include/percona/mysql \
+                            --with-mysql-libs=${prefix}/lib/percona/mysql
+}
+
+if {![variant_isset postgresql82] && ![variant_isset postgresql83] && ![variant_isset postgresql84] && ![variant_isset postgresql90] && ![variant_isset postgresql91] && ![variant_isset postgresql92] && ![variant_isset mysql5] && ![variant_isset mysql51] && ![variant_isset mysql55] && ![variant_isset mariadb] && ![variant_isset percona]} {
     default_variants +mysql5
 }
 

Modified: trunk/dports/textproc/sphinx/files/endian.patch
===================================================================
--- trunk/dports/textproc/sphinx/files/endian.patch	2012-10-24 22:49:05 UTC (rev 99042)
+++ trunk/dports/textproc/sphinx/files/endian.patch	2012-10-25 00:55:56 UTC (rev 99043)
@@ -1,58 +1,275 @@
---- src/sphinxstemru.cpp.orig	2009-03-03 02:42:35.000000000 +1100
-+++ src/sphinxstemru.cpp	2011-11-30 02:05:50.000000000 +1100
-@@ -68,6 +68,47 @@ struct RussianAlphabetWin1251_t
+--- configure.orig	2012-10-21 15:50:56.000000000 -0500
++++ configure	2012-10-24 19:43:13.000000000 -0500
+@@ -7785,231 +7785,6 @@
+ 
+ fi
+ 
+-# check endianness
+- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
+-$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
+-if test "${ac_cv_c_bigendian+set}" = set; then :
+-  $as_echo_n "(cached) " >&6
+-else
+-  ac_cv_c_bigendian=unknown
+-    # See if we're dealing with a universal compiler.
+-    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+-/* end confdefs.h.  */
+-#ifndef __APPLE_CC__
+-	       not a universal capable compiler
+-	     #endif
+-	     typedef int dummy;
+-
+-_ACEOF
+-if ac_fn_cxx_try_compile "$LINENO"; then :
+-
+-	# Check for potential -arch flags.  It is not universal unless
+-	# there are at least two -arch flags with different values.
+-	ac_arch=
+-	ac_prev=
+-	for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
+-	 if test -n "$ac_prev"; then
+-	   case $ac_word in
+-	     i?86 | x86_64 | ppc | ppc64)
+-	       if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
+-		 ac_arch=$ac_word
+-	       else
+-		 ac_cv_c_bigendian=universal
+-		 break
+-	       fi
+-	       ;;
+-	   esac
+-	   ac_prev=
+-	 elif test "x$ac_word" = "x-arch"; then
+-	   ac_prev=arch
+-	 fi
+-       done
+-fi
+-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+-    if test $ac_cv_c_bigendian = unknown; then
+-      # See if sys/param.h defines the BYTE_ORDER macro.
+-      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+-/* end confdefs.h.  */
+-#include <sys/types.h>
+-	     #include <sys/param.h>
+-
+-int
+-main ()
+-{
+-#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
+-		     && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
+-		     && LITTLE_ENDIAN)
+-	      bogus endian macros
+-	     #endif
+-
+-  ;
+-  return 0;
+-}
+-_ACEOF
+-if ac_fn_cxx_try_compile "$LINENO"; then :
+-  # It does; now see whether it defined to BIG_ENDIAN or not.
+-	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+-/* end confdefs.h.  */
+-#include <sys/types.h>
+-		#include <sys/param.h>
+-
+-int
+-main ()
+-{
+-#if BYTE_ORDER != BIG_ENDIAN
+-		 not big endian
+-		#endif
+-
+-  ;
+-  return 0;
+-}
+-_ACEOF
+-if ac_fn_cxx_try_compile "$LINENO"; then :
+-  ac_cv_c_bigendian=yes
+-else
+-  ac_cv_c_bigendian=no
+-fi
+-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+-fi
+-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+-    fi
+-    if test $ac_cv_c_bigendian = unknown; then
+-      # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
+-      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+-/* end confdefs.h.  */
+-#include <limits.h>
+-
+-int
+-main ()
+-{
+-#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
+-	      bogus endian macros
+-	     #endif
+-
+-  ;
+-  return 0;
+-}
+-_ACEOF
+-if ac_fn_cxx_try_compile "$LINENO"; then :
+-  # It does; now see whether it defined to _BIG_ENDIAN or not.
+-	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+-/* end confdefs.h.  */
+-#include <limits.h>
+-
+-int
+-main ()
+-{
+-#ifndef _BIG_ENDIAN
+-		 not big endian
+-		#endif
+-
+-  ;
+-  return 0;
+-}
+-_ACEOF
+-if ac_fn_cxx_try_compile "$LINENO"; then :
+-  ac_cv_c_bigendian=yes
+-else
+-  ac_cv_c_bigendian=no
+-fi
+-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+-fi
+-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+-    fi
+-    if test $ac_cv_c_bigendian = unknown; then
+-      # Compile a test program.
+-      if test "$cross_compiling" = yes; then :
+-  # Try to guess by grepping values from an object file.
+-	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+-/* end confdefs.h.  */
+-short int ascii_mm[] =
+-		  { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
+-		short int ascii_ii[] =
+-		  { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
+-		int use_ascii (int i) {
+-		  return ascii_mm[i] + ascii_ii[i];
+-		}
+-		short int ebcdic_ii[] =
+-		  { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
+-		short int ebcdic_mm[] =
+-		  { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
+-		int use_ebcdic (int i) {
+-		  return ebcdic_mm[i] + ebcdic_ii[i];
+-		}
+-		extern int foo;
+-
+-int
+-main ()
+-{
+-return use_ascii (foo) == use_ebcdic (foo);
+-  ;
+-  return 0;
+-}
+-_ACEOF
+-if ac_fn_cxx_try_compile "$LINENO"; then :
+-  if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
+-	      ac_cv_c_bigendian=yes
+-	    fi
+-	    if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
+-	      if test "$ac_cv_c_bigendian" = unknown; then
+-		ac_cv_c_bigendian=no
+-	      else
+-		# finding both strings is unlikely to happen, but who knows?
+-		ac_cv_c_bigendian=unknown
+-	      fi
+-	    fi
+-fi
+-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+-else
+-  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+-/* end confdefs.h.  */
+-$ac_includes_default
+-int
+-main ()
+-{
+-
+-	     /* Are we little or big endian?  From Harbison&Steele.  */
+-	     union
+-	     {
+-	       long int l;
+-	       char c[sizeof (long int)];
+-	     } u;
+-	     u.l = 1;
+-	     return u.c[sizeof (long int) - 1] == 1;
+-
+-  ;
+-  return 0;
+-}
+-_ACEOF
+-if ac_fn_cxx_try_run "$LINENO"; then :
+-  ac_cv_c_bigendian=no
+-else
+-  ac_cv_c_bigendian=yes
+-fi
+-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+-  conftest.$ac_objext conftest.beam conftest.$ac_ext
+-fi
+-
+-    fi
+-fi
+-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
+-$as_echo "$ac_cv_c_bigendian" >&6; }
+- case $ac_cv_c_bigendian in #(
+-   yes)
+-
+-$as_echo "#define USE_LITTLE_ENDIAN 0" >>confdefs.h
+-;; #(
+-   no)
+-
+-$as_echo "#define USE_LITTLE_ENDIAN 1" >>confdefs.h
+- ;; #(
+-   universal)
+-     as_fn_error "universial endianess not supported" "$LINENO" 5
+-
+-     ;; #(
+-   *)
+-     as_fn_error "unknown endianess not supported" "$LINENO" 5 ;;
+- esac
+ 
+ 
+ 
+--- src/sphinx.h.orig	2012-10-19 04:48:07.000000000 -0500
++++ src/sphinx.h	2012-10-24 19:32:00.000000000 -0500
+@@ -128,9 +128,6 @@
+ 
+ STATIC_ASSERT ( ( 1 << ROWITEM_SHIFT )==ROWITEM_BITS, INVALID_ROWITEM_SHIFT );
+ 
+-#ifndef USE_LITTLE_ENDIAN
+-#error Please define endianness
+-#endif
+ 
+ template < typename DOCID >
+ inline DOCID DOCINFO2ID_T ( const DWORD * pDocinfo );
+@@ -142,7 +139,7 @@
+ 
+ template<> inline uint64_t DOCINFO2ID_T ( const DWORD * pDocinfo )
+ {
+-#if USE_LITTLE_ENDIAN
++#ifdef __LITTLE_ENDIAN__
+ 	return uint64_t(pDocinfo[0]) + (uint64_t(pDocinfo[1])<<32);
+ #else
+ 	return uint64_t(pDocinfo[1]) + (uint64_t(pDocinfo[0])<<32);
+@@ -156,7 +153,7 @@
+ 
+ inline void DOCINFOSETID ( DWORD * pDocinfo, uint64_t uValue )
+ {
+-#if USE_LITTLE_ENDIAN
++#ifdef __LITTLE_ENDIAN__
+ 	pDocinfo[0] = (DWORD)uValue;
+ 	pDocinfo[1] = (DWORD)(uValue>>32);
+ #else
+--- src/sphinxstemru.cpp.orig	2012-10-17 05:36:31.000000000 -0500
++++ src/sphinxstemru.cpp	2012-10-24 19:32:20.000000000 -0500
+@@ -70,7 +70,7 @@
  // UTF-8 implementation
  /////////////////////////////////////////////////////////////////////////////
  
-+#ifdef __BIG_ENDIAN__
-+struct RussianAlphabetUTF8_t
-+{
-+	enum
-+	{
-+		A	= 0xD0B0U,
-+		B	= 0xD0B1U,
-+		V	= 0xD0B2U,
-+		G	= 0xD0B3U,
-+		D	= 0xD0B4U,
-+		E	= 0xD0B5U,
-+		YO	= 0xD191U,
-+		ZH	= 0xD0B6U,
-+		Z	= 0xD0B7U,
-+		I	= 0xD0B8U,
-+		IY	= 0xD0B9U,
-+		K	= 0xD0BAU,
-+		L	= 0xD0BBU,
-+		M	= 0xD0BCU,
-+		N	= 0xD0BDU,
-+		O	= 0xD0BEU,
-+		P	= 0xD0BFU,
-+		R	= 0xD180U,
-+		S	= 0xD181U,
-+		T	= 0xD182U,
-+		U	= 0xD183U,
-+		F	= 0xD184U,
-+		H	= 0xD185U,
-+		TS	= 0xD186U,
-+		CH	= 0xD187U,
-+		SH	= 0xD188U,
-+		SCH	= 0xD189U,
-+		TVY	= 0xD18AU, // TVYordiy znak
-+		Y	= 0xD18BU,
-+		MYA	= 0xD18CU, // MYAgkiy znak
-+		EE	= 0xD18DU,
-+		YU	= 0xD18EU,
-+		YA	= 0xD18FU
-+	};
-+};
-+#else
+-#if USE_LITTLE_ENDIAN
++#ifdef __LITTLE_ENDIAN__
  struct RussianAlphabetUTF8_t
  {
  	enum
-@@ -107,6 +148,7 @@ struct RussianAlphabetUTF8_t
- 		YA	= 0x8FD1U
- 	};
- };
-+#endif
- 
- #define LOC_CHAR_TYPE		unsigned short
- #define LOC_PREFIX(_a)		_a##_utf8

Deleted: trunk/dports/textproc/sphinx/files/src_sphinxexpr.cpp.patch
===================================================================
--- trunk/dports/textproc/sphinx/files/src_sphinxexpr.cpp.patch	2012-10-24 22:49:05 UTC (rev 99042)
+++ trunk/dports/textproc/sphinx/files/src_sphinxexpr.cpp.patch	2012-10-25 00:55:56 UTC (rev 99043)
@@ -1,29 +0,0 @@
---- src/sphinxexpr.cpp.orig	2009-10-22 11:36:37.000000000 +1100
-+++ src/sphinxexpr.cpp	2012-06-08 18:27:07.000000000 +1000
-@@ -1010,7 +1010,7 @@ public:
- 	/// evaluate arg, return interval id
- 	virtual int IntEval ( const CSphMatch & tMatch ) const
- 	{
--		T val = ExprEval ( this->m_pArg, tMatch ); // 'this' fixes gcc braindamage
-+		T val = Expr_ArgVsSet_c<T>::ExprEval ( this->m_pArg, tMatch ); // 'this' fixes gcc braindamage
- 		ARRAY_FOREACH ( i, this->m_dValues ) // FIXME! OPTIMIZE! perform binary search here
- 			if ( val<this->m_dValues[i] )
- 				return i;
-@@ -1044,7 +1044,7 @@ public:
- 	/// evaluate arg, return interval id
- 	virtual int IntEval ( const CSphMatch & tMatch ) const
- 	{
--		T val = ExprEval ( this->m_pArg, tMatch ); // 'this' fixes gcc braindamage
-+		T val = Expr_ArgVsSet_c<T>::ExprEval ( this->m_pArg, tMatch ); // 'this' fixes gcc braindamage
- 		ARRAY_FOREACH ( i, m_dTurnPoints )
- 			if ( val < Expr_ArgVsSet_c<T>::ExprEval ( m_dTurnPoints[i], tMatch ) )
- 				return i;
-@@ -1077,7 +1077,7 @@ public:
- 	/// evaluate arg, check if the value is within set
- 	virtual int IntEval ( const CSphMatch & tMatch ) const
- 	{
--		T val = ExprEval ( this->m_pArg, tMatch ); // 'this' fixes gcc braindamage
-+		T val = Expr_ArgVsSet_c<T>::ExprEval ( this->m_pArg, tMatch ); // 'this' fixes gcc braindamage
- 		return this->m_dValues.BinarySearch ( val )!=NULL;
- 	}
- 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20121024/2484de99/attachment-0001.html>


More information about the macports-changes mailing list