diff --git a/bin/cygport.in b/bin/cygport.in
index 15bd559e..074c86e1 100755
--- a/bin/cygport.in
+++ b/bin/cygport.in
@@ -630,14 +630,19 @@ fi
 # this requires S and B to be already defined
 if ! defined _CYGPORT_RESTRICT_debuginfo_
 then
+	prefix_map_option=file-prefix-map
+	if defined FORCE_DEBUG_PREFIX_MAP
+	then
+		prefix_map_option=debug-prefix-map
+	fi
 	for flags in {C,CXX,F,FC,GO,OBJC,OBJCXX}FLAGS
 	do
 		for map in ${DEBUG_PREFIX_MAPS[*]}
 		do
-			declare ${flags}+=" -ffile-prefix-map=${map}=/usr/src/debug/${PF}"
+			declare ${flags}+=" -f${prefix_map_option}=${map}=/usr/src/debug/${PF}"
 		done
-		declare ${flags}+=" -ffile-prefix-map=${B}=/usr/src/debug/${PF}"
-		declare ${flags}+=" -ffile-prefix-map=${S}=/usr/src/debug/${PF}"
+		declare ${flags}+=" -f${prefix_map_option}=${B}=/usr/src/debug/${PF}"
+		declare ${flags}+=" -f${prefix_map_option}=${S}=/usr/src/debug/${PF}"
 	done
 	unset flags map
 fi
