[weasel-commit] Source: expect=5.43.0-2

  • From: rbuilder@xxxxxxxxx
  • To: weasel-commit@xxxxxxxxxxxxx
  • Date: Tue, 05 Jan 2010 17:38:57 -0500

================================
expect:source=5.43.0-2 (previous: 5.43.0-1)
cvc rdiff expect -1 /weasel.rpath.org@wgl:3-devel/5.43.0-2
================================
5.43.0-2 Filip Brcic (brcha@xxxxxxx) Tue Jan  5 17:37:42 2010
    fixed recipe

expect.recipe: changed
Index: expect.recipe
====================================================================
contents(size sha1)
inode(mtime)
--- expect.recipe /weasel.rpath.org@wgl:3-devel/5.43.0-1
+++ expect.recipe /weasel.rpath.org@wgl:3-devel/5.43.0-2
@@ -3,62 +3,68 @@
 # Distributed under the terms of the GNU General Public License v3
 #
 
+loadInstalled('tcl')
 class Expect(AutoPackageRecipe):
     name = 'expect'
     version = '5.43.0'
 
     buildRequires = [ 'tcl:devel', ]
 
+    shortDesc  = 'Expect tool'
+    longDesc   = 'Tool for automating interactive applications'
+    url        = 'http://expect.nist.gov/'
+    licenses   = [ 'BSD' ]
+    categories = [ 'System/Development' ]
+
     def unpack(r):
-        r.addArchive('http://expect.nist.gov/old/')
-        r.addPatch('expect-5.43.0-config_update-1.patch')
-        r.addPatch('expect-5.43.0-spawn-2.patch')
+        r.addArchive('http://expect.nist.gov/src/')
+#        r.addPatch('expect-5.43.0-multilib.patch')
         r.addPatch('expect-5.39.0-libdir.patch')
         r.addPatch('expect-5.43.0-avoid-tcl-internals-1.patch')
+
+        r.Replace('/usr/local/bin', '%(bindir)s',
+                  'expect.man', 'expectk.man')
+
+        r.Replace('install-libraries ', '',
+                  'Makefile.in',
+                  lines='^install:')
+        r.Replace('^SCRIPTS_MANPAGES = ', '_SCRIPTS_MANPAGES = ',
+                  'Makefile.in')
+
+        r.Replace('^#include "tcl.h"', '#include "tclInt.h"',
+                  'exp_inter.c', 'exp_command.c')
+        
+        r.Replace('^(#include <stdio.h>)',
+                  '\\1\n#include "expect_cf.h"',
+                  'Dbg.c')
+
         r.addPatch('expect-5.43.0-missing-includes.patch')
 
         r.Replace(r'EXP_LIB_SPEC="-L\\\${INSTALL_ROOT}\\\${exec_prefix}/lib 
-lexpect\${EXP_LIB_VERSION}\${DBGX}"',
                   r'EXP_LIB_SPEC="-L\${libdir} 
-lexpect${EXP_LIB_VERSION}${DBGX}"',
                   'configure')
 
-        r.Replace('/usr/local/bin', '%(bindir)s', 'expect.man', 'expectk.man')
+#        r.Autoreconf()
+        
+    def configure(r):
+        r.macros.tcl_version = '.'.join(Tcl.version.split('.')[:-1])
+        r.macros.tcl_include = '%(libdir)s/tcl%(tcl_version)s/include'
 
-        # Fix "TCL_REG_BOSONLY undeclared" error due to change in tcl8.5
-        r.Replace('^#include "tcl.h"', '#include "tclInt.h"',
-                 'exp_inter.c', 'exp_command.c')
-
-        # Fix missing define of HAVE_UNISTD_H in Dbg.c
-        r.Replace('^#include <stdio.h>', '#include <stdio.h>\\n#include 
"expect_cf.h"',
-                  'Dbg.c')
-
-        r.Run('touch configure') # configure thinks it should run autoconf
-
-        if Arch.x86_64:
-            macros32 = r.macros.copy()
-            macros32.lib = 'lib'
-            macros32.libdir = '%(prefix)s/lib'
-            macros32.essentiallibdir = '/lib'
-            macros32.cc = '"gcc -m32"'
-            macros32.cxx = '"g++ -m32"'
-
-            r.Configure('--enable-shared'
-                        ' --with-tcl=%(libdir)s'
-#                        ' --with-tk=%(libdir)s'
-                        ' --with-tclinclude=%(includedir)s',
-                        preConfigure='USE_ARCH=32',
-                        objDir='build32', overrideMacros=macros32)
-            r.Make(dir='build32', overrideMacros=macros32)
-            r.MakeInstall(rootVar='INSTALL_ROOT', dir='build32', 
overrideMacros=macros32)
-
-    def configure(r):
-        r.Configure('--enable-shared'
-                    ' --with-tcl=%(libdir)s'
-#                    ' --with-tk=%(libdir)s'
-                    ' --with-tclinclude=%(includedir)s',
-                    objDir='build')
+        r.Configure(
+            ' --with-tcl=%(libdir)s --with-tclinclude=%(tcl_include)s'
+            ' --without-x' # TODO: maybe enable X once tk is built
+            ' --enable-shared'
+            )
 
     def make(r):
-        r.Make(dir='build')
+        r.Make('TCLHDIRDASHI="-I%(tcl_include)s/generic 
-I%(tcl_include)s/unix"')
 
     def makeinstall(r):
-        r.MakeInstall(rootVar='INSTALL_ROOT', dir='build')
+        r.MakeDirs('%(libdir)s')
+        r.MakeInstall(rootVar='INSTALL_ROOT')
+
+        r.macros.majorminor = '.'.join(r.version.split('.')[:-1])
+
+        
r.Remove('%(libdir)s/%(name)s-%(majorminor)s/lib%(name)s%(majorminor)s.a')
+        r.Symlink('%(libdir)s/lib%(name)s%(majorminor)s.so',
+                  '%(libdir)s/lib%(name)s.so')


expect-5.43.0-missing-includes.patch: changed
Index: expect-5.43.0-missing-includes.patch
====================================================================
inode(perms mtime)
expect-5.43.0-avoid-tcl-internals-1.patch: changed
Index: expect-5.43.0-avoid-tcl-internals-1.patch
====================================================================
inode(perms mtime)
expect-5.39.0-libdir.patch: changed
Index: expect-5.39.0-libdir.patch
====================================================================
inode(perms mtime)
expect-5.43.0-multilib.patch: new
--- /dev/null
+++ expect-5.43.0-multilib.patch
@@ -0,0 +11 @@
+--- expect-5.42/configure.in.orig      2004-12-21 03:02:36.095170881 -0800
++++ expect-5.42/configure.in   2004-12-21 03:03:08.987170537 -0800
+@@ -1141,7 +1141,7 @@
+ fi
+ 
+ EXP_BUILD_LIB_SPEC="-L`pwd` -lexpect${EXP_LIB_VERSION}${DBGX}"
+-EXP_LIB_SPEC="-L\${INSTALL_ROOT}\${exec_prefix}/lib 
-lexpect${EXP_LIB_VERSION}${DBGX}"
++EXP_LIB_SPEC="-L\${libdir} -lexpect${EXP_LIB_VERSION}${DBGX}"
+ EXP_UNSHARED_LIB_FILE=libexpect${EXP_LIB_VERSION}${DBGX}.a
+ 
+ # The TCL_SHARED_LIB_SUFFIX macro below relies on the DBGX macro,

expect-5.43.0-spawn-2.patch: removed
expect-5.43.0-config_update-1.patch: removed

Committed by: brcha

Other related posts:

  • » [weasel-commit] Source: expect=5.43.0-2 - rbuilder