Re: [CMake] 138% progress when building both all and not-in-all target?

2014-06-23 Thread Ben Pope

On Monday, June 23, 2014 08:38 PM, Brad King wrote:

On 06/20/2014 04:24 AM, Ben Pope wrote:

I've also seen this using the Makefile generator, the bigger problem is
that it ends up building the dependencies of those targets in parallel,
if there is overlap, it may try to build the same target multiple times
simultaneously, which can obviously break the build


This issue is recorded here:

  http://www.cmake.org/Bug/view.php?id=14312

It has been fixed for GNU make in CMake 3.0.


Awesome.  I suspect that if you build a set of targets often, it makes 
sense to add that set to a target to increase parallelism of the build.


But a quick fix that prevents breakage without regression is great.

Ben


--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Question of using cmake in Windows

2014-06-23 Thread John Drescher
> Ok, run cmake -G "MinGW Makefiles"
> -DCMAKE_C_COMPILER=/c/mingw-w64-4.9.0/mingw64/bin
> I got this error:
> CMake Error: the source directory  does not appear to contain
> CMakeLists.txt
>
> What I am missing?
>

You are not passing the folder of the source.

John
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Question of using cmake in Windows

2014-06-23 Thread jici gao
Ok, run cmake -G "MinGW Makefiles"
-DCMAKE_C_COMPILER=/c/mingw-w64-4.9.0/mingw64/bin
I got this error:
CMake Error: the source directory  does not appear to contain
CMakeLists.txt

What I am missing?

Thanks again!


On Mon, Jun 23, 2014 at 9:32 AM, Bill Hoffman 
wrote:

> On 6/23/2014 12:24 PM, jici gao wrote:
>
>>
>> So why only cmake gui version works for me, not the cmake command?
>>
> Use the -G option to the cmake on the command line to pick a generator.
>  cmake --help should list the ones supported by your version of cmake.
>
>
> -Bill
>
> --
>
> Powered by www.kitware.com
>
> Please keep messages on-topic and check the CMake FAQ at:
> http://www.cmake.org/Wiki/CMake_FAQ
>
> Kitware offers various services to support the CMake community. For more
> information on each offering, please visit:
>
> CMake Support: http://cmake.org/cmake/help/support.html
> CMake Consulting: http://cmake.org/cmake/help/consulting.html
> CMake Training Courses: http://cmake.org/cmake/help/training.html
>
> Visit other Kitware open-source projects at http://www.kitware.com/
> opensource/opensource.html
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/cmake
>
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Re: [CMake] Question of using cmake in Windows

2014-06-23 Thread Bill Hoffman

On 6/23/2014 12:24 PM, jici gao wrote:


So why only cmake gui version works for me, not the cmake command?
Use the -G option to the cmake on the command line to pick a generator. 
 cmake --help should list the ones supported by your version of cmake.



-Bill

--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


[CMake] Question of using cmake in Windows

2014-06-23 Thread jici gao
Hi,

I am using cmake (3.0.0) to setup environment for my compiling on Windows
and require mingw-w64 compiler. I pretty much followed your instruction
with Method 2 here:
http://www.cmake.org/Wiki/CMake_FAQ#How_do_I_use_a_different_compiler.3F

But cmake output always showed that it is building for Visual Studio 12
2013 and the c compiler identification is MSVC 18.0.21005.1 not the
mingw-w64 compiler I want.

I usually deleted all files under the build subdir to remove cached stuff
before start over.

However the cmake gui version is much better which allows to delete the
cached stuff and then I can specify the generator for the making, say
MinGW. I was able to specify the right compiler.

So why only cmake gui version works for me, not the cmake command?

Thanks in advance.
Jici
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

[CMake] CMake based package manager

2014-06-23 Thread Ruslan Baratov via CMake

Hi,

I'm developing a project that is a kind of wrapper of 
ExternalProject_Add and

allow it to be more reusable. User interface is quite simple.

For example adding Boost:

hunter_add_package(Boost COMPONENTS system filesystem)
find_package(Boost REQUIRED system filesystem)

... or GTest (it's patched version):

hunter_add_package(GTest)
find_package(GTest CONFIG REQUIRED)
target_link_libraries(... PUBLIC GTest::main)

The idea is to focus all builds in one place and let the outside projects
make requests to add/install new libraries there. At the same time overhead
is quite small. Every project hold one file (~ 10 KB) (that called gate) 
which

will download archive (~ 30 KB) with other packages' sha1 and download URLs.
External project from this set will be build and installed only if 
somebody call

`hunter_add_package` command.

I've made a test-drive project, so you can check how it works:

* https://github.com/forexample/hunter-simple

And the bigger one with Boost, CppNetlib.URI, GTest, JSON Spirit:

* https://github.com/ruslo/weather

I've tested it on Windows (Visual Studio), Linux, Mac OS X (+ iOS).

(Notes for windows: project should works fine on cygwin and mingw platforms,
but cygwin has old g++ version with lack of c++11 support and boost 
failed to

build with mingw)

For anybody interested, here is a github project:

* https://github.com/ruslo/hunter
--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Running OSX Bundle via open after creation with CMake/CPack

2014-06-23 Thread Scott Klum
I figured out the issue.  I have CPACK_BUNDLE_STARTUP_COMMAND to my startup
bash script.  This script modifies a bunch of library paths via
install_name_tool.  I cd into the directory containing the actual
executable (MyApp.app/Contents/Resources/bin/) and work from there.

This is pretty darn inefficient doing this every time the app starts, but I
couldn't find a way to do it AFTER the package (I looked into
execute_process, add_custom_command, etc. and nothing seemed to work after
the myapp executable was put in the bin directory), so if anyone has a
suggestion there it would be appreciated.

After modifying the paths, I have a ./myapp command at the end of the
script.  I expected this to work because I had cd'd into the directory
which contained myapp.  However, switching this command to one with an
absolute path (/Applications/MyApp.app/Contents/Resources/bin/myapp)
resulted in everything working.  I'm not sure if it's because this isn't
the standard structure for a bundle or what but there you have it.

Thanks for the suggestions.

Regards,
Scott



On Mon, Jun 23, 2014 at 9:04 AM, Scott Klum  wrote:

> Also, I forgot to mention that using the Console Utility gives nondescript
> errors: it just says MyApp exited with code 127.
>
>
> On Mon, Jun 23, 2014 at 8:56 AM, Scott Klum  wrote:
>
>> Lucas and David,
>>
>> Thank you for your responses.
>>
>> *Does anything get printed in the terminal if you type and enter: *
>> */Applications/MyApp.app/Contents/MacOS/MyApp**?*
>>
>> This is what I mean when I say I can run it through the terminal.  If I
>> enter the above command the app starts properly.
>>
>> *Does your app launch a lot of sub-processes at startup?*
>>
>> Nope - and as far as I can tell the code in my main.cpp isn't even
>> reached.
>>
>>
>> *Are you saying that you *can* run the app from the terminal window, but
>> that you cannot run the app by double-clicking or by using "open"? (And
>> that it's the exact same executable...?) What command line do you use if
>> you're not using "open"? *
>> That's correct.  I use the command described in the first response.
>>
>>
>> *Is there an environment difference (maybe LD_LIBRARY_PATH or
>> DYLD_LIBRARY_PATH?) between your Terminal, and your overall environment?*
>>
>> Not that I can tell.
>>
>> *Can you launch a debug build in a debugger?*
>>
>> Building in debug mode doesn't seem to make any difference.
>>
>> The fundamental problem seems to be whatever the open command does in the
>> background, I haven't set things up properly in terms of open knowing that
>> the when I run open MyApp.app, it should run
>> MyApp.app/Contents/MacOS/MyApp.  I've got CFBundleExecutable set to
>> MyApp... in fact my .plist looks like this:
>>
>> 
>> > http://www.apple.com/DTDs/PropertyList-1.0.dtd";>
>> 
>> 
>> CFBundleDevelopmentRegion
>> English
>>  CFBundleExecutable
>> MyApp
>> CFBundleIdentifier
>>  com.MyApp
>> CFBundleInfoDictionaryVersion
>> 6.0
>>  CFBundleName
>>  MyApp
>> CFBundleIconFile
>>   MyApp
>> CFBundlePackageType
>> APPL
>>  CFBundleShortVersionString
>> 2.1.0
>> CFBundleVersion
>>  2.1.0
>> CSResourcesFileMapped
>> 
>>  LSRequiresCarbon
>> 
>> NSHighResolutionCapable
>>  
>> 
>> 
>>
>> Again, not sure how to proceed.  But, I really appreciate the help.
>>
>> Regards,
>> Scott
>>
>>
>> On Mon, Jun 23, 2014 at 6:13 AM, David Cole  wrote:
>>
>>> Also, you may find extra hints about what's going wrong in the output of
>>> the "Console" application. (Usually found in "/Applications/Utilities") --
>>> see if there's anything in the "system.log" in there, or poke around and
>>> see if it has a crash report related to your app.
>>>
>>>
>>> HTH,
>>> David C.
>>>
>>>
>>
>>
>> --
>> Scott Klum
>> B.S. in Computer Science, Michigan State University 2012
>> M.S. in Computer Science, Michigan State University 2014
>>
>
>
>
> --
> Scott Klum
> B.S. in Computer Science, Michigan State University 2012
> M.S. in Computer Science, Michigan State University 2014
>



-- 
Scott Klum
B.S. in Computer Science, Michigan State University 2012
M.S. in Computer Science, Michigan State University 2014
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Re: [CMake] cmLocalGenerator.cxx is bugy

2014-06-23 Thread Brad King
On 06/22/2014 08:57 AM, Richard Wirth wrote:
> In line 1865 of the above mentioned file there is a conversion from
> const char* to string&  . When char* is NULL it crashes. The NULL comes
> as return from GetDefinition().

This problem was caused by refactoring in commit:

 stringapi: Pass configuration names as strings
 http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=84fdc9921

Since then we've found a few other places that forget to switch NULL
to empty string.  This looks like another, thanks.  I've fixed it
along with the rest of the places that call GetDefinition for
CMAKE_BUILD_TYPE without checking the result:

 Fix some generator crashes on undefined CMAKE_BUILD_TYPE
 http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=c491cb1e

> Then I searched all the files of the project for a occurrence of
> GetDefinition(). And I've found other codings of this possible error.
> For instance in cmComputeLinkInformation.cxx line 880 and many others.

That location checks the return value before use AFAICT, but without
knowing the exact version you have checked out from Git I do not know
if I'm looking at the same line of code.

Thanks,
-Brad

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] combine multiple library into a single one

2014-06-23 Thread Bill Hoffman

On 6/21/2014 8:00 PM, Emanuele Cannizzaro wrote:

Dear Sir/Madame,

I am trying to create a library that it depends on compiler flags.

I can create 4 library that will all together include all the functions
required, that is

You should look at Object Libraries:

http://www.cmake.org/Wiki/CMake/Tutorials/Object_Library

-Bill

--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


[CMake] CDash 2.2 release

2014-06-23 Thread Julien Jomier
On behalf of Zach, Bill, myself and the rest of the CDash team, we are 
pleased to announce that CDash 2.2.2 is available for download at: 
http://www.cdash.org


More than 80 bugs have been fixed for this release and among the new 
features:


  * Support for JUnit and NUnit tests
  * Support for Perforce Web Client
  * Support for Redmine repository browser
  * Better support for PostgreSQL  including version 9
  * Addition of developers statistics
  * News feed messages
  * New coverage presentation
  * Overall speed and robustness improvements

Documentation on how to upgrade from previous CDash installations is 
available at: http://public.kitware.com/Wiki/CDash:Upgrade.


If you have any problems or find any bugs, please report them at 
www.cdash.org/Bug.


A list of changes for the 2.2 release is included below and at

  http://public.kitware.com/Wiki/CDash:Upgrade#CDash_2.2

Happy CDashing,
Julien

--
CDash 2.2 Release - Bugs fixed

*0014906: Fix schedule to build association when handling submissions 
synchronously

*0014717: Fix SQL query quoting issue introduced in r3432
*0014683: Use correct variable to get db type
*0014682: Fix PHP undefined constant usage warning
*0014679: Properly check if specified project exists
*0014678: Drop weird copy'n'pasted comments from api/* files
*0014681: Fix typo in "feed" table definition
*0013400: Deleting all SubProjects does not remove the SubProjects section
*0013937: CDash does not filter warnings when requesting difference to 
previous build

*0014160: Deleting a group causes all builds in that group to disappear
*0014638: Fix a typo in the coverage viewer
*0014665: Generate xhtml to make the markdown standard compliant
*0014664: Add menu to viewNotes page
*0012989: Uninformative log message occurs a couple times a night on the 
CMake dashboard
*0013654: Failed to update from "expected" to "non-expected" when there 
are no build

*0014639: Fix undefined variable usage in test viewer
*0014560: Overhaul configure warning extraction algorithm
*0014589: Fix a PostgreSQL incompatibility
*0014588: Fix undefined variable usage in changes viewer
*0014556: ENH: Check that git directory is writable
*0014551: CDash gives out of memory errors when attempting to XSLT 
transform large XML files
*0014537: Fix a minor PostgreSQL incompatibility in test failure graph 
viewer
*0014531: Don't hardcode coverage threshold, use the one from the 
project settings

*0014530: Display correct configure warnings number on build summary page
*0014525: Daily Updates for Perforce reports Revision and Prior Revision 
as 0
*0014524: The path to the P4 utility is not quoted (reported by Igor 
Murzov)

*0014523: Drop remnants of backup page that was removed in r2599
*0014518: Add Perforce support to Daily Updates
*0014346: Fix a couple of typos in file viewer
*0014344: Cosmetics: Simplify some if conditions
*0014343: Drop incorrect & pointless query on client libraries info update
*0014513: Fix some html markdown issues
*0014480: Fix seeming logout in file viewer
*0014496: DOxygen menu should be renamed
*0014478: Don't display errors when project gets unselected on Edit 
Project page

*0014477: Drop unnecessary MySql-style quotes from SQL queries
*0014469: Fix broken markdown on registration page
*0014451: clientjobschedule.php doesn't encode project name before 
adding to submit URL

*0014423: Drop left-over code
*0014413: Fix grammar in coverage manager
*0014412: Handle '0 builds' and '0 failed tests' cases properly
*0014351: Fix lines of code calculation in the coverage viewer
*0014350: Set Append property to false in upload xml handler as files 
are not appendable

*0014189: dynamic analysis results not decoded
*0012368: CDash's build results html should use monospace font for 
'standard error' output

*0014364: Add missing dot which prevented job id to be set in client script
*0014374: Properly fetch result of SQL query on coverage info removal
*0014375: Fix incorrect string quoting in SQL query in coveragefile2user 
model

*0014341: Fix "user" table/function confusion
*0014340: Fix undefined variable usage in sendemail
*0010455: Show graph for 
*0013782: inconsistent last submission time for project and subprojects 
in the project dashboard

*0013781: typo in manageBuildGroup.php
*0013751: Error page
*0013577: User Enumeration Vulnerability
*0013491: CDash banner does not escape strings, potential SQL injection
*0013256: cdash viewCoverage.php errors with new ajax interface
*0013041: CDash 2 is still reporting wrong summary info for clock speed 
and RAM
*0014621: Broken Filter Hyperlinks when enabling and then disabling 
Auto-refresh

*0013943: Backup.php missing
*0013428: Unknown column 'buildid' when running "Cleanup database"
*0014514: svn log not updating with https:// and self signed certificate
*0013079: Test attachment links broken when a test fails
*0012994: Sorting by "Build Name" column doesn't work right when builds 
have OS icons

*0012993: Times with milliseconds in the

Re: [CMake] Running OSX Bundle via open after creation with CMake/CPack

2014-06-23 Thread Scott Klum
Also, I forgot to mention that using the Console Utility gives nondescript
errors: it just says MyApp exited with code 127.


On Mon, Jun 23, 2014 at 8:56 AM, Scott Klum  wrote:

> Lucas and David,
>
> Thank you for your responses.
>
> *Does anything get printed in the terminal if you type and enter: *
> */Applications/MyApp.app/Contents/MacOS/MyApp**?*
>
> This is what I mean when I say I can run it through the terminal.  If I
> enter the above command the app starts properly.
>
> *Does your app launch a lot of sub-processes at startup?*
>
> Nope - and as far as I can tell the code in my main.cpp isn't even reached.
>
>
> *Are you saying that you *can* run the app from the terminal window, but
> that you cannot run the app by double-clicking or by using "open"? (And
> that it's the exact same executable...?) What command line do you use if
> you're not using "open"? *
> That's correct.  I use the command described in the first response.
>
>
> *Is there an environment difference (maybe LD_LIBRARY_PATH or
> DYLD_LIBRARY_PATH?) between your Terminal, and your overall environment?*
>
> Not that I can tell.
>
> *Can you launch a debug build in a debugger?*
>
> Building in debug mode doesn't seem to make any difference.
>
> The fundamental problem seems to be whatever the open command does in the
> background, I haven't set things up properly in terms of open knowing that
> the when I run open MyApp.app, it should run
> MyApp.app/Contents/MacOS/MyApp.  I've got CFBundleExecutable set to
> MyApp... in fact my .plist looks like this:
>
> 
>  http://www.apple.com/DTDs/PropertyList-1.0.dtd";>
> 
> 
> CFBundleDevelopmentRegion
> English
>  CFBundleExecutable
> MyApp
> CFBundleIdentifier
>  com.MyApp
> CFBundleInfoDictionaryVersion
> 6.0
>  CFBundleName
>  MyApp
> CFBundleIconFile
>   MyApp
> CFBundlePackageType
> APPL
>  CFBundleShortVersionString
> 2.1.0
> CFBundleVersion
>  2.1.0
> CSResourcesFileMapped
> 
>  LSRequiresCarbon
> 
> NSHighResolutionCapable
>  
> 
> 
>
> Again, not sure how to proceed.  But, I really appreciate the help.
>
> Regards,
> Scott
>
>
> On Mon, Jun 23, 2014 at 6:13 AM, David Cole  wrote:
>
>> Also, you may find extra hints about what's going wrong in the output of
>> the "Console" application. (Usually found in "/Applications/Utilities") --
>> see if there's anything in the "system.log" in there, or poke around and
>> see if it has a crash report related to your app.
>>
>>
>> HTH,
>> David C.
>>
>>
>
>
> --
> Scott Klum
> B.S. in Computer Science, Michigan State University 2012
> M.S. in Computer Science, Michigan State University 2014
>



-- 
Scott Klum
B.S. in Computer Science, Michigan State University 2012
M.S. in Computer Science, Michigan State University 2014
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Re: [CMake] Running OSX Bundle via open after creation with CMake/CPack

2014-06-23 Thread Scott Klum
Lucas and David,

Thank you for your responses.

*Does anything get printed in the terminal if you type and enter: *
*/Applications/MyApp.app/Contents/MacOS/MyApp**?*

This is what I mean when I say I can run it through the terminal.  If I
enter the above command the app starts properly.

*Does your app launch a lot of sub-processes at startup?*

Nope - and as far as I can tell the code in my main.cpp isn't even reached.


*Are you saying that you *can* run the app from the terminal window, but
that you cannot run the app by double-clicking or by using "open"? (And
that it's the exact same executable...?) What command line do you use if
you're not using "open"?*
That's correct.  I use the command described in the first response.

*Is there an environment difference (maybe LD_LIBRARY_PATH or
DYLD_LIBRARY_PATH?) between your Terminal, and your overall environment?*

Not that I can tell.

*Can you launch a debug build in a debugger?*

Building in debug mode doesn't seem to make any difference.

The fundamental problem seems to be whatever the open command does in the
background, I haven't set things up properly in terms of open knowing that
the when I run open MyApp.app, it should run
MyApp.app/Contents/MacOS/MyApp.  I've got CFBundleExecutable set to
MyApp... in fact my .plist looks like this:


http://www.apple.com/DTDs/PropertyList-1.0.dtd";>


CFBundleDevelopmentRegion
English
CFBundleExecutable
MyApp
CFBundleIdentifier
com.MyApp
CFBundleInfoDictionaryVersion
6.0
CFBundleName
 MyApp
CFBundleIconFile
 MyApp
CFBundlePackageType
APPL
CFBundleShortVersionString
2.1.0
CFBundleVersion
2.1.0
CSResourcesFileMapped

LSRequiresCarbon

NSHighResolutionCapable




Again, not sure how to proceed.  But, I really appreciate the help.

Regards,
Scott


On Mon, Jun 23, 2014 at 6:13 AM, David Cole  wrote:

> Also, you may find extra hints about what's going wrong in the output of
> the "Console" application. (Usually found in "/Applications/Utilities") --
> see if there's anything in the "system.log" in there, or poke around and
> see if it has a crash report related to your app.
>
>
> HTH,
> David C.
>
>


-- 
Scott Klum
B.S. in Computer Science, Michigan State University 2012
M.S. in Computer Science, Michigan State University 2014
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Re: [CMake] 138% progress when building both all and not-in-all target?

2014-06-23 Thread Brad King
On 06/20/2014 04:24 AM, Ben Pope wrote:
> I've also seen this using the Makefile generator, the bigger problem is 
> that it ends up building the dependencies of those targets in parallel, 
> if there is overlap, it may try to build the same target multiple times 
> simultaneously, which can obviously break the build

This issue is recorded here:

 http://www.cmake.org/Bug/view.php?id=14312

It has been fixed for GNU make in CMake 3.0.

-Brad

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Running OSX Bundle via open after creation with CMake/CPack

2014-06-23 Thread David Cole via CMake
Also, you may find extra hints about what's going wrong in the output 
of the "Console" application. (Usually found in 
"/Applications/Utilities") -- see if there's anything in the 
"system.log" in there, or poke around and see if it has a crash report 
related to your app.



HTH,
David C.

--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Running OSX Bundle via open after creation with CMake/CPack

2014-06-23 Thread David Cole via CMake

Well, there's this information about "unknown error" -10810:

   http://www.thexlab.com/faqs/error-10810.html

Does your app launch a lot of sub-processes at startup?

Are you saying that you *can* run the app from the terminal window, but 
that you cannot run the app by double-clicking or by using "open"? (And 
that it's the exact same executable...?) What command line do you use 
if you're not using "open"?


Is there an environment difference (maybe LD_LIBRARY_PATH or 
DYLD_LIBRARY_PATH?) between your Terminal, and your overall environment?


Can you launch a debug build in a debugger?

--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Running OSX Bundle via open after creation with CMake/CPack

2014-06-23 Thread Lucas Soltic

Le 23 juin 2014 à 03:11, Scott Klum  a écrit :

> I'm trying to make an OSX bundle using CMake/CPack on OSX that involves 
> OpenCV and Qt (although I don't think those dependencies matter at this 
> point). Everything compiles and the bundle is created fine, and I have a 
> script that modifies the necessary library paths such the executable I'm 
> making works if I run it from the Terminal within the bundle. The problem I'm 
> having is if I try to run the MyApp.app file via the open command or by 
> simply double clicking the app it gives me the error:
> 
> LSOpenURLsWithRole() failed with error -10810 for the file /Applications/MyApp
> I've seen other solutions to other LSOpenURLsWithRole() errors involving 
> modifying permissions, but that hasn't helped me. Also, this error code is an 
> "unknown error" so I'm not sure how to proceed.
> 
> 
> -- 
> Scott Klum

Hello Scott,

Does anything get printed in the terminal if you type and enter:
/Applications/MyApp.app/Contents/MacOS/MyApp
?-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake