Skip to content

Reproduce does not work when linker script is found within a -L directory #1454

Description

@parth-07

Reproduce does not work when a linker script is found within a -L directory.

Reproducer:

#!/usr/bin/env bash

set -e

mkdir -p A/lib

cat >main.c <<\EOF
int foo() { return 1; }
int main() { return foo(); }
EOF

cat >script.t <<\EOF
EOF

clang -target x86_64-linux-gnu -o main.o main.c -c -ffunction-sections 
mv script.t A/lib

ld.eld -o main.eld.out main.o -L A/lib -T script.t --reproduce a.tar 
rm -rf reproduce && mkdir reproduce -p
tar -xvf a.tar -C reproduce --strip-components=1
cd reproduce
bash -x response.txt 

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions