[Cmake] Execute permissions on a configured file

Andy Cedilnik andy . cedilnik at kitware . com
21 Aug 2003 08:59:00 -0400


Hi Both,

Make sure to put IF(UNIX) around.

			Andy

On Thu, 2003-08-21 at 08:33, Brad King wrote:
> > I'm using the CONFIGURE_FILE command to create a shell script. How can I
> > force the created file to have execute permission?
> 
> CONFIGURE_FILE(..input.. ..output.. @ONLY IMMEDIATE)
> EXEC_PROGRAM(chmod ARGS 755 ..output..)
> 
> The IMMEDIATE argument ensures that the output is created immediately when
> CONFIGURE_FILE is called.  Be sure to use full paths for input and output.