Bug 537

Summary: cannot build the "Hello World" Yocto SDK project
Product: [Yocto Project Subprojects] Eclipse Plugin Reporter: Anna Dushistova <anna.dushistova>
Component: eclipse-pluginAssignee: Jessica <jessica.zhang>
Status: RESOLVED NOTABUG QA Contact:
Severity: normal    
Priority: Medium CC: kevin.tian, lianhao.lu, liping.ke, sgw, yp.ep.watcher, yp.watcher
Version: 1.0   
Target Milestone: 1.0 M1   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: ---

Description Anna Dushistova 2010-11-15 12:06:26 UTC
Configure phase has errors, here is the log:

Invoking autogen.sh in build directory: /home/anna/yocto-test-workspace/test-yocto-2

sh /home/anna/yocto-test-workspace/test-yocto-2/autogen.sh --target=arm-poky-linux-gnueabi --host=arm-poky-linux-gnueabi --build=i586-linux 
configure.ac:24: error: AC_SUBST: `test-yocto-2_CFLAGS' is not a valid shell variable name
configure.ac:24: the top level
autom4te: /usr/bin/m4 failed with exit status: 1
aclocal: autom4te failed with exit status: 1
configure.ac:24: error: AC_SUBST: `test-yocto-2_CFLAGS' is not a valid shell variable name
configure.ac:24: the top level
autom4te: /usr/bin/m4 failed with exit status: 1
configure.ac:24: error: AC_SUBST: `test-yocto-2_CFLAGS' is not a valid shell variable name
configure.ac:24: the top level
autom4te: /usr/bin/m4 failed with exit status: 1
autoheader: '/usr/bin/autom4te' failed with exit status: 1
configure.ac:24: error: AC_SUBST: `test-yocto-2_CFLAGS' is not a valid shell variable name
configure.ac:24: the top level
autom4te: /usr/bin/m4 failed with exit status: 1
automake: autoconf failed with exit status: 1
/home/anna/yocto-test-workspace/test-yocto-2/autogen.sh: line 9: ./configure: No such file or directory

Configuration failed with error
Comment 1 Jessica 2010-11-15 14:21:17 UTC
Hi Anna,

First of all, I'd like to thank you for keeping trying things out with our plug-in and reporting issues to us.

Now as to the problem, I can reproduce it myself and after investigating further, it turned out it's really the autoconf's issue/feature which the AC_SUBST macro is picky about the passing in variable "test-yocto-2_CFLAGS", so if you change test-yocto-2 to testYocto2, the autoconf will pass.  I've played a little bit further, if I remove the AC_SUBST from configure.ac, the test-yocto-2 name will be further complained by Makefile.am which it will try to change it to test_yocto_2, seems somehow the autoconf tools doesn't like "-" in the variable...