On Fri, 21 Mar 2008, Markus Hennecke wrote:

Hello ports,

attached is an updated port for ctwm bringing it to version 3.8a. So far tested on i386 and amd64. My config file from 3.6 worked out of the box. Please test and comment.

Here again in form of an unified diff. I reworked the port a little bit to make as few changes as possible. One thing I'd like to know is why the xpm files were left out of the install in the 3.6 port?

Kind regards,
  Markus
Index: Makefile
===================================================================
RCS file: /var/cvs/ports/x11/ctwm/Makefile,v
retrieving revision 1.18
diff -u -p -r1.18 Makefile
--- Makefile    1 Feb 2008 21:38:26 -0000       1.18
+++ Makefile    21 Mar 2008 09:58:07 -0000
@@ -2,11 +2,10 @@
 
 COMMENT=       twm, plus support for multiple virtual screens, etc
 
-DISTNAME=      ctwm-3.6
-PKGNAME=       ${DISTNAME}p0
+DISTNAME=      ctwm-3.8a
 CATEGORIES=    x11
 
-HOMEPAGE=      http://ctwm.dl.nu/
+HOMEPAGE=      http://ctwm.free.lp.se/
 
 # BSD-like/badly worded
 PERMIT_PACKAGE_CDROM=  Yes
@@ -14,7 +13,7 @@ PERMIT_PACKAGE_FTP=   Yes
 PERMIT_DISTFILES_CDROM=        Yes
 PERMIT_DISTFILES_FTP=  Yes
 
-WANTLIB=       ICE SM X11 Xau Xdmcp Xext Xmu Xpm Xt c
+WANTLIB=       ICE SM X11 Xau Xdmcp Xext Xmu Xpm Xt c jpeg
 
 MASTER_SITES=  ${HOMEPAGE}/dist/
 
@@ -22,5 +21,7 @@ USE_X11=      Yes
 CONFIGURE_STYLE= imake
 
 NO_REGRESS=    Yes
+
+LIB_DEPENDS=   jpeg.>=62::graphics/jpeg
 
 .include <bsd.port.mk>
Index: distinfo
===================================================================
RCS file: /var/cvs/ports/x11/ctwm/distinfo,v
retrieving revision 1.4
diff -u -p -r1.4 distinfo
--- distinfo    5 Apr 2007 17:36:19 -0000       1.4
+++ distinfo    21 Mar 2008 09:58:07 -0000
@@ -1,5 +1,5 @@
-MD5 (ctwm-3.6.tar.gz) = yenhYeB+PRx+J2hENvAeKw==
-RMD160 (ctwm-3.6.tar.gz) = g+b3cOWO+23qXqz8zjRTIv/dQW4=
-SHA1 (ctwm-3.6.tar.gz) = iozv0ic8dI/Xzt7Uw1U+XKeplOw=
-SHA256 (ctwm-3.6.tar.gz) = 2r4rF5ZD3bEAscc68gOME+3qcCFLS4RP0Sl+8nb/uzE=
-SIZE (ctwm-3.6.tar.gz) = 370563
+MD5 (ctwm-3.8a.tar.gz) = zq9A7w8b2jzIt8kRRNkhIw==
+RMD160 (ctwm-3.8a.tar.gz) = zBw8hiw8+x1mWT2aldKOwLu7rzw=
+SHA1 (ctwm-3.8a.tar.gz) = w6MdZpvvfdXseNiZUMDlddbFHHc=
+SHA256 (ctwm-3.8a.tar.gz) = OTIsxrDRLcKGrwlE+aENOgmaXwTF2cR7dXQs32Xb1KQ=
+SIZE (ctwm-3.8a.tar.gz) = 738226
Index: patches/patch-Imakefile
===================================================================
RCS file: /var/cvs/ports/x11/ctwm/patches/patch-Imakefile,v
retrieving revision 1.1
diff -u -p -r1.1 patch-Imakefile
--- patches/patch-Imakefile     5 Jul 2002 07:21:52 -0000       1.1
+++ patches/patch-Imakefile     21 Mar 2008 09:58:07 -0000
@@ -1,37 +1,33 @@
---- Imakefile.orig     Tue Dec 11 15:38:52 2001
-+++ Imakefile  Fri Jul  5 14:54:29 2002
-@@ -11,7 +11,7 @@
- #undef  USE_SOUND
- #define XPM
- #define USEM4
--#undef X11R6
-+#define X11R6
- #undef I18N
+$OpenBSD$
+--- Imakefile.orig     Fri Feb 16 10:24:27 2007
++++ Imakefile  Fri Mar 21 10:54:39 2008
+@@ -6,7 +6,20 @@ XCOMM other people do also, so perhaps you could do us
+ XCOMM distribute this one.
+ XCOMM
  
-          YFLAGS = -d
-@@ -19,8 +19,8 @@
-        LINTLIBS = $(LINTXMU) $(LINTEXTENSIONLIB) $(LINTXLIB)
+-#include "Imakefile.local"
++#undef  IMCONV
++#undef  USE_SOUND
++#define XPM
++#define JPEG
++#define USE_M4
++#undef GNOME
++#undef  USE_GNU_REGEX
++#undef  DEBUG
++#undef  DEBUGPARSER 
++#undef  GCC_PEDANTIC
++USER_JPEGLIBDIR = -L/usr/local/lib
++USER_JPEGINCDIR = -I/usr/local/include
++USER_XPMLIBDIR  = -L/usr/X11R6/lib
++USER_XPMINCDIR  = -I/usr/X11R6/include
  
- #ifdef XPM
--      XPMLIBDIR = 
--      XPMINCDIR = 
-+      XPMLIBDIR = -L/usr/X11R6/lib
-+      XPMINCDIR = -I/usr/X11R6/include
  
-      XPMDEFINES = -DXPM
-          XPMLIB = $(XPMLIBDIR) -lXpm
-@@ -145,14 +145,6 @@
- NormalLibraryTarget(ctwm, libctwm.o)
- ComplexProgramTarget(ctwm)
- InstallNonExecFile(system.ctwmrc,$(TWMDIR))
--#ifdef XPM
--install:: xpm
--      MakeDir($(DESTDIR)$(TWMDIR)/images)
--      @case '${MFLAGS}' in *[i]*) set +e;; esac; \
--      for i in xpm/?* ; do \
--              (set -x; $(INSTALL) -c $(INSTLIBFLAGS) $$i 
$(DESTDIR)$(TWMDIR)/images); \
--      done
--#endif
+ #ifdef DEBUGPARSER
+@@ -246,6 +259,6 @@ do_rpm:
+ $(OBJS): Makefile
  
- gram.h gram.c: gram.y
-       $(YACC) $(YFLAGS) gram.y
+ #define IHaveSpecialMakefileTarget
+-Makefile: Imakefile Imakefile.local
++Makefile: Imakefile
+       echo "You need to run 'xmkmf'"
+       exit 1
Index: patches/patch-gram.y
===================================================================
RCS file: /var/cvs/ports/x11/ctwm/patches/patch-gram.y,v
retrieving revision 1.1
diff -u -p -r1.1 patch-gram.y
--- patches/patch-gram.y        5 Jul 2002 07:21:52 -0000       1.1
+++ patches/patch-gram.y        21 Mar 2008 09:58:07 -0000
@@ -1,54 +0,0 @@
---- gram.y.orig        Tue Dec 11 15:38:52 2001
-+++ gram.y     Fri Jul  5 15:10:02 2002
-@@ -419,7 +419,6 @@
-               | WINDOW_RING           { list = &Scr->WindowRingL; }
-                 win_list
-               | WINDOW_RING           { Scr->WindowRingAll = TRUE; }
--              ;
-               | WINDOW_RING_EXCLUDE    { if (!Scr->WindowRingL)
-                                             Scr->WindowRingAll = TRUE;
-                                         list = &Scr->WindowRingExcludeL; }
-@@ -427,6 +426,7 @@
- 
-               | WINDOW_GEOMETRIES      {  }
-                 wingeom_list
-+              ;
- 
- noarg         : KEYWORD               { if (!do_single_keyword ($1)) {
-                                           twmrc_error_prefix();
-@@ -683,8 +683,8 @@
-               | wingeom_entries wingeom_entry
-               ;
- 
--wingeom_entry : string string { AddToList (&Scr->WindowGeometries, $1, $2) }
--
-+wingeom_entry : string string { AddToList (&Scr->WindowGeometries, $1, $2); }
-+              ;
- 
- 
- squeeze               : SQUEEZE_TITLE { 
-@@ -834,6 +834,7 @@
- occupy_workspc_entry  : string {
-                               AddToClientsList ($1, client);
-                         }
-+                      ;
- 
- occupy_window_list    : LB occupy_window_entries RB {}
-                       ;
-@@ -845,6 +846,7 @@
- occupy_window_entry   : string {
-                               AddToClientsList (workspace, $1);
-                         }
-+                      ;
- 
- icon_list     : LB icon_entries RB {}
-               ;
-@@ -962,6 +964,8 @@
-                                         RemoveDQuote(ptr);
-                                         $$ = (unsigned char*)ptr;
-                                       }
-+              ;
-+
- number                : NUMBER                { $$ = $1; }
-               ;
- 
Index: patches/patch-session.c
===================================================================
RCS file: /var/cvs/ports/x11/ctwm/patches/patch-session.c,v
retrieving revision 1.1
diff -u -p -r1.1 patch-session.c
--- patches/patch-session.c     5 Jul 2002 07:21:52 -0000       1.1
+++ patches/patch-session.c     21 Mar 2008 09:58:07 -0000
@@ -1,14 +1,14 @@
---- session.c.orig     Tue Dec 11 15:38:52 2001
-+++ session.c  Fri Jul  5 14:36:25 2002
-@@ -892,6 +892,7 @@
+--- session.c.orig     Fri Feb 16 10:24:27 2007
++++ session.c  Fri Mar 21 10:40:08 2008
+@@ -838,6 +838,7 @@ int GetWindowConfig (TwmWindow *theWindow, short *x, s
      return found;
  }
  
 +#ifndef __OpenBSD__
  /*===[ Unique Filename Generator 
]===========================================*/
  
- static char *
-@@ -922,6 +923,7 @@
+ static char *unique_filename (char *path, char *prefix)
+@@ -865,6 +866,7 @@ static char *unique_filename (char *path, char *prefix
  #endif
  }
  
@@ -16,10 +16,10 @@
  /*===[ SAVE WINDOW INFORMATION 
]=============================================*/
  
  #ifndef PATH_MAX
-@@ -951,6 +953,10 @@
+@@ -890,6 +892,10 @@ void SaveYourselfPhase2CB (SmcConn smcCon, SmPointer c
+     SmPropValue prop1val, prop2val, prop3val;
      char discardCommand[PATH_MAX + 4];
      int numVals, i;
-     char yes = 1;
 +#ifdef __OpenBSD__
 +    int tmphandle;
 +    char tmpprefix[256];
@@ -27,13 +27,13 @@
      static int first_time = 1;
  
      if (first_time)
-@@ -1003,12 +1009,20 @@
+@@ -942,12 +948,20 @@ void SaveYourselfPhase2CB (SmcConn smcCon, SmPointer c
       *        no longer the same since the new format supports
       *        virtaul workspaces.
       *========================================================*/
 +#ifdef __OpenBSD__
-+    strncpy(tmpprefix, path, 256);
-+    strncat(tmpprefix, "/.ctwmXXXXXX", (sizeof(path) - 12));
++    strlcpy(tmpprefix, path, 256);
++    strlcat(tmpprefix, "/.ctwmXXXXXX", (sizeof(path) - 12));
 +    if ((tmphandle = mkstemp(tmpprefix)) == -1)
 +      goto bad;
 +    if ((configFile = fdopen(tmphandle, "wb")) == NULL)
Index: pkg/PLIST
===================================================================
RCS file: /var/cvs/ports/x11/ctwm/pkg/PLIST,v
retrieving revision 1.4
diff -u -p -r1.4 PLIST
--- pkg/PLIST   15 Sep 2004 19:26:28 -0000      1.4
+++ pkg/PLIST   21 Mar 2008 09:58:07 -0000
@@ -1,5 +1,96 @@
[EMAIL PROTECTED] $OpenBSD: PLIST,v 1.4 2004/09/15 19:26:28 espie Exp $
[EMAIL PROTECTED] $OpenBSD$
 bin/ctwm
 lib/X11/twm/
+lib/X11/twm/images/
+lib/X11/twm/images/3D_Expand15.xpm
+lib/X11/twm/images/3D_Iconify15.xpm
+lib/X11/twm/images/3D_Lightning15.xpm
+lib/X11/twm/images/3D_Menu15.xpm
+lib/X11/twm/images/3D_Resize15.xpm
+lib/X11/twm/images/3D_Zoom15.xpm
+lib/X11/twm/images/3dcircle.xpm
+lib/X11/twm/images/3ddimple.xpm
+lib/X11/twm/images/3ddot.xpm
+lib/X11/twm/images/3dfeet.xpm
+lib/X11/twm/images/3dleopard.xpm
+lib/X11/twm/images/3dpie.xpm
+lib/X11/twm/images/3dpyramid.xpm
+lib/X11/twm/images/3dslant.xpm
+lib/X11/twm/images/IslandD.xpm
+lib/X11/twm/images/IslandW.xpm
+lib/X11/twm/images/LRom.xpm
+lib/X11/twm/images/LRom1.xpm
+lib/X11/twm/images/arthur.xpm
+lib/X11/twm/images/audio_editor.xpm
+lib/X11/twm/images/background1.xpm
+lib/X11/twm/images/background2.xpm
+lib/X11/twm/images/background3.xpm
+lib/X11/twm/images/background4.xpm
+lib/X11/twm/images/background5.xpm
+lib/X11/twm/images/background6.xpm
+lib/X11/twm/images/background7.xpm
+lib/X11/twm/images/background8.xpm
+lib/X11/twm/images/background9.xpm
+lib/X11/twm/images/ball1.xpm
+lib/X11/twm/images/ball10.xpm
+lib/X11/twm/images/ball11.xpm
+lib/X11/twm/images/ball12.xpm
+lib/X11/twm/images/ball2.xpm
+lib/X11/twm/images/ball3.xpm
+lib/X11/twm/images/ball4.xpm
+lib/X11/twm/images/ball5.xpm
+lib/X11/twm/images/ball6.xpm
+lib/X11/twm/images/ball7.xpm
+lib/X11/twm/images/ball8.xpm
+lib/X11/twm/images/ball9.xpm
+lib/X11/twm/images/cdrom1.xpm
+lib/X11/twm/images/claude.xpm
+lib/X11/twm/images/clipboard.xpm
+lib/X11/twm/images/datebook.xpm
+lib/X11/twm/images/emacs.xpm
+lib/X11/twm/images/ghostview.xpm
+lib/X11/twm/images/hpterm.xpm
+lib/X11/twm/images/mail0.xpm
+lib/X11/twm/images/mail1.xpm
+lib/X11/twm/images/nothing.xpm
+lib/X11/twm/images/nt1.xpm
+lib/X11/twm/images/nt2.xpm
+lib/X11/twm/images/pixmap.xpm
+lib/X11/twm/images/postit.xpm
+lib/X11/twm/images/skull.xpm
+lib/X11/twm/images/spider.xpm
+lib/X11/twm/images/supman1.xbm
+lib/X11/twm/images/supman2.xbm
+lib/X11/twm/images/supman3.xbm
+lib/X11/twm/images/supman4.xbm
+lib/X11/twm/images/supman5.xbm
+lib/X11/twm/images/supman6.xbm
+lib/X11/twm/images/supman7.xbm
+lib/X11/twm/images/supman8.xbm
+lib/X11/twm/images/supman9.xbm
+lib/X11/twm/images/term.xpm
+lib/X11/twm/images/unknown.xpm
+lib/X11/twm/images/unknown1.xpm
+lib/X11/twm/images/unread.xpm
+lib/X11/twm/images/welcome.xpm
+lib/X11/twm/images/welcome.xwd
+lib/X11/twm/images/xarchie.xpm
+lib/X11/twm/images/xcalc.xpm
+lib/X11/twm/images/xcalc2.xpm
+lib/X11/twm/images/xedit.xpm
+lib/X11/twm/images/xftp.xpm
+lib/X11/twm/images/xgopher.xpm
+lib/X11/twm/images/xgrab.xpm
+lib/X11/twm/images/xhpcalc.xpm
+lib/X11/twm/images/xirc.xpm
+lib/X11/twm/images/xmail.xpm
+lib/X11/twm/images/xman.xpm
+lib/X11/twm/images/xmosaic.xpm
+lib/X11/twm/images/xnomail.xpm
+lib/X11/twm/images/xrn-compose.xpm
+lib/X11/twm/images/xrn.goodnews.xpm
+lib/X11/twm/images/xrn.nonews.xpm
+lib/X11/twm/images/xrn.xpm
+lib/X11/twm/images/xterm.xpm
 lib/X11/twm/system.ctwmrc
 @man man/cat1/ctwm.0

Reply via email to