tinyos / nesc

Master nesc repository
GNU General Public License v2.0
100 stars 53 forks source link

AST_types.h:63:21: error: ‘nil’ undeclared here (not in a function) #26

Closed fossterer closed 10 years ago

fossterer commented 10 years ago

While trying to build Nesc for the installation of TinyOS, I receive this error. Here's an extract from my build logs:

... gcc -DHAVE_CONFIG_H -I. -I./libcompat -I./../libcpp/include -I./../libcpp -I./../include -g -Wall -Wno-long-double -MT AST.o -MD -MP -MF .deps/AST.Tpo -c -o AST.o AST.c In file included from AST.h:46:0, from parser.h:36, from AST.c:22: AST_types.h:63:21: error: ‘nil’ undeclared here (not in a function) kind_error_decl = nil, ...

bradjc commented 10 years ago

What version of emacs do you have installed? It seems that lisp interpreter in version 24.3.* doesn't work with nesc (although I have no idea why). See issue #12.

antoniolm23 commented 10 years ago

Thank you for the reply, I have 24.3.1 version of emacs!

2014-05-10 5:39 GMT+02:00 Brad Campbell notifications@github.com:

What version of emacs do you have installed? It seems that lisp interpreter in version 24.3.* doesn't work with nesc (although I have no idea why). See issue #12 https://github.com/tinyos/nesc/issues/12.

— Reply to this email directly or view it on GitHubhttps://github.com/tinyos/nesc/issues/26#issuecomment-42730734 .

dgay42 commented 10 years ago

It's name collisions (emacs now reserves some identifiers that are used in the .el files). Fix coming soon.

fossterer commented 10 years ago

@bradjc Yeah, I have emacs 24.3.1. Thanks for clarifying. @dgay42 'Name collision for being a reserved word'? What does 'nil' mean in a .c file at all?

dgay42 commented 10 years ago

Name collision in the emacs lisp that generates the .c file. Could have failed more gracefully than by generating invalid C code...

Fixed in https://github.com/tinyos/nesc/commit/da4a54897562f030dc9dfcd7f9942f6a9e79785e

fossterer commented 10 years ago

Woww! That's real quick! Thanks for the fix @dgay42

dayDPTR commented 6 years ago

Hi, ALL

the issue happens when i build nescc based on nesc-1.3.3 source code, so i merge the https://github.com/tinyos/nesc/commit/da4a54897562f030dc9dfcd7f9942f6a9e79785e to nesc-1.3.3 source code and then execute "make" command, it always report the same error: AST_types.h:63:21: error: ‘nil’ undeclared here (not in a function)

could you help me slove this problem ? Thanks. @dgay42 @bradjc @cire831 @tyll

cire831 commented 6 years ago

why are you using 1.3.3?

current release is 1.3.6

dayDPTR commented 6 years ago

Very thanks! reply is so quick! @cire831 l can build nescc based on nesc-1.3.6 source code successfully, but now, members in our lab all do WSN research and coding based on tinyos and nesc-1.3.3 ( we built tinyos development environment in Mac-OSX and unfortunately there is something wrong with my macbook), therefore, i have to build tinyos development environment in linux temporarily. We plan to update our development environment together after we finish current project. I carefully check necessary software version: automake-1.15 autoconf- 2.69 emacs-24.5.1 gperf-3.0.4 bison-3.0.4 flex-2.6.0 I cannot determine whether the fault version of these software causes this build error,

cire831 commented 6 years ago

Okay. but no idea.

On Sun, Sep 10, 2017 at 6:47 PM, ryanee notifications@github.com wrote:

Very thanks! reply is so quick! @cire831 https://github.com/cire831 l can build nescc based on nesc-1.3.6 source code successfully, but now, members in our lab all do WSN research and coding based on tinyos and nesc-1.3.3 ( we built tinyos development environment in Mac-OSX and unfortunately there is something wrong with my macbook), therefore, i have to build tinyos development environment in linux temporarily. We plan to update our development environment together after we finish current project. I carefully check necessary software version: automake-1.15 autoconf- 2.69 emacs-24.5.1 gperf-3.0.4 bison-3.0.4 flex-2.6.0 I cannot determine whether the fault version of these software causes this build error,

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/tinyos/nesc/issues/26#issuecomment-328394737, or mute the thread https://github.com/notifications/unsubscribe-auth/AAY46Sl-F7ci8lo0symhPy_7GuCaFC2nks5shJEYgaJpZM4B33pm .

-- Eric B. Decker Senior (over 50 :-) Researcher