Ticket #48835: wireshark-1.12.8-lua52.diff
File wireshark-1.12.8-lua52.diff, 4.6 KB (added by raimue (Rainer Müller), 9 years ago) |
---|
-
Portfile
129 129 } 130 130 131 131 # https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=10881 132 #variant lua { 133 # configure.args-delete --without-lua 134 # configure.args-append --with-lua=${prefix} 135 # depends_lib-append port:lua 136 #} 132 variant lua { 133 configure.args-delete --without-lua 134 configure.args-append --with-lua=${prefix} 135 depends_lib-append port:lua 137 136 137 patchfiles-append patch-lua52-pkgconfig.diff 138 use_autoreconf yes 139 } 140 138 141 variant libsmi { 139 142 configure.args-delete --without-libsmi 140 143 configure.args-append --with-libsmi=${prefix} -
files/patch-configure.diff
12 12 ac_krb5_version="$ac_heimdal_version$ac_mit_version_olddir$ac_mit_version_newdir" 13 13 if test "x$ac_krb5_version" = "xHEIMDAL" 14 14 then 15 --- acinclude.m4 2015-10-14 19:01:09.000000000 +0200 16 +++ acinclude.m4 2015-11-06 16:35:20.000000000 +0100 17 @@ -1282,8 +1167,9 @@ 18 CPPFLAGS="$CPPFLAGS -I$krb5_dir/include" 19 ac_heimdal_version=`grep heimdal $krb5_dir/include/krb5.h | head -n 1 | sed 's/^.*heimdal.*$/HEIMDAL/'` 20 # MIT Kerberos moved krb5.h to krb5/krb5.h starting with release 1.5 21 - ac_mit_version_olddir=`grep 'Massachusetts Institute of Technology' $krb5_dir/include/krb5.h | head -n 1 | sed 's/^.*Massachusetts Institute of Technology.*$/MIT/'` 22 - ac_mit_version_newdir=`grep 'Massachusetts Institute of Technology' $krb5_dir/include/krb5/krb5.h | head -n 1 | sed 's/^.*Massachusetts Institute of Technology.*$/MIT/'` 23 + 24 + ac_mit_version_olddir=`head -20 "$krb5_dir/include/krb5.h" | perl -e 'while (<>) {$line = $_; chomp $line; $allLines .= " $line";} if ($allLines =~ /Massachusetts.*Institute of Technology/s) {print "MIT";}'` 25 + ac_mit_version_newdir=`head -20 "$krb5_dir/include/krb5/krb5.h" | perl -e 'while (<>) {$line = $_; chomp $line; $allLines .= " $line";} if ($allLines =~ /Massachusetts.*Institute of Technology/s) {print "MIT";}'` 26 ac_krb5_version="$ac_heimdal_version$ac_mit_version_olddir$ac_mit_version_newdir" 27 if test "x$ac_krb5_version" = "xHEIMDAL" 28 then -
files/patch-lua52-pkgconfig.diff
1 Upstream: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commitdiff;h=4fe8ca05767f2a4ec160eae412f5b2fd0ee0903b 2 Upstream: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commitdiff;h=9e1ddb5b73c28b531186c526ead54bfd544f149d 3 4 Inspired by upstream 2.0.0rc2, adapted to 1.12.x and specifically MacPorts. 5 Most of it can be thrown out on update to 2.0.0. 6 7 --- Makefile.am 8 +++ Makefile.am 9 @@ -625,7 +625,7 @@ 10 # Common headers 11 AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/wiretap \ 12 $(LIBGNUTLS_CFLAGS) $(LIBGCRYPT_CFLAGS) $(LIBSMI_CFLAGS) $(PY_CFLAGS) \ 13 - @LUA_INCLUDES@ -DTOP_SRCDIR=\"$(abs_top_srcdir)\" 14 + @LUA_CFLAGS@ -DTOP_SRCDIR=\"$(abs_top_srcdir)\" 15 16 # 17 # Build the version string 18 --- epan/Makefile.am 19 +++ epan/Makefile.am 20 @@ -47,7 +47,7 @@ libwireshark_la_LDFLAGS = -version-info 0:0:0 @LDFLAGS_SHAREDLIB@ 21 include Makefile.common 22 23 AM_CPPFLAGS = -I$(srcdir)/.. -I$(srcdir)/$(LEMON) -I$(builddir)/wslua \ 24 - @LUA_INCLUDES@ $(LIBGNUTLS_CFLAGS) $(LIBGCRYPT_CFLAGS) \ 25 + @LUA_CFLAGS@ $(LIBGNUTLS_CFLAGS) $(LIBGCRYPT_CFLAGS) \ 26 $(LIBSMI_CFLAGS) $(LIBGEOIP_CFLAGS) $(PY_CFLAGS) 27 28 AM_NON_GENERATED_CFLAGS =-DWS_BUILD_DLL 29 --- epan/wslua/Makefile.am 30 +++ epan/wslua/Makefile.am 31 @@ -23,7 +23,7 @@ if HAVE_WARNINGS_AS_ERRORS 32 AM_CFLAGS = -Werror 33 endif 34 35 -AM_CPPFLAGS = -I$(top_srcdir) @LUA_INCLUDES@ 36 +AM_CPPFLAGS = -I$(top_srcdir) @LUA_CFLAGS@ 37 38 noinst_LTLIBRARIES = libwslua.la 39 40 --- configure.ac 41 +++ configure.ac 42 @@ -2190,12 +2190,20 @@ 43 AC_MSG_RESULT(no) 44 else 45 AC_MSG_RESULT(yes) 46 - AC_WIRESHARK_LIBLUA_CHECK 47 + # XXX: MacPorts specific configure to work around incomaptible Lua versions 48 + # Try the standard pkg-config way, hardcoding the Lua version 49 + PKG_CHECK_MODULES(LUA, lua-5.2, [true], [want_lua=no]) 50 if test "x$want_lua" = "xno" ; then 51 - AC_MSG_RESULT(liblua not found - disabling support for the lua scripting plugin) 52 + AC_MSG_ERROR([Lua support was requested, but is not available]) 53 fi 54 fi 55 +if test "x$want_lua" = "xyes" 56 +then 57 + AC_DEFINE(HAVE_LUA, 1, [Define to use Lua]) 58 +fi 59 AM_CONDITIONAL(HAVE_LIBLUA, test x$want_lua = xyes) 60 +AC_SUBST(LUA_LIBS) 61 +AC_SUBST(LUA_CFLAGS) 62 63 64 dnl portaudio check