Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: build problem with patch level 1.5301



On May 13,  8:13pm, S. Cowles wrote:
}
} gcc -c -I. -I../Src -I../Src -I../Src/Zle -I.  -DHAVE_CONFIG_H -Wall -Wmissing-prototypes -O2  -o builtin.o builtin.c
} In file included from zsh.mdh:49:0,
}                   from builtin.c:33:
} mem.epro:5:35: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'last_heap_id'

Hmm, the script that generates zsh.mdh doesn't know about #ifdef,
so it tries to export a variable that's declared conditionally in
mem.c.

All that's really necessary, though, is to make the typedef for
"Heapid" visible regardless of whether ZSH_HEAP_DEBUG is defined.

Index: Src/zsh.h
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/zsh.h,v
retrieving revision 1.175
diff -u -r1.175 zsh.h
--- Src/zsh.h   14 May 2011 00:07:42 -0000      1.175
+++ Src/zsh.h   14 May 2011 03:59:32 -0000
@@ -2327,7 +2327,6 @@
  * Memory management *
  *********************/
 
-#ifdef ZSH_HEAP_DEBUG
 /*
  * A Heapid is a type for identifying, uniquely up to the point where
  * the count of new identifiers wraps. all heaps that are or
@@ -2341,6 +2340,8 @@
  */
 typedef unsigned int Heapid;
 
+#ifdef ZSH_HEAP_DEBUG
+
 /* printf format specifier corresponding to Heapid */
 #define HEAPID_FMT     "%x"
 

-- 



Messages sorted by: Reverse Date, Date, Thread, Author