help with sed for post-patch

Rainer Hurling rhurlin at gwdg.de
Mon Mar 22 06:37:46 UTC 2010


Am 21.03.2010 21:42 (UTC+1) schrieb Tijl Coosemans:
> On Sunday 21 March 2010 21:14:11 Eitan Adler wrote:
>> I need to change
>> set(LIBRARY_OUTPUT_PATH ${CMAKE_BINARY_DIR}/lib)
>> to
>> set(LIBRARY_OUTPUT_PATH libdata/lib)
>>
>> Here is what I have
>> ${REINPLACE_CMD} -E 's/\$\{CMAKE_BINARY_DIR\}\/lib/libdata\/lib/'
>> ${WRKSRC}/CMakeLists.txt
>>
>> how could I fix this?
>
> In a Makefile you have to replace $ by $$.
>
> ${REINPLACE_CMD} 's,$${CMAKE_BINARY_DIR}/lib,libdata/lib,' ${WRKSRC}/CMakeLists.txt

and, as far as I understand, put "-e" between command and the rest (see 
Porters Handbook, chapter 4.4):

${REINPLACE_CMD} -e 's,$${CMAKE_BINARY_DIR}/lib,libdata/lib,' 
${WRKSRC}/CMakeLists.txt


More information about the freebsd-ports mailing list