Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 5 Apr 2002 16:04:23 -0500
From:      The Anarcat <anarcat@anarcat.dyndns.org>
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        anarcat@anarcat.dyndns.org
Subject:   ports/36800: tvision 0.8 port upgrade breaks libh
Message-ID:  <20020405210524.7BA5018B9@khan.anarcat.dyndns.org>

next in thread | raw e-mail | index | archive | help

>Number:         36800
>Category:       ports
>Synopsis:       tvision 0.8 port upgrade breaks libh
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    freebsd-ports
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Apr 05 13:10:01 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     The Anarcat
>Release:        FreeBSD 4.5-STABLE i386
>Organization:
Nada, Inc.
>Environment:
System: FreeBSD lenny.anarcat.dyndns.org 4.5-STABLE FreeBSD 4.5-STABLE #1: Wed Mar 27 12:55:29 EST 2002 anarcat@lenny.anarcat.dyndns.org:/usr/src/sys/compile/LENNY i386

tvision 0.8 and libh 0.2.1

>Description:

The devel/tvision 0.8 update change endianess handling by using a
header file called "myendian.h" in the tvision source.

For some reason, this file doesn't get installed with tvision. But not
only that, the system.h file from tvision tries to include it using
<myendian.h> which should be instead <tvision/myendian.h>.

The file is also misplaced in the distro.

The errors reported by the libh build look like this:

/usr/local/include/tvision/drawbuf.h:113: myendian.h: No such file or
directory

>How-To-Repeat:

cd /usr/ports/misc/libh && make

>Fix:

Workaround: use tvision 0.7

Fix:

Plan A: (see also plan B below)

1- these diffs go into files/

[files/patch::lib-system.h]

--- lib/system.h.orig	Fri Apr  5 15:25:19 2002
+++ lib/system.h	Fri Apr  5 15:25:33 2002
@@ -182,7 +182,7 @@
     uchar buttons;
 };
 
-#include <myendian.h>
+#include <tvision/myendian.h>
 
 /**
  * This structure stores information about a key.

2- 

[files/patch::lib/Makefile.am]

--- Makefile.am.orig	Fri Apr  5 15:26:19 2002
+++ Makefile.am	Fri Apr  5 15:26:42 2002
@@ -14,7 +14,7 @@
 
 pkginclude_HEADERS = \
 app.h buffers.h colorsel.h dialogs.h drawbuf.h editors.h \
-help.h helpbase.h menus.h msgbox.h objects.h outline.h resource.h \
+help.h helpbase.h menus.h msgbox.h myendian.h objects.h outline.h resource.h \
 stddlg.h system.h textview.h tkeys.h tobjstrm.h ttypes.h tv.h \
 tvconfig.h tvobjs.h util.h validate.h views.h
 
3- I think the .in file also needs patching:

[files/patch::lib-Makefile.in]

--- lib/Makefile.in.orig	Fri Apr  5 15:35:02 2002
+++ lib/Makefile.in	Fri Apr  5 15:35:17 2002
@@ -86,7 +86,7 @@
 
 pkginclude_HEADERS = \
 app.h buffers.h colorsel.h dialogs.h drawbuf.h editors.h \
-help.h helpbase.h menus.h msgbox.h objects.h outline.h resource.h \
+help.h helpbase.h menus.h msgbox.h myendian.h objects.h outline.h resource.h \
 stddlg.h system.h textview.h tkeys.h tobjstrm.h ttypes.h tv.h \
 tvconfig.h tvobjs.h util.h validate.h views.h
 

4-

[files/patch-lib::drawbuf.h]

--- lib/drawbuf.h.orig	Fri Apr  5 15:51:31 2002
+++ lib/drawbuf.h	Fri Apr  5 15:51:40 2002
@@ -110,7 +110,7 @@
     ushort data[maxViewWidth];
 };
 
-#include <myendian.h>
+#include <tvision/myendian.h>
 
 #if (BYTE_ORDER == LITTLE_ENDIAN)
 	#define loByte(w)    (((uchar *)&w)[0])

5- for some odd reason, the myendian.h file is not with the other
header files (lib/) but in ./ :

--- /usr/ports/deve/tvision/Makefile.orig	Fri Apr  5 15:43:41 2002
+++ /usr/ports/deve/tvision/Makefile	Fri Apr  5 15:42:00 2002
@@ -18,4 +18,7 @@
 CONFIGURE_TARGET=	--build=${ARCH}-portbld-freebsd${OSREL}
 INSTALLS_SHLIB=	yes
 
+pre-patch:
+	mv ${WRKSRC}/myendian.h ${WRKSRC}/lib/myendian.h
+
 .include <bsd.port.mk>


6- finally, the pkg-list needs patching:

--- /usr/ports/devel/tvision/pkg-plist.orig	Fri Apr  5 15:37:53 2002
+++ /usr/ports/devel/tvision/pkg-plist	Fri Apr  5 15:38:06 2002
@@ -8,6 +8,7 @@
 include/tvision/helpbase.h
 include/tvision/menus.h
 include/tvision/msgbox.h
+include/tvision/myendian.h
 include/tvision/objects.h
 include/tvision/outline.h
 include/tvision/resource.h

Plan B: patch system.h to use the old way of doing things:

anarcat@lenny[~/src/ports/distfiles]% diff -u tvision-0.7/lib/system.h tvision-0.8/lib/system.h | grep -5 endian
      */
     uchar buttons;
 };
 
-#ifdef __FreeBSD__
-#include <machine/endian.h>
-#else
-#include <endian.h>
-#endif
+#include <tvision/myendian.h>
 
 /**
- * This structure stores informations about a key.
+ * This structure stores information about a key.
  * @see KeyDownEvent


>Release-Note:
>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020405210524.7BA5018B9>