Re: [CMake] Does Makefile generated by CMake support make -jN?

2016-07-17 Thread Chaos Zhang
e -j" option in CMake file? For i use Qt Creator as IDE, and the CMake compile system is provided for other R&D teams, so i want to make the CMake compile system as simply and automatically as i can. Could you please give me some advice? Thanks again, Chao Chaos Zhang wrote > Hi,

Re: [CMake] Does Makefile generated by CMake support make -jN?

2016-07-14 Thread Chaos Zhang
Hi, Chuck, Thanks for your generous help. Actually there is no make -j option in the already exist make flow of my project as i know so far. Because i have read the makefiles in detail, and when i make my project, the sub projects in my project executed in order. The problem i found is it cost

Re: [CMake] Does Makefile generated by CMake support make -jN?

2016-07-12 Thread Chaos Zhang
ctively in CMake. Thanks again, Chao Andrew Melo wrote > On Tue, Jul 12, 2016 at 10:48 PM, Chaos Zhang < > zcsd2012@ > > wrote: >> Thanks for your reply Raymond, by 'If you got 96% both times, then I >> would >> say there's a problem.', did you mean i

Re: [CMake] Does Makefile generated by CMake support make -jN?

2016-07-12 Thread Chaos Zhang
hanks, Chao J Decker wrote > On Tue, Jul 12, 2016 at 7:54 PM, Chaos Zhang < > zcsd2012@ > > wrote: > >> Hi, all, >> >> I was trying to compile my project using CMake, after CMake generated >> Makefile. >> I used `/usr/bin/time -v make` to make the M

Re: [CMake] Does Makefile generated by CMake support make -jN?

2016-07-12 Thread Chaos Zhang
gt; Hi Chao, > > > On Wed, Jul 13, 2016 at 10:54 AM, Chaos Zhang < > zcsd2012@ > > wrote: >> I was trying to compile my project using CMake, after CMake generated >> Makefile. >> I used `/usr/bin/time -v make` to make the Makefile, got the result: >>

[CMake] Does Makefile generated by CMake support make -jN?

2016-07-12 Thread Chaos Zhang
Hi, all, I was trying to compile my project using CMake, after CMake generated Makefile. I used `/usr/bin/time -v make` to make the Makefile, got the result: 'Percent of CPU this job got: 96%'. Then i used `/usr/bin/time -v make -j8` to make the Makefile, the result of CPU used is 'Percent of CP

Re: [CMake] [ANNOUNCE] CMake 3.6.0-rc4 now ready for testing!

2016-07-01 Thread Chaos Zhang
Thanks a lot for your hard working, thus we can benefit from cmake! :-)Best regard,chao Robert Maynard wrote > I am proud to announce the fourth CMake 3.6 release candidate.Sources and > binaries are available at: https://cmake.org/download/Documentation is > available at: https://cmake.org/cmake

[CMake] How to assign specific c, c++, fortran compiler and does CMake support Intel C/C++/Fortran Compiler?

2016-06-30 Thread Chaos Zhang
Hi, all, First, thanks for review my email. There are two questions i faced now: 1. I faced problem to assign specific compiler in CMake, and i searched for a while then i found [ CC="Foo\gcc.exe" CXX="Foo\g++.exe" cmake . ] seem work. Now i use CMake in QtCreator, is there other way i can assign

[CMake] Why a foo.dll.a generated when i build shared lib foo.dll or foo.exe file?

2016-06-19 Thread Chaos Zhang
Hi,all, I am working on transferring an existed make project into cmake, and the platform is MinGW(32 bit) on windows. The make flow to build foo.dll or foo.exe would not generate foo.dll.a, but when i use CMake, this generated. I was wondering if this foo.dll.a is necessary, and if it is not nec

[CMake] How to set gcc option "-Wl,-rpath-link," in CMake?make

2016-06-06 Thread Chaos Zhang
Hi, all, i am trying to converting an existed make project into CMake project, and there are some gcc link options i should convert. Not long ago, Mr. Atkins told me 'RPATHs are automatically added by CMake to executables so they can use libraries from the build tree.'. Now i don't know weather "-

Re: [CMake] How to use CMAKE_MFC_FLAG for only one on executables?

2016-06-01 Thread Zhang Peixuan
4 AM, Nicholas Braden > wrote: > > Have you tried unsetting it after adding the executable in question? > > If that doesn't work, is it possible to make the MFX executable be the > > very last executable added in your project? > > > > On Wed, Jun 1, 201

[CMake] How to use CMAKE_MFC_FLAG for only one on executables?

2016-06-01 Thread Zhang Peixuan
d DLL". In fact, I want only one MFC executable, and make sure all other executables are "Use Standard Windows Library". Is there any way to implement it? It seems CMAKE_MFC_FLAG does not work with set_target_property or other commands. Thanks, Peixuan Zhang -- Powered by www.kitware.

Re: [CMake] How to hundle gcc link options(like whole-archive, --allow-multiple-definition) in CMake?

2016-05-31 Thread Chaos Zhang
tions where you may need the > actual file name but they are uncommon and even then you would do it > through target properties and generator expressions rather than hard code > the library file name. > > - Chuck > > On Mon, May 30, 2016 at 8:35 AM, Chaos Zhang <

[CMake] How to hundle gcc link options(like whole-archive, --allow-multiple-definition) in CMake?

2016-05-30 Thread Chaos Zhang
Hi, all, Thanks for taking your time to review my email. I have a demo project and it's structure like as below: top_dir CMakeLists.txt sub_dir1 CMakeLists.txt sub_dir2 CMakeLists.txt top_dir/sub_dir1/CMakeLists.txt used to build `lib1` by using `add_library(lib1 ...)

Re: [CMake] How to use 'CMAKE_EXE_LINKER_FLAGS' correctly

2016-05-24 Thread Chaos Zhang
path/to/foo/libfoo.a (or .so if it's shared) instead of -L/path/to/foo > -lfoo. CMake will adjust the flags to -L and -l if needed but the > preference is always to use the full library path. > > - Chuck > > On Mon, May 23, 2016 at 2:23 AM, Chaos Zhang < > zcsd20

Re: [CMake] How to use 'CMAKE_EXE_LINKER_FLAGS' correctly

2016-05-22 Thread Chaos Zhang
Thanks a lot! `set(FOO_LIBRARY "-Wl,--whole-archive ${FOO_LIBRARY} -Wl,--no-whole-archive")` worked when the content of ${FOO_LIBRARY} look like `-Ldir -llib`, if just use lib name as the content of ${FOO_LIBRARY}, error while occur. Chuck Atkins wrote >> -rpath > > > RPATHs are automatically a

Re: [CMake] How to use 'CMAKE_EXE_LINKER_FLAGS' correctly

2016-05-20 Thread Chaos Zhang
ia CMAKE_EXE_LINKER_FLAGS. > > - Chuck > > On Fri, May 20, 2016 at 4:28 AM, Chaos Zhang < > zcsd2012@ > > wrote: > >> Hi, all, >> >> I try to use some gcc link option and libs(except libs link by >> target_link_libraries(...)), i researched and try

[CMake] How to use 'CMAKE_EXE_LINKER_FLAGS' correctly

2016-05-20 Thread Chaos Zhang
Hi, all, I try to use some gcc link option and libs(except libs link by target_link_libraries(...)), i researched and try to use 'CMAKE_EXE_LINKER_FLAGS' in a simple project, as below: in dir, there are 5 files: -hello.h -hello.c -main.c -hello.o -libhello.a hello.o was compiled by hello.c(gcc -

[CMake] Linking CXX executable xxx :undefined reference to `stlp_std::cout'

2016-05-16 Thread Chaos Zhang
Hi all, I was trying to convert an existed c++ project to CMake. The existed worked well with makefile, and i have converted similar one successfully. but when i try to convert this one, some confusing errors occurred, as below: 18:22:10: Running steps for project encryption... 18:22:10: Starting

Re: [CMake] How to link shared lib on windows (visual studio 2014).

2016-04-26 Thread Chaos Zhang
ce instead of leaving them scattered across the various > sub-directories of the build folder. > > - Chuck > > On Tue, Apr 26, 2016 at 9:22 AM, Chaos Zhang < > zcsd2012@ > > wrote: > >> Hi, all, >> >> Thanks for your sincerely help, and i understa

Re: [CMake] How to link shared lib on windows (visual studio 2014).

2016-04-26 Thread Chaos Zhang
the long run and doesn't work as an actual solution > to > the problem if you are trying to solve it for many projects. > > -Caleb > > On Mon, Apr 25, 2016 at 9:01 PM, Chaos Zhang < > zcsd2012@ > > wrote: > >> Hi, >> >> I faced this

Re: [CMake] Need a example to use dll in vs

2016-04-25 Thread Chaos Zhang
trying to do, and what is failing. > > Sincerely, > Jakob van Bethlehem > > On Mon, Apr 25, 2016 at 5:13 AM, Chaos Zhang < > zcsd2012@ > > wrote: > >> Hi all, >> >> I faced a problem when i migrate a project from Linux to windows for the >>

[CMake] How to link shared lib on windows (visual studio 2014).

2016-04-25 Thread Chaos Zhang
here are two questions i could not figure out: ①Is this "..\sub_hello\Debug\hello_lib.lib" associates with "..\sub_hello\Debug\hello_lib.dll"? For windows can not use .dll directly, and use a .lib to record the .dll's entrance and location. ②How to solve the problem of main

[CMake] Exe file can't find .dll file on windows

2016-04-25 Thread Chaos Zhang
from your computer. Try reinstalling to fix this problem." And after i copy hello_lib.dll to the folder of exe file, it worked. Thanks, Chao Zhang -- View this message in context: http://cmake.3232098.n2.nabble.com/Exe-file-can-t-find-dll-file-on-windows-tp7593334.html Sent from the CMake maili

Re: [CMake] Need a example to use dll in vs

2016-04-24 Thread Chaos Zhang
; as part of my > cmake process. Then I make sure the builds' install area is in the path > of the application. > > The issue may be your EXE cant find the DLL in its path. > > Scott > > -Original Message- > From: CMake [mailto: > cmake-bounces@ > ]

[CMake] Need a example to use dll in vs

2016-04-24 Thread Chaos Zhang
give me one or some? BTW the dll lib seem could be used in Mingw makefile on windows. Thanks, Chao Zhang -- View this message in context: http://cmake.3232098.n2.nabble.com/Need-a-example-to-use-dll-in-vs-tp7593331.html Sent from the CMake mailing list archive at Nabble.com. -- Powered by

[CMake] How to transfer CMake variable and include other makefile in one makefile which generated by CMake

2016-04-23 Thread Chaos Zhang
is convert this makefile into CMakeLists.txt, and after cmake this CMakeLists.txt, i can get a makefile like this. What should i do? Thanks, Chao Zhang -- View this message in context: http://cmake.3232098.n2.nabble.com/How-to-transfer-CMake-variable-and-include-other-makefile-in-one-makefile

Re: [CMake] CMake:question of the time when the command will happen in add_custom_command(...)

2016-04-22 Thread Chaos Zhang
main"); > } > > The custom command becomes a part of the entire process of "Building > target," that's why the "Built target" message appears after the command > runs. > > BTW, please keep the mailing list in copy when replying. > > Petr &g

[CMake] CMake:question of the time when the command will happen in add_custom_command(...)

2016-04-21 Thread Chaos Zhang
Hi all, I have some trouble when i use PRE_BUILD | PRE_LINK | POST_BUILD in command "add_custom_command(...)". When i use POST_BUILD, i found the command will execute before target had been built, like this: 1 [root@VM_33_35_centos build]# make 2 Scanning dependencies of target main 3 [100%] Buil

[CMake] CMake: how to use 'for cyclic sentence' in command add_custom_command(...)

2016-04-19 Thread Chaos Zhang
do echo $x \; done\;) The result of execution was not like as below: a b c But like this: Just print 3 blank lines. So how to use it correctly? Thanks for your help, Chao Zhang -- View this message in context: http://cmake.3232098.n2.nabble.com/CMake-how-

Re: [CMake] CMake: how to use 'if condition' in command add_custom_command(...)

2016-04-19 Thread Chaos Zhang
quot;, if POST_BUILD gets treated as PRE_LINK, why "3_pre_build" was printed before "1_pre_link"? Thanks for you reply, Chaos Zhang ​ 2016-04-19 15:50 GMT+08:00 Craig Scott-3 [via CMake] < ml-node+s3232098n7593281...@n2.nabble.com>: > In case it matters, in Clark'

[CMake] CMake: how to use 'if condition' in command add_custom_command(...)

2016-04-18 Thread Chaos Zhang
Hi, Is there a way to use Linux command 'if' like this : <http://cmake.3232098.n2.nabble.com/file/n7593278/2016-04-19_113005.png> For i need to execute 'if condition' in make phase rather than cmake phase. Thanks a lot Chaos Zhang -- View this message in cont

Re: [CMake] CMP0026 - Disallow use of the LOCATION target property

2015-02-24 Thread Jifeng ZHANG
Thank you Steve and NoRulez. We actually make some manipulations on the string (TEST_PATH) that returned from get_target_property, before we pass it to add_test. So if we directly pass the generator expression, it won't work. We need to change this part obviously. Any idea when CMake 4.0 is plan

[CMake] CMP0026 - Disallow use of the LOCATION target property

2015-02-06 Thread Jifeng ZHANG
umentation. So to get the LOCATION of ${TEST_PROJECT}, I can use: set (TEST_PATH $) But if I want to get LOCATION_${CMAKE_BUILD_TYPE}, how can I do it? Thanks. -- Vänliga hälsningar/Best regards, Jifeng Zhang -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ

Re: [CMake] How about GNU Automatic Variables

2014-11-29 Thread Zhang Xianyi
Hi Decker, Thank you for the answer. If I want to debug test_double, the debugger will refer to ${CMAKE_BINARY_DIR}/test_double.c. I am not sure it is appropriate to debug a generated file. Xianyi 2014-11-28 23:03 GMT+08:00 J Decker : > > > On Fri, Nov 28, 2014 at 1:29 AM, Zha

Re: [CMake] L

2014-11-28 Thread Zhang Xianyi
Hi Crni, I just added generating OpenBLASConfig.cmake on OpenBLAS develop branch. ( https://github.com/xianyi/OpenBLAS/commit/fe7dcf98f3666388b75839c6b3e6656580dcd222 ) I think the find_package(OpenBLAS) works fine now. Xianyi 2014-11-11 16:35 GMT+08:00 Crni Gorac : > On Tue, Nov 11, 2014 at

[CMake] How about GNU Automatic Variables

2014-11-28 Thread Zhang Xianyi
Hi, I want to use cmake for a library which supports different floating point precision. In Makefile, I used $(*F) to generate the different function name. Could I use $(*F) in cmake? == test.c === #ifdef DOUBLE #define TYPE double #else #define TYPE float

[CMake] Support OpenBLAS in FindBLAS module

2014-11-04 Thread Zhang Xianyi
Hi Folks, I am the developer of OpenBLAS, an optimized BLAS implementation forked from GotoBLAS2. So far, the FindBLAS.cmake module cannot recognize OpenBLAS as a legitimate library. Is it possible to support OpenBLAS in FindBLAS module? Best Regards, Xianyi -- Powered by www.kitware.com Ple

[CMake] WiX installer default install_root

2013-10-30 Thread Evan Zhang
Hi, What is the proper method to set the WiX install path? I am trying to create a 64 bit MSI installer, but cannot get the INSTALL_ROOT variable to point away from "C:\Program Files(x86)" Consequently, when running CPACK, the wix.log alerts me to the following error messages : This 64Bit

[CMake] Setting CPack Module Path for WiX generator

2013-10-17 Thread Evan Zhang
Hi, I am attempting to set the CPack Module Path to point to a different directory when using the WiX generator so that I may use a customized WiX.template.in configuration file. I am doing this by adding the following line into my CPackConfig.cmake file before calling cpack through the command l

[CMake] Allow CPack generated WiX installer to set registry key values

2013-10-16 Thread Evan Zhang
Hi, Is there a way to set registry key values after defining the install registry key using "SET(CPACK_PACKAGE_INSTALL_REGISTRY_KEY "Example Registry Key")"? I would like to create an installer that actually populates REG_SZ string values under the key. I am assuming the above value for "CPAC

Re: [CMake] How to pack a target/file into multiple packages in Linux?

2012-11-04 Thread Ralph Zhang
That solves my problem, thank you! On Fri, Nov 2, 2012 at 4:56 PM, Eric Noulard wrote: > 2012/11/2 Ralph Zhang : > > Hi guys > > > > I'm working on a project which generates quite a few executables, > libraries > > and configs, they need to be packed into

[CMake] How to pack a target/file into multiple packages in Linux?

2012-11-01 Thread Ralph Zhang
Hi guys I'm working on a project which generates quite a few executables, libraries and configs, they need to be packed into different packages for deployment. The problem is, the inclusion of those targets/files is not mutual exclusive. One target/file can belong to multiple packages. I'm using

[CMake] Invitation to connect on LinkedIn

2011-06-17 Thread debao zhang via LinkedIn
LinkedIn debao zhang requested to add you as a connection on LinkedIn: -- Robert, I'd like to add you to my professional network on LinkedIn. - debao Accept invitation from debao zhang http://www.linkedin.com/e/-nf7vxk-gp0skr

[CMake] In MSVC, how can I link my exe with my library with the same configuration (release, minsizerel) separately

2009-11-10 Thread Meng Zhang
Dear CMakers, Sorry for disturbing. Since nobody gave the answer, I just rephrased the title of my question. I am a beginner of CMake. My problem is that in MSVC, I have two projects: one is executable project A, and the other is library project B. A depends on B and A has to link B. I want A

[CMake] How can I link to my MinSizeRel project in msvc

2009-11-09 Thread Meng Zhang
Dear CMakers, I am a beginner of CMake. My problem is that in MSVC, I have two projects: one is executable project A, and the other is library project B. A depends on B and A has to link B. I want A to link the corresponding B separately under different configurations. For example, if I build Rel

Re: [CMake] Help on how to handle the name of a object file?

2009-04-28 Thread zhang
Thanks Alex for your reply. Ok, the problem has been resolved. The setting SET(CMAKE_D_OUTPUT_EXTENSION_REPLACE 1) should be placed in CMakeDCompiler.cmake.in. After more tests, I'll submit my D module for CMake. -- Heromyth __ 赶快注册雅虎超

[CMake] Help on how to handle the name of a object file?

2009-04-24 Thread zhang
The default format of the obj's name is like this *.c.obj or *.cpp.obj, etc. I want the source-file-type in the name got rid of. What can I do in Cmake. I have no choice if some linkers like the Digitalmars's can't handle these names with this format. Thanks for any help. -- ___

Re: [CMake] General questions

2008-02-24 Thread Yang Zhang
Hendrik Sattler wrote: Am Sonntag 24 Februar 2008 schrieb Yang Zhang: I understand your point, but support for cmake is not as ubiquitous as it is for autotools. For instance, a cross-platform build system I'm using (a bitbake/openembedded derivative) does not support cmake. As another ex

Re: [CMake] General questions

2008-02-24 Thread Yang Zhang
Andreas Pakulat wrote: On 24.02.08 16:27:47, Yang Zhang wrote: - Can cmake auto-infer libraries based on #includes + a DB of header-to-library mappings? Not sure. I'll let the cmake developers answer that one. - Can cmake generate autotools inputs (for POSIX-portable preferably-GNU-comp

Re: [CMake] General questions

2008-02-24 Thread Yang Zhang
Yang Zhang wrote: Hi, thanks for your reply. Mike Jackson wrote: > > -- Mike Jackson Senior Research Engineer > Innovative Management & Technology Services > > > On Feb 23, 2008, at 4:34 AM, Yang Zhang wrote: >> - Can cmake auto-generate and cache

Re: [CMake] General questions

2008-02-24 Thread Yang Zhang
Hi, thanks for your reply. Mike Jackson wrote: > > -- Mike Jackson Senior Research Engineer > Innovative Management & Technology Services > > > On Feb 23, 2008, at 4:34 AM, Yang Zhang wrote: > >> Hi, I just finished reading the example in the documentation on the

[CMake] General questions

2008-02-23 Thread Yang Zhang
ging)? Thanks! -- Yang Zhang http://www.mit.edu/~y_z/ ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake

Re: [CMake] how to get compile environment ($host) in cmake

2007-05-17 Thread haibin zhang
Clark J. Wang" <[EMAIL PROTECTED]> 写道: On 5/17/07, haibin zhang <[EMAIL PROTECTED]> wrote: Hi all : how to get $host in cmake ? In autotool , it can use $host to get compile environment, example cygwin,i686-pc-mingw32 . Use CMAKE_SYSTEM regards --

[CMake] how to get compile environment ($host) in cmake

2007-05-16 Thread haibin zhang
Hi all : how to get $host in cmake ? In autotool , it can use $host to get compile environment, example cygwin,i686-pc-mingw32 . regards - Mp3疯狂搜-新歌热歌高速下 ___ CMake mailing list CMake@cmake.org ht

Re: [CMake] How to specify target specific CPPFLAGS or CFLAGS?

2007-05-15 Thread haibin zhang
Hi , Just as said, How can I change CFLAGS in configure in cmake? for example in autotool: //remove debug option ./configure --prefix=/opt CFLAGS=-O2 How to do it in cmake ? regards Eric Noulard <[EMAIL PROTECTED]> 写道: 2007/5/15, Clark J. Wang : > I have a C source file `foo.c' and I want to p

[CMake] Can't create Hello.lib in Visual C++ Express Edition 2005 SP1(using cmake example demo)

2007-05-12 Thread haibin zhang
Hi all : I can build demo using Hello.dll in Visual C++ Express Edition 2005, but when I upgrade Visual C++ Express Edition 2005 to sp1, I can't build it. the error is : -- Build started: Project: helloDemo, Configuration: Debug Win32 -- Linking... LINK : fatal error LNK1104: cannot open

[CMake] can't create makefile in Visual C++ Express Edition Version 8.0.50727.42 (using cmake example demo)

2007-05-10 Thread haibin zhang
Hi all: I can't create makefile in Visual C++ Express Edition Version 8.0.50727.42, I use Example in cmake. I found it want to find 'user32.lib', but system don't obtain it. it only have 'user32.dll' How to avoid it to go to find 'user32.lib'? the error is : E:zhb_svnmingwbuildc

[CMake] CMake generated rule is not recognized by make or dependency order?

2006-01-30 Thread Tao Zhang
I have an executable depends on some nonexisting files.I use ADD_CUSTOM_COMMAND to produce these files. However, make reports "no rule" errors even rules are there. Type "make envC.cpp" directly works instead. The rule in the Makefile: envC.cpp: /home/ship2rr/hdrsfaults.h @echo "Building