Jesse Corrington | 1 Dec 2007 02:24
Picon

Re: cross compiling

That would probably be possible. However, that would be limiting as it would restrict you to using visual studio. Also, and I may we wrong here, but I'm pretty sure the visual studio project is only capable of building emulator builds.

On Nov 30, 2007 12:47 PM, <clinton-CsSkQS5UgvVWk0Htik3J/w@public.gmane.org> wrote:

Acoording to that link you gave, a Visual Studio project file can be created
from inf and mmp files.  Can you get CMake to generate an equivalent Visual
Studio project file?

Clint

On Friday 30 November 2007 1:02:42 pm Jesse Corrington wrote:
> It seems there is some confusion over the symbian build files. If you are
> interested, take a look at this article on building a simple hello world
> app, which talks about the inf and mmp files.
>
> http://newlc.com/Getting-Started-with-Symbian.html
>
>
> Jesse
>
>
> On Nov 30, 2007 11:43 AM, Jesse Corrington <jesse.corrington-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
>
> wrote:
> > I'm pretty sure to build any symbian app you need an inf and mmp file.
> > These have nothing to do with the eclipse plugin, but It is able to
> > import them, so you need these files whether you are working in an IDE or
> > building from the command line. The files are extremely simple, at least
> > the ones we use. They are pretty close to just a flat list of files,
> > because it uses all of the symbian default compiler flags and such. I
> > can't get the CMake source at work right now, because our firewall is
> > being stupid, but I am going to grab it this weekend and start having a
> > look on Monday. I was planning to work from the makefile generator, since
> > this will be similar to that.
> >
> > On Nov 30, 2007 12:55 AM, Torsten Martinsen <tma-xHzrhMJjkLWqz0fwNBLI4A@public.gmane.org> wrote:
> > >  The CVS version does, yes.
> > >
> > >  ------------------------------
> > > *From:* cmake-bounces+tma=gatehouse.dk-wChDC6UyXvPYtjvyW6yDsg@public.gmane.org
> > > [mailto:cmake-bounces+tma=gatehouse.dk-wChDC6UyXvPYtjvyW6yDsg@public.gmane.org ] *On Behalf Of *Josef
> > > Karthauser
> > > *Sent:* 30 November 2007 09:54
> > > *To:* Jesse Corrington; Salvatore Iovene
> > > *Cc:* cmake-wChDC6UyXvPYtjvyW6yDsg@public.gmane.org; a.neundorf-work-hi6Y0CQ0nG0@public.gmane.org
> > > *Subject:* RE: [CMake] cross compiling
> > >
> > >   Did I miss something?  Does cmake support cross compiling now?
> > >
> > > ------------------------------
> > > This e-mail and any files sent with it contain information that may be
> > > privileged or confidential and is the property of the GateHouse Group.
> > > This information is intended solely for the person to whom it is
> > > addressed. If you are not the intended recipient, you are not
> > > authorized to read, print, retain, copy, disseminate, distribute, or
> > > use the message or any part thereof. If you have received this e-mail
> > > in error, please notify the sender immediately, and delete all copies
> > > of this message. In accordance with GateHouse Security Policy, e-mails
> > > sent or received may be monitored.
> > >
> > > _______________________________________________
> > > CMake mailing list
> > > CMake-wChDC6UyXvPYtjvyW6yDsg@public.gmane.org
> > > http://www.cmake.org/mailman/listinfo/cmake



_______________________________________________
CMake mailing list
CMake@...
http://www.cmake.org/mailman/listinfo/cmake
Jesse Corrington | 1 Dec 2007 03:31
Picon

SOURCE_GROUP command

In my cmake scripts I build a single list of all my cpp and h files for the project. At the end of the script I iterate over this list and add each file to the correct source group based on it's path relative to the source root. This is only for MSVC.  I am running into a problem where I end up with .h files in the Source Files group, or .cpp files in the Header Files group. I noticed that if I only grouped header files, or only grouped source files, then there was no mixing, but I want both to be grouped. Below is my code for doing this. PROJECT_SOURCE_FILES contains the complete list of source and header files. Thanks

Jesse

# Setup source grouping for visual studio
IF( MSVC )

    FOREACH( pathSourceFile ${PROJECT_SOURCE_FILES} )
       
        GET_FILENAME_COMPONENT( pathSourceGroup ${pathSourceFile} PATH )
       
        IF( NOT ${pathSourceGroup} STREQUAL ${CMAKE_SOURCE_DIR} )
       
            # Make the path relative to the base source path
            STRING( REPLACE ${CMAKE_SOURCE_DIR} "" pathSourceGroup ${pathSourceGroup} )
   
            # Remove starting / and \
            STRING( SUBSTRING ${pathSourceGroup} 0 1 firstChar )
            IF( firstChar STREQUAL "/" OR
                firstChar STREQUAL "\\" )
                   
                STRING( LENGTH ${pathSourceGroup} strLen )
                MATH( EXPR strLen "${strLen} - 1" )
                STRING( SUBSTRING ${pathSourceGroup} 1 ${strLen}  pathSourceGroup )
            ENDIF()
           
            # Replace / with \ so the source groups work correctly in MSVC
            STRING( REPLACE "/" "\\" pathSourceGroup ${pathSourceGroup} )
           
            # Add file to the source group
            GET_FILENAME_COMPONENT( fileExtension ${pathSourceFile} EXT )
            IF( ${fileExtension} MATCHES ".c" OR
                ${fileExtension} MATCHES ".cpp" )
                SOURCE_GROUP( "Source Files\\${pathSourceGroup}" FILES ${pathSourceFile} )
            ELSEIF( ${fileExtension} MATCHES ".h" OR
                    ${fileExtension} MATCHES ".hpp" )
                SOURCE_GROUP( "Header Files\\${pathSourceGroup}" FILES ${pathSourceFile} )
            ELSE()
                MESSAGE( SEND_ERROR "Source grouping failed on file ${pathSourceFile}" )
            ENDIF()
           
        ENDIF()
       
    ENDFOREACH()
ENDIF()

_______________________________________________
CMake mailing list
CMake@...
http://www.cmake.org/mailman/listinfo/cmake
Alexander Adam | 1 Dec 2007 09:22

Re: windows mobile visual studio 2005 project files

Hi,

Well, yes that's certainly possible yet AFAIK you need a WinMain at
least, I can't get anything else compiled on Windows CE / Mobile..

Alex

On Nov 30, 2007 12:08 AM, Hendrik Sattler <post@...> wrote:
> Am Donnerstag 29 November 2007 schrieb Alexander Adam:
> > > You can't build the following ?
> > > int main() {return 0;}
> > >
> > > So what is the most simple executable you can build ?
> >
> > Well, for windows mobile, you're required to have a _WinMain startup
> > entry, otherwise you can't build as Windows CE doesn't have anything
> > like a console.
>
> But it has programs that may have no windows (because they do not need to
> interact with the user). Or is this impossible under Windows Mobile?
>
> HS
>
> _______________________________________________
> CMake mailing list
> CMake@...
> http://www.cmake.org/mailman/listinfo/cmake
>
Picon

Re: Can't get cmake to do debug build with wxwidgets

On Nov 30, 2007 1:43 PM, Joseph Garvin wrote:
> Under windows, everything works fine. However, trying to build my project on
> Linux, I think that cmake isn't properly setting up linking against the
> debug versions of the wxwidgets libraries. wxWidgets has a function,
> wxLogDebug, that prints text in debug mode but does nothing in release mode.
> Even if I run cmake in wizard mode and tell it to only build Debug mode,
> wxLogDebug does not print anything in my app. I've double checked that I
> have the debug libraries installed, and I don't get any error messages. I'm
> using FIND_PACKAGE(wxWidgets), and TARGET_LINK_LIBRARIES(myapp
> ${wxWidgets_LIBRARIES}). Any ideas? Using Cmake v2.4 - patch7 running on
> Ubuntu against wxWidgets 2.8.4.

Can you provide the CMakeLists.txt and CMakeCache.txt files?

You must be doing something else because just:

 FIND_PACKAGE(wxWidgets) should not
 TARGET_LINK_LIBRARIES(myapp ${wxWidgets_LIBRARIES})

won't work. You need to specify the modules you want to link with and
posibly make use of the UsewxWidgets.cmake file, although I don't use
it.

--Miguel
Hendrik Sattler | 1 Dec 2007 20:43
Picon

CMake and SWIG and several broken modules

Hi,

I trie to use cmake for an already existing project that currently uses 
autotools.

There are several problems and some are related to bugs in module files or 
missing module features. The bugs are reported here as they are easy to fix 
and I don't want to do yet-another-registration:

* the FindPerlLibs.cmake module:
  - doesn't properly escape the $ at lines 35 and 45
  - calls SEPERATE_ARGUMENTS in line 51 that makes it harder to use with
    set_target_properties and the COMPILE_FLAGS property.
  - doesn't even mention that the PERL_EXTRA_C_FLAGS are essentiel
  Obviously noone ever used it :-(

* The UseSWIG.cmake module:
  - uses it's first argument as target name for the module and thus also
    as output name, better:
      - combine target name with the current language and set OUTPUT_NAME
        property on target to the first argument

With the latter, the user has to call set_target_properties for _every_ module 
to set the OUTPUT_NAME to something sensible.

The rest of the SWIG stuff is incredible easy to use :)
I didn't write the install instruction, yet, though. How do I find the proper 
directories for languages like perl, python, ruby and tcl?

HS
Hendrik Sattler | 1 Dec 2007 21:12
Picon

Re: CMake and SWIG and several broken modules

Am Samstag 01 Dezember 2007 schrieb Hendrik Sattler:
> * The UseSWIG.cmake module:
>   - uses it's first argument as target name for the module and thus also
>     as output name, better:
>       - combine target name with the current language and set OUTPUT_NAME
>         property on target to the first argument
    - only works if the macros are run in the same directory as the source
      file, so UseSWIG.cmake is also seriously broken :-(

HS
Steven Van Ingelgem | 1 Dec 2007 21:13
Picon

How to pass a write-parameter to a "MACRO"?

What I want to do is to pass a parameter to a macro which will be
"SET" at the end of the macro.
In fact I want it to behave a little as a "function" with it's own
variable scope.

Does anyone know how I could do that?

Thanks,
Steven
Brandon Van Every | 1 Dec 2007 22:23
Picon

Re: How to pass a write-parameter to a "MACRO"?

On Dec 1, 2007 3:13 PM, Steven Van Ingelgem <steven@...> wrote:
> What I want to do is to pass a parameter to a macro which will be
> "SET" at the end of the macro.
> In fact I want it to behave a little as a "function" with it's own
> variable scope.
>
> Does anyone know how I could do that?

Uuuh, do you mean

macro(myfunction myparam)
  # blah blah blah
  set(${myparam} whatever)
endmacro(myfunction)

${myparam} evaluates to the global variable that you fed to the macro.
 There is no local scope in current CMake.  We've had extensive
argument about the need for scope recently.  One approach is to
improve the CMake script language.  There are some proposals in the
recent thread "lexical scoping", and some people at Kitware may be
willing to act on one or more of them sometime soon.  Another approach
is to embed Lua into CMake.  Ken has shown proof-of-concept that it's
doable, but there's no consensus that it's desirable.

Do you feel the documentation of macro() is adequate to explain the
formal argument processing, or is more needed?

Cheers,
Brandon Van Every
Sumit Kumar | 2 Dec 2007 00:40
Picon
Favicon

CMake does not recurse subdirectores

Hello
I have written a CMakeLists.txt which calls several
individual CMakeLists.txt files in subdirectories.

that is

DIR
|
-- SDir1
   |
   ------SDir2a
   |
   ------SDir2b
and so on
The CMakeLists.txt file in DIR calls
SUBDIRS(SDir1)

The CMakeLists.txt file in SDir1 has
SUBDIRS(
SDir2a
SDir2b
)
SDir2a and SDir2b have their own CMakeLists.txt files

CMake successfully generates makefiles. However when I
am trying to compile the code (I use MinGW compiler)
it only compiles code from the last listing amongst
the subdirectories in SDir1 (which in this case would
be SDir2b). It does not enter SDir2a !!
Can anyone tell me what I am missing here ?
Thanks

Sumit K. Nath, Ph.d
Department of Electrical, Computer and Systems Engg,
Rensselaer Polytechnic Institute
Troy, NY - 12180
U.S.A

Phone - +1-(573)-529-6522

      Looking for the perfect gift? Give the gift of Flickr! 

http://www.flickr.com/gift/
Cem DEMiRKIR | 2 Dec 2007 10:07
Picon

CMake Error

Hello group.

I've been trying to build ITK on my machine, and obviously is not related to what is built, and CMake produces 
some errors at the configuration step.  Perhaps someoneelse has already encountered 
similar type of problem ?

My setup:
Windows XP, ITK 3.4.0 Latest Release, CMake 2.4.4, Visual Studio .NET 2005
w/ Visual C++ 8

At first I've observed the following CMake Errror message box and then a lot of errors coming up when I choose OK.


CMake Error:  Unable to find executable for TRY_RUN:  tried
"Z:\Libraries\Insight\bin/CMakeTmp/cmTryCompileExec.exe" and
"Z:\Libraries\Insight\bin/CMakeTmp/Debug/cmTryCompileExec.exe" and
"Z:\Libraries\Insight\bin/CMakeTmp/Development/cmTryCompileExec.exe".
[CMake is correct; these files do not exist, but the log indicates no error for the building of these executables.]
 
I've compiled previous version of ITK, or VTK, etc. without any problem before, but after deleting old one and trying to build the latest release, I've got these errors. I'd be grateful to anyone who help me resolve this problem ?
 
Sincerely
Cem DEMiRKIR 

_______________________________________________
CMake mailing list
CMake@...
http://www.cmake.org/mailman/listinfo/cmake

Gmane