Re: [CMake] unable to include a source file for all sub directories

2009-05-18 Thread ankit jain
2009/5/16 Hendrik Sattler > Am Freitag 15 Mai 2009 17:05:58 schrieb ankit jain: > [...] > > The following works with VS2008 without any problem as expected: > CMakeLists.txt: > -- > project(var C) > add_executable(var sub/main.c var.c va

Re: [CMake] unable to include a source file for all sub directories

2009-05-15 Thread Hendrik Sattler
Am Freitag 15 Mai 2009 17:05:58 schrieb ankit jain: [...] The following works with VS2008 without any problem as expected: CMakeLists.txt: -- project(var C) add_executable(var sub/main.c var.c var.h) --

Re: [CMake] unable to include a source file for all sub directories

2009-05-15 Thread ankit jain
2009/5/15 > ankit jain wrote: > > > My source tree structure is: > > Main_folder > >.. Ident.c > >..folder1 > >f11.c > >f12.c > > [...] > > > > Now I am able to get all the source files from all the folders. but > the > > problem is that all folder source files uses one variable

Re: [CMake] unable to include a source file for all sub directories

2009-05-15 Thread David . Karr
ankit jain wrote: > My source tree structure is: > Main_folder >.. Ident.c >..folder1 >f11.c >f12.c > [...] > > Now I am able to get all the source files from all the folders. but the > problem is that all folder source files uses one variable v1 of this Ident.c > file.. > > So th

[CMake] unable to include a source file for all sub directories

2009-05-15 Thread ankit jain
-- Forwarded message -- From: ankit jain Date: 2009/5/15 Subject: Re: [CMake] unable to include a source file for all sub directories To: Hendrik Sattler 2009/5/15 Hendrik Sattler > Zitat von ankit jain : > >> Now all files iam getting from folder1 and folder2

Re: [CMake] unable to include a source file for all sub directories

2009-05-15 Thread Hendrik Sattler
Zitat von ankit jain : Now all files iam getting from folder1 and folder2 and objects of all files including Ident.c is created... But while linking f11.obj f12.obj f21.obj f22.obj all show error undefined symbol: char *v1 where Ident .c contains.. char v1[]="Hello"; If you want a pointer, de

Re: [CMake] unable to include a source file for all sub directories

2009-05-15 Thread ankit jain
2009/5/15 Hendrik Sattler > Zitat von ankit jain : > >> Linker error for many objects files that have created >> > > So either the object file that contains the symbol is not part of your link > command or you have a coding error. > Since you release neither an example nor further information, yo

Re: [CMake] unable to include a source file for all sub directories

2009-05-15 Thread Hendrik Sattler
Zitat von ankit jain : Linker error for many objects files that have created So either the object file that contains the symbol is not part of your link command or you have a coding error. Since you release neither an example nor further information, you will probably not get any other answ

[CMake] unable to include a source file for all sub directories

2009-05-15 Thread ankit jain
-- Forwarded message -- From: ankit jain Date: 2009/5/15 Subject: Re: [CMake] unable to include a source file for all sub directories To: Hendrik Sattler 2009/5/15 Hendrik Sattler > Zitat von ankit jain : > >> If suppose 5 files are there in one folder and ea

Re: [CMake] unable to include a source file for all sub directories

2009-05-15 Thread Hendrik Sattler
Zitat von ankit jain : If suppose 5 files are there in one folder and each file uses some functions form other file in the same folder and when ur creating library then there is no problem.. Issue is if one folder file uses another file which is in diff. folder or in its parent folder then crea

[CMake] unable to include a source file for all sub directories

2009-05-15 Thread ankit jain
-- Forwarded message -- From: ankit jain Date: 2009/5/15 Subject: Re: [CMake] unable to include a source file for all sub directories To: Hendrik Sattler 2009/5/15 Hendrik Sattler Zitat von ankit jain : > >> Now I am able to get all the source files from all th

Re: [CMake] unable to include a source file for all sub directories

2009-05-15 Thread Hendrik Sattler
Zitat von ankit jain : Now I am able to get all the source files from all the folders. but the problem is that all folder source files uses one variable v1 of this Ident.c file.. So the error iam getting while building the library is : unresolved external symbol: v1 (iam working on windows VC++

[CMake] unable to include a source file for all sub directories

2009-05-14 Thread ankit jain
Hi all, My problem is like this... My source tree structure is: Main_folder .. Ident.c ..folder1 f11.c f12.c ..folder2 ..f21.c ..f22.c ..folder3 f31.c f32.c Now iam building a library for main_folder as: foreach(fname ${folder1_srcs} list(APPEND main_folder_srcs f