- # Change a hardcoded path from /usr/include to /tools/include:
- sed -i 's@/usr/include@/tools/include@g' ${LFS_TMP}/${PACKAGE}/ext/Errno/Errno_pm.PL
-}
+ # By default, Perl's Compress::Raw::Zlib module builds and links against
+ # its own internal copy of Zlib. The following command will tell it to
+ # use the system-installed Zlib:
+ sed -e '/^BUILD_ZLIB/s/True/False/' \
+ -e '/^INCLUDE/s,\./zlib-src,/usr/include,' \
+ -e '/^LIB/s,\./zlib-src,/usr/lib,' \
+ -i ${SRC_DIR}/cpan/Compress-Raw-Zlib/config.in