pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/55840: mutt-2.0.2 slang build with pkgsrc patch-color.c patch fails



>Number:         55840
>Category:       pkg
>Synopsis:       mutt-2.0.2 slang build with pkgsrc patch-color.c patch fails
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Dec 04 15:05:00 +0000 2020
>Originator:     Ken Dunlap
>Release:        NetBSD-9
>Organization:
PANIX
>Environment:
NetBSD juggler.panix.com 9.0 NetBSD 9.0 (PANIX-STD) #7: Sun May  3 21:08:07 EDT 2020  root%juggler.panix.com@localhost:/misc/obj64/misc/devel/netbsd/9.0/src/sys/arch/amd64/compile/PANIX-STD amd64
>Description:
The patch causes the preprocessor to use the wrong defines when building with slang on NetBSD.
>How-To-Repeat:
Apply patch, configure using slang, build.  Error output:

color.c:264:33: error: use of undeclared identifier 'A_ATTRIBUTES'
  merged_pair |= (source_pair & ATTR_MASK) | (overlay_pair & ATTR_MASK);
                                ^
color.c:123:20: note: expanded from macro 'ATTR_MASK'
#define ATTR_MASK (A_ATTRIBUTES ^ A_COLOR)
                   ^
color.c:264:62: error: use of undeclared identifier 'A_ATTRIBUTES'
  merged_pair |= (source_pair & ATTR_MASK) | (overlay_pair & ATTR_MASK);
                                                             ^
color.c:123:20: note: expanded from macro 'ATTR_MASK'
#define ATTR_MASK (A_ATTRIBUTES ^ A_COLOR)
                   ^
2 errors generated.
>Fix:
Revised patch:

--- color.c.orig        2020-12-03 11:40:02.377302672 -0500
+++ color.c     2020-12-03 11:43:57.080051289 -0500
@@ -119,7 +119,7 @@

 #define COLOR_QUOTE_INIT       8

-#ifdef NCURSES_VERSION
+#if defined(NCURSES_VERSION) || (defined(__NetBSD__) && !defined(USE_SLANG_CURSES))
 #define ATTR_MASK (A_ATTRIBUTES ^ A_COLOR)
 #elif defined (USE_SLANG_CURSES)
 #define ATTR_MASK (~(unsigned int)A_NORMAL ^ (A_CHARTEXT | A_UNUSED | A_COLOR))


Home | Main Index | Thread Index | Old Index