public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] Confusing compilation problem
@ 2009-04-10  7:47 grahamlab
  2009-04-10  7:59 ` Sergei Gavrikov
  0 siblings, 1 reply; 9+ messages in thread
From: grahamlab @ 2009-04-10  7:47 UTC (permalink / raw)
  To: ecos-discuss


Hello all
I am trying to evaluate the best way for me to use ecos for my project - to
use the configtool or command line interface.
So I 
1.created an ecos build using from command line using the default template.
2.executed the make command to build ecos
3.created a testbed directory and created a hello world application
4.compiled and linked successfully
Next I
1 created an ecos build using the configuration tool
2 created a test bed directory and created a hello world application
3 this does not compile and gives the following errors -
test.cpp: In function ‘int main()’:
test.cpp:6: error: ‘printf’ was not declared in this scope

Both use the same makefile and make.params files(atached) - the only changes
were to point to the correct install directory.
If I point the configtool version at the commandline version install tree it
will compile

Could some one explain why this is?

Thanks

http://www.nabble.com/file/p22984314/configtool_Make.params
configtool_Make.params 
http://www.nabble.com/file/p22984314/configtool_Makefile configtool_Makefile 
http://www.nabble.com/file/p22984314/cli_Make.params cli_Make.params 
http://www.nabble.com/file/p22984314/cli_Makefile cli_Makefile 
Graham

-- 
View this message in context: http://www.nabble.com/Confusing-compilation-problem-tp22984314p22984314.html
Sent from the Sourceware - ecos-discuss mailing list archive at Nabble.com.


--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [ECOS] Confusing compilation problem
  2009-04-10  7:47 [ECOS] Confusing compilation problem grahamlab
@ 2009-04-10  7:59 ` Sergei Gavrikov
  2009-04-10  8:05   ` grahamlab
  0 siblings, 1 reply; 9+ messages in thread
From: Sergei Gavrikov @ 2009-04-10  7:59 UTC (permalink / raw)
  To: grahamlab; +Cc: ecos-discuss

On Fri, Apr 10, 2009 at 12:30:56AM -0700, grahamlab wrote:
> 
> Hello all
> I am trying to evaluate the best way for me to use ecos for my project - to
> use the configtool or command line interface.
> So I 
> 1.created an ecos build using from command line using the default template.
> 2.executed the make command to build ecos
> 3.created a testbed directory and created a hello world application
> 4.compiled and linked successfully
> Next I
> 1 created an ecos build using the configuration tool
> 2 created a test bed directory and created a hello world application
> 3 this does not compile and gives the following errors -
> test.cpp: In function ‘int main()’:
> test.cpp:6: error: ‘printf’ was not declared in this scope
> 
> Both use the same makefile and make.params files(atached) - the only changes
> were to point to the correct install directory.

Graham, not only

  /tmp$ diff configtool_Make.params cli_Make.params 
  5c5
  < export PREFIX := /home/graham/ecos/DevBoard_install
  ---
  > export PREFIX := /home/graham/lab1/install
  7c7
  < export CC := $(COMMAND_PREFIX)gcc
  ---
  > export CC := $(COMMAND_PREFIX)g++


  /tmp$ diff configtool_Makefile cli_Makefile


Are you really going program in C++? Try rename your main.cpp in the
main.c.

BTW, the short plain text files you can just attach.

Sergei.

> If I point the configtool version at the commandline version install tree it
> will compile
> 
> Could some one explain why this is?
> 
> Thanks
> 
> http://www.nabble.com/file/p22984314/configtool_Make.params
> configtool_Make.params 
> http://www.nabble.com/file/p22984314/configtool_Makefile configtool_Makefile 
> http://www.nabble.com/file/p22984314/cli_Make.params cli_Make.params 
> http://www.nabble.com/file/p22984314/cli_Makefile cli_Makefile 
> Graham
> 
> -- 
> View this message in context: http://www.nabble.com/Confusing-compilation-problem-tp22984314p22984314.html
> Sent from the Sourceware - ecos-discuss mailing list archive at Nabble.com.
> 
> 
> --
> Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
> and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [ECOS] Confusing compilation problem
  2009-04-10  7:59 ` Sergei Gavrikov
@ 2009-04-10  8:05   ` grahamlab
  2009-04-10  8:10     ` Sergei Gavrikov
  0 siblings, 1 reply; 9+ messages in thread
From: grahamlab @ 2009-04-10  8:05 UTC (permalink / raw)
  To: ecos-discuss




Sergei Gavrikov-4 wrote:
> 
> On Fri, Apr 10, 2009 at 12:30:56AM -0700, grahamlab wrote:
>> 
>> Hello all
>> I am trying to evaluate the best way for me to use ecos for my project -
>> to
>> use the configtool or command line interface.
>> So I 
>> 1.created an ecos build using from command line using the default
>> template.
>> 2.executed the make command to build ecos
>> 3.created a testbed directory and created a hello world application
>> 4.compiled and linked successfully
>> Next I
>> 1 created an ecos build using the configuration tool
>> 2 created a test bed directory and created a hello world application
>> 3 this does not compile and gives the following errors -
>> test.cpp: In function ‘int main()’:
>> test.cpp:6: error: ‘printf’ was not declared in this scope
>> 
>> Both use the same makefile and make.params files(atached) - the only
>> changes
>> were to point to the correct install directory.
> 
> Graham, not only
> 
>   /tmp$ diff configtool_Make.params cli_Make.params 
>   5c5
>   < export PREFIX := /home/graham/ecos/DevBoard_install
>   ---
>   > export PREFIX := /home/graham/lab1/install
>   7c7
>   < export CC := $(COMMAND_PREFIX)gcc
>   ---
>   > export CC := $(COMMAND_PREFIX)g++
> 
> 
>   /tmp$ diff configtool_Makefile cli_Makefile
> 
> 
> Are you really going program in C++? Try rename your main.cpp in the
> main.c.
> 
> BTW, the short plain text files you can just attach.
> 
> Sergei.
> 
>> If I point the configtool version at the commandline version install tree
>> it
>> will compile
>> 
>> Could some one explain why this is?
>> 
>> Thanks
>> 
>> http://www.nabble.com/file/p22984314/configtool_Make.params
>> configtool_Make.params 
>> http://www.nabble.com/file/p22984314/configtool_Makefile
>> configtool_Makefile 
>> http://www.nabble.com/file/p22984314/cli_Make.params cli_Make.params 
>> http://www.nabble.com/file/p22984314/cli_Makefile cli_Makefile 
>> Graham
>> 
>> -- 
>> View this message in context:
>> http://www.nabble.com/Confusing-compilation-problem-tp22984314p22984314.html
>> Sent from the Sourceware - ecos-discuss mailing list archive at
>> Nabble.com.
>> 
>> 
>> --
>> Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
>> and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
> 
> -- 
> Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
> and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
> 
> 
> 
Helo again Sergei

Beleive me I have tried muliple permutations using both g++ and gcc
The cli vesrion compile with both g++ and gcc
The config tool version compiles with neither.

It seems that you cannot switch between a cli build and a configtool build
I am a little confused but will investigate further.
Do you use the cli exclusively or do you switch between the 2?

Graham
-- 
View this message in context: http://www.nabble.com/Confusing-compilation-problem-tp22984314p22984595.html
Sent from the Sourceware - ecos-discuss mailing list archive at Nabble.com.


--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [ECOS] Confusing compilation problem
  2009-04-10  8:05   ` grahamlab
@ 2009-04-10  8:10     ` Sergei Gavrikov
  2009-04-10  8:19       ` grahamlab
  0 siblings, 1 reply; 9+ messages in thread
From: Sergei Gavrikov @ 2009-04-10  8:10 UTC (permalink / raw)
  To: grahamlab; +Cc: ecos-discuss

On Fri, Apr 10, 2009 at 12:59:19AM -0700, grahamlab wrote:
> Sergei Gavrikov-4 wrote:
> > 
> > On Fri, Apr 10, 2009 at 12:30:56AM -0700, grahamlab wrote:
> >> 
> >> Hello all
> >> I am trying to evaluate the best way for me to use ecos for my project -
> >> to
> >> use the configtool or command line interface.
> >> So I 
> >> 1.created an ecos build using from command line using the default
> >> template.
> >> 2.executed the make command to build ecos
> >> 3.created a testbed directory and created a hello world application
> >> 4.compiled and linked successfully
> >> Next I
> >> 1 created an ecos build using the configuration tool
> >> 2 created a test bed directory and created a hello world application
> >> 3 this does not compile and gives the following errors -
> >> test.cpp: In function ‘int main()’:
> >> test.cpp:6: error: ‘printf’ was not declared in this scope
> >> 
> >> Both use the same makefile and make.params files(atached) - the only
> >> changes
> >> were to point to the correct install directory.
> > 
> > Graham, not only
> > 
> >   /tmp$ diff configtool_Make.params cli_Make.params 
> >   5c5
> >   < export PREFIX := /home/graham/ecos/DevBoard_install
> >   ---
> >   > export PREFIX := /home/graham/lab1/install
> >   7c7
> >   < export CC := $(COMMAND_PREFIX)gcc
> >   ---
> >   > export CC := $(COMMAND_PREFIX)g++
> > 
> > 
> >   /tmp$ diff configtool_Makefile cli_Makefile
> > 
> > 
> > Are you really going program in C++? Try rename your main.cpp in the
> > main.c.
> > 
> > BTW, the short plain text files you can just attach.
> > 
> > Sergei.
> > 
> >> If I point the configtool version at the commandline version install tree
> >> it
> >> will compile
> >> 
> >> Could some one explain why this is?
> >> 
> >> Thanks
> >> 
> >> http://www.nabble.com/file/p22984314/configtool_Make.params
> >> configtool_Make.params 
> >> http://www.nabble.com/file/p22984314/configtool_Makefile
> >> configtool_Makefile 
> >> http://www.nabble.com/file/p22984314/cli_Make.params cli_Make.params 
> >> http://www.nabble.com/file/p22984314/cli_Makefile cli_Makefile 
> >> Graham
> >> 
> >> -- 
> >> View this message in context:
> >> http://www.nabble.com/Confusing-compilation-problem-tp22984314p22984314.html
> >> Sent from the Sourceware - ecos-discuss mailing list archive at
> >> Nabble.com.
> >> 
> >> 
> >> --
> >> Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
> >> and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
> > 
> > -- 
> > Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
> > and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
> > 
> > 
> > 
> Helo again Sergei
> 
> Beleive me I have tried muliple permutations using both g++ and gcc

I hope that your Make.params were not handy tweaked.

> The cli vesrion compile with both g++ and gcc
> The config tool version compiles with neither.
> 
> It seems that you cannot switch between a cli build and a configtool build
> I am a little confused but will investigate further.
> Do you use the cli exclusively or do you switch between the 2?

I have used CLI only, but I have eCos configtool installed too. I will
try to reproduce your issue.

Sergei

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [ECOS] Confusing compilation problem
  2009-04-10  8:10     ` Sergei Gavrikov
@ 2009-04-10  8:19       ` grahamlab
  2009-04-10  8:22         ` grahamlab
  2009-04-10  8:38         ` Sergei Gavrikov
  0 siblings, 2 replies; 9+ messages in thread
From: grahamlab @ 2009-04-10  8:19 UTC (permalink / raw)
  To: ecos-discuss




Sergei Gavrikov-4 wrote:
> 
> On Fri, Apr 10, 2009 at 12:59:19AM -0700, grahamlab wrote:
>> Sergei Gavrikov-4 wrote:
>> > 
>> > On Fri, Apr 10, 2009 at 12:30:56AM -0700, grahamlab wrote:
>> >> 
>> >> Hello all
>> >> I am trying to evaluate the best way for me to use ecos for my project
>> -
>> >> to
>> >> use the configtool or command line interface.
>> >> So I 
>> >> 1.created an ecos build using from command line using the default
>> >> template.
>> >> 2.executed the make command to build ecos
>> >> 3.created a testbed directory and created a hello world application
>> >> 4.compiled and linked successfully
>> >> Next I
>> >> 1 created an ecos build using the configuration tool
>> >> 2 created a test bed directory and created a hello world application
>> >> 3 this does not compile and gives the following errors -
>> >> test.cpp: In function ‘int main()’:
>> >> test.cpp:6: error: ‘printf’ was not declared in this scope
>> >> 
>> >> Both use the same makefile and make.params files(atached) - the only
>> >> changes
>> >> were to point to the correct install directory.
>> > 
>> > Graham, not only
>> > 
>> >   /tmp$ diff configtool_Make.params cli_Make.params 
>> >   5c5
>> >   < export PREFIX := /home/graham/ecos/DevBoard_install
>> >   ---
>> >   > export PREFIX := /home/graham/lab1/install
>> >   7c7
>> >   < export CC := $(COMMAND_PREFIX)gcc
>> >   ---
>> >   > export CC := $(COMMAND_PREFIX)g++
>> > 
>> > 
>> >   /tmp$ diff configtool_Makefile cli_Makefile
>> > 
>> > 
>> > Are you really going program in C++? Try rename your main.cpp in the
>> > main.c.
>> > 
>> > BTW, the short plain text files you can just attach.
>> > 
>> > Sergei.
>> > 
>> >> If I point the configtool version at the commandline version install
>> tree
>> >> it
>> >> will compile
>> >> 
>> >> Could some one explain why this is?
>> >> 
>> >> Thanks
>> >> 
>> >> http://www.nabble.com/file/p22984314/configtool_Make.params
>> >> configtool_Make.params 
>> >> http://www.nabble.com/file/p22984314/configtool_Makefile
>> >> configtool_Makefile 
>> >> http://www.nabble.com/file/p22984314/cli_Make.params cli_Make.params 
>> >> http://www.nabble.com/file/p22984314/cli_Makefile cli_Makefile 
>> >> Graham
>> >> 
>> >> -- 
>> >> View this message in context:
>> >>
>> http://www.nabble.com/Confusing-compilation-problem-tp22984314p22984314.html
>> >> Sent from the Sourceware - ecos-discuss mailing list archive at
>> >> Nabble.com.
>> >> 
>> >> 
>> >> --
>> >> Before posting, please read the FAQ:
>> http://ecos.sourceware.org/fom/ecos
>> >> and search the list archive:
>> http://ecos.sourceware.org/ml/ecos-discuss
>> > 
>> > -- 
>> > Before posting, please read the FAQ:
>> http://ecos.sourceware.org/fom/ecos
>> > and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
>> > 
>> > 
>> > 
>> Helo again Sergei
>> 
>> Beleive me I have tried muliple permutations using both g++ and gcc
> 
> I hope that your Make.params were not handy tweaked.
> 
>> The cli vesrion compile with both g++ and gcc
>> The config tool version compiles with neither.
>> 
>> It seems that you cannot switch between a cli build and a configtool
>> build
>> I am a little confused but will investigate further.
>> Do you use the cli exclusively or do you switch between the 2?
> 
> I have used CLI only, but I have eCos configtool installed too. I will
> try to reproduce your issue.
> 
> Sergei
> 
> -- 
> Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
> and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
> 
> 
> 
Hi Sergei
I have been looking at the stdio.h file in both install trees.
The files are exactly the same but in the CLI version things like 
CYGINT_ISO_STDIO_FILETYPES are defined
but in the configtool version they are not - so the correct includes are not
generated.
Where do things like CYGINT_ISO_STDIO_FILETYPES get defined?

Graham
-- 
View this message in context: http://www.nabble.com/Confusing-compilation-problem-tp22984314p22984655.html
Sent from the Sourceware - ecos-discuss mailing list archive at Nabble.com.


--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [ECOS] Confusing compilation problem
  2009-04-10  8:19       ` grahamlab
@ 2009-04-10  8:22         ` grahamlab
  2009-04-10  9:09           ` Sergei Gavrikov
  2009-04-10  8:38         ` Sergei Gavrikov
  1 sibling, 1 reply; 9+ messages in thread
From: grahamlab @ 2009-04-10  8:22 UTC (permalink / raw)
  To: ecos-discuss




grahamlab wrote:
> 
> 
> 
> Sergei Gavrikov-4 wrote:
>> 
>> On Fri, Apr 10, 2009 at 12:59:19AM -0700, grahamlab wrote:
>>> Sergei Gavrikov-4 wrote:
>>> > 
>>> > On Fri, Apr 10, 2009 at 12:30:56AM -0700, grahamlab wrote:
>>> >> 
>>> >> Hello all
>>> >> I am trying to evaluate the best way for me to use ecos for my
>>> project -
>>> >> to
>>> >> use the configtool or command line interface.
>>> >> So I 
>>> >> 1.created an ecos build using from command line using the default
>>> >> template.
>>> >> 2.executed the make command to build ecos
>>> >> 3.created a testbed directory and created a hello world application
>>> >> 4.compiled and linked successfully
>>> >> Next I
>>> >> 1 created an ecos build using the configuration tool
>>> >> 2 created a test bed directory and created a hello world application
>>> >> 3 this does not compile and gives the following errors -
>>> >> test.cpp: In function ‘int main()’:
>>> >> test.cpp:6: error: ‘printf’ was not declared in this scope
>>> >> 
>>> >> Both use the same makefile and make.params files(atached) - the only
>>> >> changes
>>> >> were to point to the correct install directory.
>>> > 
>>> > Graham, not only
>>> > 
>>> >   /tmp$ diff configtool_Make.params cli_Make.params 
>>> >   5c5
>>> >   < export PREFIX := /home/graham/ecos/DevBoard_install
>>> >   ---
>>> >   > export PREFIX := /home/graham/lab1/install
>>> >   7c7
>>> >   < export CC := $(COMMAND_PREFIX)gcc
>>> >   ---
>>> >   > export CC := $(COMMAND_PREFIX)g++
>>> > 
>>> > 
>>> >   /tmp$ diff configtool_Makefile cli_Makefile
>>> > 
>>> > 
>>> > Are you really going program in C++? Try rename your main.cpp in the
>>> > main.c.
>>> > 
>>> > BTW, the short plain text files you can just attach.
>>> > 
>>> > Sergei.
>>> > 
>>> >> If I point the configtool version at the commandline version install
>>> tree
>>> >> it
>>> >> will compile
>>> >> 
>>> >> Could some one explain why this is?
>>> >> 
>>> >> Thanks
>>> >> 
>>> >> http://www.nabble.com/file/p22984314/configtool_Make.params
>>> >> configtool_Make.params 
>>> >> http://www.nabble.com/file/p22984314/configtool_Makefile
>>> >> configtool_Makefile 
>>> >> http://www.nabble.com/file/p22984314/cli_Make.params cli_Make.params 
>>> >> http://www.nabble.com/file/p22984314/cli_Makefile cli_Makefile 
>>> >> Graham
>>> >> 
>>> >> -- 
>>> >> View this message in context:
>>> >>
>>> http://www.nabble.com/Confusing-compilation-problem-tp22984314p22984314.html
>>> >> Sent from the Sourceware - ecos-discuss mailing list archive at
>>> >> Nabble.com.
>>> >> 
>>> >> 
>>> >> --
>>> >> Before posting, please read the FAQ:
>>> http://ecos.sourceware.org/fom/ecos
>>> >> and search the list archive:
>>> http://ecos.sourceware.org/ml/ecos-discuss
>>> > 
>>> > -- 
>>> > Before posting, please read the FAQ:
>>> http://ecos.sourceware.org/fom/ecos
>>> > and search the list archive:
>>> http://ecos.sourceware.org/ml/ecos-discuss
>>> > 
>>> > 
>>> > 
>>> Helo again Sergei
>>> 
>>> Beleive me I have tried muliple permutations using both g++ and gcc
>> 
>> I hope that your Make.params were not handy tweaked.
>> 
>>> The cli vesrion compile with both g++ and gcc
>>> The config tool version compiles with neither.
>>> 
>>> It seems that you cannot switch between a cli build and a configtool
>>> build
>>> I am a little confused but will investigate further.
>>> Do you use the cli exclusively or do you switch between the 2?
>> 
>> I have used CLI only, but I have eCos configtool installed too. I will
>> try to reproduce your issue.
>> 
>> Sergei
>> 
>> -- 
>> Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
>> and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
>> 
>> 
>> 
> Hi Sergei
> I have been looking at the stdio.h file in both install trees.
> The files are exactly the same but in the CLI version things like 
> CYGINT_ISO_STDIO_FILETYPES are defined
> but in the configtool version they are not - so the correct includes are
> not generated.
> Where do things like CYGINT_ISO_STDIO_FILETYPES get defined?
> 
> Graham
> 
It seems I need to include IO C libraries - all working now thanks
-- 
View this message in context: http://www.nabble.com/Confusing-compilation-problem-tp22984314p22984736.html
Sent from the Sourceware - ecos-discuss mailing list archive at Nabble.com.


--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [ECOS] Confusing compilation problem
  2009-04-10  8:19       ` grahamlab
  2009-04-10  8:22         ` grahamlab
@ 2009-04-10  8:38         ` Sergei Gavrikov
  1 sibling, 0 replies; 9+ messages in thread
From: Sergei Gavrikov @ 2009-04-10  8:38 UTC (permalink / raw)
  To: grahamlab; +Cc: ecos-discuss

On Fri, Apr 10, 2009 at 01:09:57AM -0700, grahamlab wrote:
> 
> 
> 
> Sergei Gavrikov-4 wrote:
> > 
> > On Fri, Apr 10, 2009 at 12:59:19AM -0700, grahamlab wrote:
> >> Sergei Gavrikov-4 wrote:
> >> > 
> >> > On Fri, Apr 10, 2009 at 12:30:56AM -0700, grahamlab wrote:
> >> >> 
> >> >> Hello all
> >> >> I am trying to evaluate the best way for me to use ecos for my project
> >> -
> >> >> to
> >> >> use the configtool or command line interface.
> >> >> So I 
> >> >> 1.created an ecos build using from command line using the default
> >> >> template.
> >> >> 2.executed the make command to build ecos
> >> >> 3.created a testbed directory and created a hello world application
> >> >> 4.compiled and linked successfully
> >> >> Next I
> >> >> 1 created an ecos build using the configuration tool
> >> >> 2 created a test bed directory and created a hello world application
> >> >> 3 this does not compile and gives the following errors -
> >> >> test.cpp: In function ‘int main()’:
> >> >> test.cpp:6: error: ‘printf’ was not declared in this scope
> >> >> 
> >> >> Both use the same makefile and make.params files(atached) - the only
> >> >> changes
> >> >> were to point to the correct install directory.
> >> > 
> >> > Graham, not only
> >> > 
> >> >   /tmp$ diff configtool_Make.params cli_Make.params 
> >> >   5c5
> >> >   < export PREFIX := /home/graham/ecos/DevBoard_install
> >> >   ---
> >> >   > export PREFIX := /home/graham/lab1/install
> >> >   7c7
> >> >   < export CC := $(COMMAND_PREFIX)gcc
> >> >   ---
> >> >   > export CC := $(COMMAND_PREFIX)g++
> >> > 
> >> > 
> >> >   /tmp$ diff configtool_Makefile cli_Makefile
> >> > 
> >> > 
> >> > Are you really going program in C++? Try rename your main.cpp in the
> >> > main.c.
> >> > 
> >> > BTW, the short plain text files you can just attach.
> >> > 
> >> > Sergei.
> >> > 
> >> >> If I point the configtool version at the commandline version install
> >> tree
> >> >> it
> >> >> will compile
> >> >> 
> >> >> Could some one explain why this is?
> >> >> 
> >> >> Thanks
> >> >> 
> >> >> http://www.nabble.com/file/p22984314/configtool_Make.params
> >> >> configtool_Make.params 
> >> >> http://www.nabble.com/file/p22984314/configtool_Makefile
> >> >> configtool_Makefile 
> >> >> http://www.nabble.com/file/p22984314/cli_Make.params cli_Make.params 
> >> >> http://www.nabble.com/file/p22984314/cli_Makefile cli_Makefile 
> >> >> Graham
> >> >> 
> >> >> -- 
> >> >> View this message in context:
> >> >>
> >> http://www.nabble.com/Confusing-compilation-problem-tp22984314p22984314.html
> >> >> Sent from the Sourceware - ecos-discuss mailing list archive at
> >> >> Nabble.com.
> >> >> 
> >> >> 
> >> >> --
> >> >> Before posting, please read the FAQ:
> >> http://ecos.sourceware.org/fom/ecos
> >> >> and search the list archive:
> >> http://ecos.sourceware.org/ml/ecos-discuss
> >> > 
> >> > -- 
> >> > Before posting, please read the FAQ:
> >> http://ecos.sourceware.org/fom/ecos
> >> > and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
> >> > 
> >> > 
> >> > 
> >> Helo again Sergei
> >> 
> >> Beleive me I have tried muliple permutations using both g++ and gcc
> > 
> > I hope that your Make.params were not handy tweaked.
> > 
> >> The cli vesrion compile with both g++ and gcc
> >> The config tool version compiles with neither.
> >> 
> >> It seems that you cannot switch between a cli build and a configtool
> >> build
> >> I am a little confused but will investigate further.
> >> Do you use the cli exclusively or do you switch between the 2?
> > 
> > I have used CLI only, but I have eCos configtool installed too. I will
> > try to reproduce your issue.
> > 
> > Sergei
> > 
> > -- 
> > Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
> > and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
> > 
> > 
> > 
> Hi Sergei
> I have been looking at the stdio.h file in both install trees.
> The files are exactly the same but in the CLI version things like 
> CYGINT_ISO_STDIO_FILETYPES are defined
> but in the configtool version they are not - so the correct includes are not
> generated.
> Where do things like CYGINT_ISO_STDIO_FILETYPES get defined?
> 
> Graham

Are packages CYGPKG_ISOINFRA CYGPKG_LIBC_STDIO included in your gui
template? Did you able build the eCos tests using GUI? I hope you did:

configtool
  Build
    Tests <Shift+F7>

There are and .cxx files in the eCos tests.

Sergei

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [ECOS] Confusing compilation problem
  2009-04-10  8:22         ` grahamlab
@ 2009-04-10  9:09           ` Sergei Gavrikov
  2009-04-10 12:54             ` grahamlab
  0 siblings, 1 reply; 9+ messages in thread
From: Sergei Gavrikov @ 2009-04-10  9:09 UTC (permalink / raw)
  To: grahamlab; +Cc: ecos-discuss

[-- Attachment #1: Type: text/plain, Size: 5236 bytes --]

On Fri, Apr 10, 2009 at 01:18:57AM -0700, grahamlab wrote:
> 
> 
> 
> grahamlab wrote:
> > 
> > 
> > 
> > Sergei Gavrikov-4 wrote:
> >> 
> >> On Fri, Apr 10, 2009 at 12:59:19AM -0700, grahamlab wrote:
> >>> Sergei Gavrikov-4 wrote:
> >>> > 
> >>> > On Fri, Apr 10, 2009 at 12:30:56AM -0700, grahamlab wrote:
> >>> >> 
> >>> >> Hello all
> >>> >> I am trying to evaluate the best way for me to use ecos for my
> >>> project -
> >>> >> to
> >>> >> use the configtool or command line interface.
> >>> >> So I 
> >>> >> 1.created an ecos build using from command line using the default
> >>> >> template.
> >>> >> 2.executed the make command to build ecos
> >>> >> 3.created a testbed directory and created a hello world application
> >>> >> 4.compiled and linked successfully
> >>> >> Next I
> >>> >> 1 created an ecos build using the configuration tool
> >>> >> 2 created a test bed directory and created a hello world application
> >>> >> 3 this does not compile and gives the following errors -
> >>> >> test.cpp: In function ‘int main()’:
> >>> >> test.cpp:6: error: ‘printf’ was not declared in this scope
> >>> >> 
> >>> >> Both use the same makefile and make.params files(atached) - the only
> >>> >> changes
> >>> >> were to point to the correct install directory.
> >>> > 
> >>> > Graham, not only
> >>> > 
> >>> >   /tmp$ diff configtool_Make.params cli_Make.params 
> >>> >   5c5
> >>> >   < export PREFIX := /home/graham/ecos/DevBoard_install
> >>> >   ---
> >>> >   > export PREFIX := /home/graham/lab1/install
> >>> >   7c7
> >>> >   < export CC := $(COMMAND_PREFIX)gcc
> >>> >   ---
> >>> >   > export CC := $(COMMAND_PREFIX)g++
> >>> > 
> >>> > 
> >>> >   /tmp$ diff configtool_Makefile cli_Makefile
> >>> > 
> >>> > 
> >>> > Are you really going program in C++? Try rename your main.cpp in the
> >>> > main.c.
> >>> > 
> >>> > BTW, the short plain text files you can just attach.
> >>> > 
> >>> > Sergei.
> >>> > 
> >>> >> If I point the configtool version at the commandline version install
> >>> tree
> >>> >> it
> >>> >> will compile
> >>> >> 
> >>> >> Could some one explain why this is?
> >>> >> 
> >>> >> Thanks
> >>> >> 
> >>> >> http://www.nabble.com/file/p22984314/configtool_Make.params
> >>> >> configtool_Make.params 
> >>> >> http://www.nabble.com/file/p22984314/configtool_Makefile
> >>> >> configtool_Makefile 
> >>> >> http://www.nabble.com/file/p22984314/cli_Make.params cli_Make.params 
> >>> >> http://www.nabble.com/file/p22984314/cli_Makefile cli_Makefile 
> >>> >> Graham
> >>> >> 
> >>> >> -- 
> >>> >> View this message in context:
> >>> >>
> >>> http://www.nabble.com/Confusing-compilation-problem-tp22984314p22984314.html
> >>> >> Sent from the Sourceware - ecos-discuss mailing list archive at
> >>> >> Nabble.com.
> >>> >> 
> >>> >> 
> >>> >> --
> >>> >> Before posting, please read the FAQ:
> >>> http://ecos.sourceware.org/fom/ecos
> >>> >> and search the list archive:
> >>> http://ecos.sourceware.org/ml/ecos-discuss
> >>> > 
> >>> > -- 
> >>> > Before posting, please read the FAQ:
> >>> http://ecos.sourceware.org/fom/ecos
> >>> > and search the list archive:
> >>> http://ecos.sourceware.org/ml/ecos-discuss
> >>> > 
> >>> > 
> >>> > 
> >>> Helo again Sergei
> >>> 
> >>> Beleive me I have tried muliple permutations using both g++ and gcc
> >> 
> >> I hope that your Make.params were not handy tweaked.
> >> 
> >>> The cli vesrion compile with both g++ and gcc
> >>> The config tool version compiles with neither.
> >>> 
> >>> It seems that you cannot switch between a cli build and a configtool
> >>> build
> >>> I am a little confused but will investigate further.
> >>> Do you use the cli exclusively or do you switch between the 2?
> >> 
> >> I have used CLI only, but I have eCos configtool installed too. I will
> >> try to reproduce your issue.
> >> 
> >> Sergei
> >> 
> >> -- 
> >> Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
> >> and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
> >> 
> >> 
> >> 
> > Hi Sergei
> > I have been looking at the stdio.h file in both install trees.
> > The files are exactly the same but in the CLI version things like 
> > CYGINT_ISO_STDIO_FILETYPES are defined
> > but in the configtool version they are not - so the correct includes are
> > not generated.
> > Where do things like CYGINT_ISO_STDIO_FILETYPES get defined?
> > 
> > Graham
> > 
> It seems I need to include IO C libraries - all working now thanks

I cannot confirm your issue. Just now I tried GUI build and script
build_Make.params. All works as I could expect (see the below)

i. All was build using configtool-3.0. (stm3210e, default template).

$ ls
gui_build  gui.ecc  gui_install


ii. Generate Make.params, and test source

$ /opt/ecos/ecos-3.0/examples/build_Make.params 

$ echo -e \
'#include <stdio.h>\nint main(void){printf("oops\\n");return 0;}' > a.cxx

$ ls
a.cxx  gui_build  gui.ecc  gui_install  Make.params


iii. Prepare Makefile

$ vi Makefile
..

$ ls
a.cxx  gui_build  gui.ecc  gui_install  Makefile  Make.params


iv. Try to build
$ make -s


v. What I got

$ ls 
a.cxx  a.o  a.out  gui_build  gui.ecc  gui_install  Makefile  Make.params


Makefile is attached as a reference.


Sergei

[-- Attachment #2: Makefile --]
[-- Type: text/plain, Size: 258 bytes --]

include Make.params

OBJS	= a.o
DST	= a.out

.PHONY: all clean

all: ${DST}

clean:
	-rm -f ${DST} ${OBJS}

%.o: %.cxx
	$(CC) -c $^ $(ACTUAL_CXXFLAGS) -I$(PREFIX)/include -o $@

${DST}: ${OBJS}
	$(CC) $(ACTUAL_LDFLAGS) -L$(PREFIX)/lib -Ttarget.ld $^ -o $@



[-- Attachment #3: Type: text/plain, Size: 148 bytes --]

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [ECOS] Confusing compilation problem
  2009-04-10  9:09           ` Sergei Gavrikov
@ 2009-04-10 12:54             ` grahamlab
  0 siblings, 0 replies; 9+ messages in thread
From: grahamlab @ 2009-04-10 12:54 UTC (permalink / raw)
  To: ecos-discuss




Sergei Gavrikov-4 wrote:
> 
> On Fri, Apr 10, 2009 at 01:18:57AM -0700, grahamlab wrote:
>> 
>> 
>> 
>> grahamlab wrote:
>> > 
>> > 
>> > 
>> > Sergei Gavrikov-4 wrote:
>> >> 
>> >> On Fri, Apr 10, 2009 at 12:59:19AM -0700, grahamlab wrote:
>> >>> Sergei Gavrikov-4 wrote:
>> >>> > 
>> >>> > On Fri, Apr 10, 2009 at 12:30:56AM -0700, grahamlab wrote:
>> >>> >> 
>> >>> >> Hello all
>> >>> >> I am trying to evaluate the best way for me to use ecos for my
>> >>> project -
>> >>> >> to
>> >>> >> use the configtool or command line interface.
>> >>> >> So I 
>> >>> >> 1.created an ecos build using from command line using the default
>> >>> >> template.
>> >>> >> 2.executed the make command to build ecos
>> >>> >> 3.created a testbed directory and created a hello world
>> application
>> >>> >> 4.compiled and linked successfully
>> >>> >> Next I
>> >>> >> 1 created an ecos build using the configuration tool
>> >>> >> 2 created a test bed directory and created a hello world
>> application
>> >>> >> 3 this does not compile and gives the following errors -
>> >>> >> test.cpp: In function ‘int main()’:
>> >>> >> test.cpp:6: error: ‘printf’ was not declared in this scope
>> >>> >> 
>> >>> >> Both use the same makefile and make.params files(atached) - the
>> only
>> >>> >> changes
>> >>> >> were to point to the correct install directory.
>> >>> > 
>> >>> > Graham, not only
>> >>> > 
>> >>> >   /tmp$ diff configtool_Make.params cli_Make.params 
>> >>> >   5c5
>> >>> >   < export PREFIX := /home/graham/ecos/DevBoard_install
>> >>> >   ---
>> >>> >   > export PREFIX := /home/graham/lab1/install
>> >>> >   7c7
>> >>> >   < export CC := $(COMMAND_PREFIX)gcc
>> >>> >   ---
>> >>> >   > export CC := $(COMMAND_PREFIX)g++
>> >>> > 
>> >>> > 
>> >>> >   /tmp$ diff configtool_Makefile cli_Makefile
>> >>> > 
>> >>> > 
>> >>> > Are you really going program in C++? Try rename your main.cpp in
>> the
>> >>> > main.c.
>> >>> > 
>> >>> > BTW, the short plain text files you can just attach.
>> >>> > 
>> >>> > Sergei.
>> >>> > 
>> >>> >> If I point the configtool version at the commandline version
>> install
>> >>> tree
>> >>> >> it
>> >>> >> will compile
>> >>> >> 
>> >>> >> Could some one explain why this is?
>> >>> >> 
>> >>> >> Thanks
>> >>> >> 
>> >>> >> http://www.nabble.com/file/p22984314/configtool_Make.params
>> >>> >> configtool_Make.params 
>> >>> >> http://www.nabble.com/file/p22984314/configtool_Makefile
>> >>> >> configtool_Makefile 
>> >>> >> http://www.nabble.com/file/p22984314/cli_Make.params
>> cli_Make.params 
>> >>> >> http://www.nabble.com/file/p22984314/cli_Makefile cli_Makefile 
>> >>> >> Graham
>> >>> >> 
>> >>> >> -- 
>> >>> >> View this message in context:
>> >>> >>
>> >>>
>> http://www.nabble.com/Confusing-compilation-problem-tp22984314p22984314.html
>> >>> >> Sent from the Sourceware - ecos-discuss mailing list archive at
>> >>> >> Nabble.com.
>> >>> >> 
>> >>> >> 
>> >>> >> --
>> >>> >> Before posting, please read the FAQ:
>> >>> http://ecos.sourceware.org/fom/ecos
>> >>> >> and search the list archive:
>> >>> http://ecos.sourceware.org/ml/ecos-discuss
>> >>> > 
>> >>> > -- 
>> >>> > Before posting, please read the FAQ:
>> >>> http://ecos.sourceware.org/fom/ecos
>> >>> > and search the list archive:
>> >>> http://ecos.sourceware.org/ml/ecos-discuss
>> >>> > 
>> >>> > 
>> >>> > 
>> >>> Helo again Sergei
>> >>> 
>> >>> Beleive me I have tried muliple permutations using both g++ and gcc
>> >> 
>> >> I hope that your Make.params were not handy tweaked.
>> >> 
>> >>> The cli vesrion compile with both g++ and gcc
>> >>> The config tool version compiles with neither.
>> >>> 
>> >>> It seems that you cannot switch between a cli build and a configtool
>> >>> build
>> >>> I am a little confused but will investigate further.
>> >>> Do you use the cli exclusively or do you switch between the 2?
>> >> 
>> >> I have used CLI only, but I have eCos configtool installed too. I will
>> >> try to reproduce your issue.
>> >> 
>> >> Sergei
>> >> 
>> >> -- 
>> >> Before posting, please read the FAQ:
>> http://ecos.sourceware.org/fom/ecos
>> >> and search the list archive:
>> http://ecos.sourceware.org/ml/ecos-discuss
>> >> 
>> >> 
>> >> 
>> > Hi Sergei
>> > I have been looking at the stdio.h file in both install trees.
>> > The files are exactly the same but in the CLI version things like 
>> > CYGINT_ISO_STDIO_FILETYPES are defined
>> > but in the configtool version they are not - so the correct includes
>> are
>> > not generated.
>> > Where do things like CYGINT_ISO_STDIO_FILETYPES get defined?
>> > 
>> > Graham
>> > 
>> It seems I need to include IO C libraries - all working now thanks
> 
> I cannot confirm your issue. Just now I tried GUI build and script
> build_Make.params. All works as I could expect (see the below)
> 
> i. All was build using configtool-3.0. (stm3210e, default template).
> 
> $ ls
> gui_build  gui.ecc  gui_install
> 
> 
> ii. Generate Make.params, and test source
> 
> $ /opt/ecos/ecos-3.0/examples/build_Make.params 
> 
> $ echo -e \
> '#include <stdio.h>\nint main(void){printf("oops\\n");return 0;}' > a.cxx
> 
> $ ls
> a.cxx  gui_build  gui.ecc  gui_install  Make.params
> 
> 
> iii. Prepare Makefile
> 
> $ vi Makefile
> ..
> 
> $ ls
> a.cxx  gui_build  gui.ecc  gui_install  Makefile  Make.params
> 
> 
> iv. Try to build
> $ make -s
> 
> 
> v. What I got
> 
> $ ls 
> a.cxx  a.o  a.out  gui_build  gui.ecc  gui_install  Makefile  Make.params
> 
> 
> Makefile is attached as a reference.
> 
> 
> Sergei
> 
> include Make.params
> 
> OBJS	= a.o
> DST	= a.out
> 
> .PHONY: all clean
> 
> all: ${DST}
> 
> clean:
> 	-rm -f ${DST} ${OBJS}
> 
> %.o: %.cxx
> 	$(CC) -c $^ $(ACTUAL_CXXFLAGS) -I$(PREFIX)/include -o $@
> 
> ${DST}: ${OBJS}
> 	$(CC) $(ACTUAL_LDFLAGS) -L$(PREFIX)/lib -Ttarget.ld $^ -o $@
> 
> 
> 
> -- 
> Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
> and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
> 
Thanks - I have everyting working now
-- 
View this message in context: http://www.nabble.com/Confusing-compilation-problem-tp22984314p22985265.html
Sent from the Sourceware - ecos-discuss mailing list archive at Nabble.com.


--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2009-04-10  9:09 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-04-10  7:47 [ECOS] Confusing compilation problem grahamlab
2009-04-10  7:59 ` Sergei Gavrikov
2009-04-10  8:05   ` grahamlab
2009-04-10  8:10     ` Sergei Gavrikov
2009-04-10  8:19       ` grahamlab
2009-04-10  8:22         ` grahamlab
2009-04-10  9:09           ` Sergei Gavrikov
2009-04-10 12:54             ` grahamlab
2009-04-10  8:38         ` Sergei Gavrikov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).