diff --git a/meta/recipes-support/curl/curl_8.19.0.bb b/meta/recipes-support/curl/curl_8.19.0.bb
index b9251336b8..cc37cc934b 100644
--- a/meta/recipes-support/curl/curl_8.19.0.bb
+++ b/meta/recipes-support/curl/curl_8.19.0.bb
@@ -93,13 +93,15 @@ EXTRA_OECONF = " \
 "
 
 fix_absolute_paths () {
-	# cleanup buildpaths from curl-config
+	# cleanup buildpaths from curl-config and libcurl.pc
 	sed -i \
 	    -e 's,--sysroot=${STAGING_DIR_TARGET},,g' \
 	    -e 's,--with-libtool-sysroot=${STAGING_DIR_TARGET},,g' \
+	    -e 's,--with-mbedtls=${STAGING_DIR_TARGET},--with-mbedtls,g' \
+	    -e 's,-L${STAGING_DIR_TARGET},,g' \
 	    -e 's|${DEBUG_PREFIX_MAP}||g' \
 	    -e 's|${@" ".join(d.getVar("DEBUG_PREFIX_MAP").split())}||g' \
-	    ${D}${bindir}/curl-config
+	    ${D}${bindir}/curl-config ${D}${libdir}/pkgconfig/libcurl.pc
 }
 
 do_install:append:class-target() {
