install CODE Parse error

install(CODE install_name_tool -change “./libMylib.dylib” “@executable_path/libMylib.dylib” ./Myapp)

i have parse error:

Parse error. Expected “(”, got newline with text "

".

install(CODE) expects CMake code, not an arbitrary shell command. You can use something like:

install(CODE "execute_process (...)")