From: Vladislav Vaintroub Date: January 28 2011 4:40pm Subject: RE: bzr push into mysql-5.5-bugteam branch (joerg:3108 to 3109) List-Archive: http://lists.mysql.com/commits/129897 Message-Id: <019a01cbbf0a$09751f80$1c5f5e80$@montyprogram.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable > -----Original Message----- > From: Joerg Bruehe [mailto:joerg.bruehe@stripped] > Sent: Freitag, 28. Januar 2011 16:25 > To: Vladislav Vaintroub > Cc: commits@stripped > Subject: Re: bzr push into mysql-5.5-bugteam branch (joerg:3108 to = 3109) >=20 > Hi Wlad, >=20 >=20 > thanks for the hint: >=20 > Vladislav Vaintroub wrote: > > Hi Joerg, > > > >> -----Original Message----- > >> From: Joerg Bruehe [mailto:joerg@stripped] > >> Sent: Freitag, 28. Januar 2011 15:28 > >> To: commits@stripped > >> Subject: bzr push into mysql-5.5-bugteam branch (joerg:3108 to = 3109) > > > > > >> FILE(READ ${CMAKE_SOURCE_DIR}/INFO_SRC SOURCE_INFO) > >> FILE(WRITE ${INFO_SRC} "${SOURCE_INFO}\n") > > > > if you just want to copy a file, > > configure_file( COPYONLY) > > > > is your friend, as documented in the inline-help : cmake = --help-command configure_file >=20 > I'm still in the test/development phase, therefore the many debug = lines. > But yes, "configure_file(... copyonly)" looks quite clean. >=20 > However, I just stumbled over the fact that using a relative "path" in > IF(EXISTS path) > FILE(READ path ...) > I get a read error, because the "exists" and the "read" interpret that > name relative to different start points: > - "exists" uses the current directory, > - "read" uses the source tree. I found it simpler to always use full paths (except in ADD_EXECUTABLE = or ADD_LIBRARY) Variables=20 ${CMAKE_CURRENT_BINARY_DIR}=20 ${CMAKE_BINARY_DIR}=20 ${CMAKE_CURRENT_SOURCE _DIR} ${CMAKE_SOURCE _DIR} make it easy (also for the reader) and there is no ambiguity.=20 > So I realize any change needs lots of testing. >=20 >=20 > Regards, > J=F6rg >=20 > -- > Joerg Bruehe, MySQL Build Team, joerg.bruehe@stripped > (+49 30) 417 01 487 > ORACLE Deutschland B.V. & Co. KG, Komturstrasse 18a, D-12099 = Berlin > Geschaeftsfuehrer: Juergen Kunz, Marcel v.d. Molen, Alexander v.d. Ven > Amtsgericht Muenchen: HRA 95603