---------- Forwarded message ---------- From: ankit jain <ankitgu...@gmail.com> Date: 2009/2/4 Subject: Re: [CMake] Fwd: Is it necessary to link a executable file? To: Eric Noulard <eric.noul...@gmail.com>
2009/2/4 Eric Noulard <eric.noul...@gmail.com> 2009/2/4 ankit jain <ankitgu...@gmail.com>: > >> > >> 2009/2/4 ankit jain <ankitgu...@gmail.com>: > >> > >> > Actually in this case i dont want to create libraries thats why iam > >> > wondering whether making only executable is permissble or not? > >> > >> If you use > >> ADD_EXECUTABLE > >> > >> it should work just fine. > >> -- > >> Erk > > > > I am using that only but it gives error because it goea to the folder > > /usr/lib and try to link it with some .o file. > > As already told by others here you should give us > more precise informations about your problem. At least, > > - the CMakeLists.txt you are using or the portion which seems to lead > to an error. > - the verbatim copy of the error you are observing. > > without that we may not help you. > > -- > Erk > The CMakeLists iam using contains: PROJECT(hello) ADD_EXECUTABLE(hello h1.C) Error iam getting is: Linking CXX executable hello /usr/lib/gcc-lib/i386-redhat-linux/3.2.3/../../../crt1.o(.text+0x18): In function `_start': : undefined reference to `main' AJ
_______________________________________________ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake