EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  <20082009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  <20082009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: msi1_4 build - compile against base 3.14.10 crashes - `TRUE' undefinded
From: "J. Lewis Muir" <[email protected]>
To: Peter Zumbruch <[email protected]>
Cc: EPICS tech-talk <[email protected]>
Date: Mon, 10 Nov 2008 14:17:18 -0500
On 11/10/08 12:49 PM, Peter Zumbruch wrote:
> Hi,
> 
> I am facing the following problem.
> I try to compile msi 1.4 using base 3.14.10.
> I get the following crash.
> 
> make -C ./msi1_4 install
> make[1]: Entering directory `<EPICS Extension Dir>/src/msi1_4'
> make -C O.linux-x86 -f ../Makefile TOP=../../.. T_A=linux-x86 install
> make[2]: Entering directory `<EPICS Extension Dir>/src/msi1_4/O.linux-x86'
> /usr/bin/gcc-3.4 -c   -D_POSIX_C_SOURCE=199506L -D_POSIX_THREADS
> -D_XOPEN_SOURCE=500 -D_X86_ -DUNIX  -D_BSD_SOURCE -Dlinux  -D_REENTRANT
> -ansi   -O3   -Wall      -m32     -g  -I. -I../O.Common -I. -I..
> -I../../../include/os/Linux -I../../../include
> -I../../../../base-3.14.10/include/os/Linux
> -I../../../../base-3.14.10/include  -I../../../include          ../msi.c
> ../msi.c: In function `main':
> ../msi.c:69: error: `TRUE' undeclared (first use in this function)
> ../msi.c:69: error: (Each undeclared identifier is reported only once
> ../msi.c:69: error: for each function it appears in.)
> ../msi.c:86: error: `FALSE' undeclared (first use in this function)
> ../msi.c: In function `makeSubstitutions':
> ../msi.c:167: error: `TRUE' undeclared (first use in this function)
> ../msi.c:225: error: `FALSE' undeclared (first use in this function)
> ../msi.c: In function `inputAddPath':
> ../msi.c:298: error: `TRUE' undeclared (first use in this function)
> ../msi.c:298: error: `FALSE' undeclared (first use in this function)
> ../msi.c: In function `freePattern':
> ../msi.c:506: error: `FALSE' undeclared (first use in this function)
> ../msi.c: In function `substituteGetNextSet':
> ../msi.c:551: error: `FALSE' undeclared (first use in this function)
> ../msi.c:553: error: `TRUE' undeclared (first use in this function)
> ../msi.c: In function `substituteGetReplacements':
> ../msi.c:616: error: `FALSE' undeclared (first use in this function)
> ../msi.c:630: error: `TRUE' undeclared (first use in this function)
> ../msi.c: At top level:
> ../msi.c:487: warning: 'freeSubFile' defined but not used
> make[2]: *** [msi.o] Error 1
> make[2]: Leaving directory `<EPICS Extension Dir>/src/msi1_4/O.linux-x86'
> make[1]: *** [install.linux-x86] Error 2
> make[1]: Leaving directory `<EPICS Extension Dir>/src/msi1_4'
> make: *** [msi1_4.install] Error 2
> 
> 
> My system is a debian sarge (3.1) clone using gcc3.4 and gmake 3.81.
> 
> Any idea?
> Hints would be appreciated.
> 
> Compiling the same code against 3.14.9 succeeds.
> 
> Best regards,
> Peter

Hi, Peter.

I have the same problem on Mac OS X 10.5.5.  It seems that msi.c expects
TRUE and FALSE to be defined.  If I include dbDefs.h, which includes
defines for these, it will successfully compile.  Attached is a patch.
However, I don't know what the intended use of dbDefs.h is.  It could be
that this should not be used by msi.  If this is the case, then one
could just define TRUE and FALSE in msi.c like this:

  #define TRUE  1
  #define FALSE 0

Or, one could replace all the TRUE and FALSE references in the file to 1
and 0 respectively.

Lewis
--- msi.c.orig	2004-06-14 14:02:00.000000000 -0400
+++ msi.c	2008-11-10 14:07:57.000000000 -0500
@@ -21,6 +21,7 @@
 #include <ctype.h>
 #include <errno.h>
  
+#include <dbDefs.h>
 #include <macLib.h>
 #include <ellLib.h>
 

References:
msi1_4 build - compile against base 3.14.10 crashes - `TRUE' undefinded Peter Zumbruch

Navigate by Date:
Prev: Re: msi1_4 build - compile against base 3.14.10 crashes - `TRUE' undefinded Andrew Johnson
Next: C++ and genSubRecord.h Pierrick Hanlet
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  <20082009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: msi1_4 build - compile against base 3.14.10 crashes - `TRUE' undefinded Andrew Johnson
Next: C++ and genSubRecord.h Pierrick Hanlet
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  <20082009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 02 Sep 2010 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·