OSDN Git Service

Linux/Unix: tighten regexp gcc-wrap uses to set the object file name so it works...
authorEric Branlund <ebranlund@fastmail.com>
Mon, 13 Jun 2022 13:35:32 +0000 (07:35 -0600)
committerEric Branlund <ebranlund@fastmail.com>
Mon, 13 Jun 2022 13:35:32 +0000 (07:35 -0600)
src/gcc-wrap

index 524e9f9..c057242 100755 (executable)
@@ -5,7 +5,7 @@ jp=$(grep "#define JP" autoconf.h | wc -l)
 if test $jp -eq 1; then
     # Prepare the various file paths.
     eval SRC_FILE=\${$#}
-    OBJ_FILE=$(echo $SRC_FILE | sed -E 's/\..+$/\.o/')
+    OBJ_FILE=$(echo $SRC_FILE | sed -E 's/\.[^./]+$/\.o/')
     SRC_DIR=$(
         cd $(dirname $0)
         pwd