brintos

brintos / llvm-project-archived public Read only

0
0
Text · 4.8 KiB · 07f967b Raw
107 lines · plain
1! Make sure that `-l` is "visible" to Flang's driver2! RUN: %flang -lpgmath -### %s3 4! Make sure that `-Wl` is "visible" to Flang's driver5! RUN: %flang -Wl,abs -### %s6 7! Make sure that `-fuse-ld' is "visible" to Flang's driver8! RUN: %flang -fuse-ld= -### %s9 10! Make sure that `-L' is "visible" to Flang's driver11! RUN: %flang -L/ -### %s12 13! ------------------------------------------------------------------------------14! Check that '-pie' and '-no-pie' are "visible" to Flang's driver. Check that15! the correct option is added to the link line.16!17! Last match "wins"18! RUN: %flang -target x86_64-pc-linux-gnu -pie -no-pie -### %s 2>&1 \19! RUN:     | FileCheck %s --check-prefix=NO-PIE20! RUN: %flang -target x86_64-pc-linux-gnu -no-pie -pie -### %s 2>&1 \21! RUN:     | FileCheck %s --check-prefix=PIE22! RUN: %flang -target x86_64-pc-linux-gnu -pie -### %s 2>&1 \23! RUN:     | FileCheck %s --check-prefix=PIE24! RUN: %flang -target x86_64-pc-linux-gnu -no-pie -### %s 2>&1 \25! RUN:     | FileCheck %s --check-prefix=NO-PIE26!27! Ensure that "-pie" is passed to the linker.28! RUN: %flang -target i386-unknown-freebsd -pie -### %s 2>&1 \29! RUN:     | FileCheck %s --check-prefix=PIE30! RUN: %flang -target aarch64-pc-linux-gnu -pie -### %s 2>&1 \31! RUN:     | FileCheck %s --check-prefix=PIE32!33! On Musl Linux, PIE is enabled by default, but can be disabled.34! RUN: %flang -target x86_64-linux-musl -### %s 2>&1 \35! RUN:   | FileCheck %s --check-prefix=PIE36! RUN: %flang -target i686-linux-musl -### %s 2>&1 \37! RUN:   | FileCheck %s --check-prefix=PIE38! RUN: %flang -target armv6-linux-musleabihf %s -### 2>&1 \39! RUN:   | FileCheck %s --check-prefix=PIE40! RUN: %flang -target armv7-linux-musleabihf %s -### 2>&1 \41! RUN:   | FileCheck %s --check-prefix=PIE42! RUN: %flang --target=x86_64-linux-musl -no-pie -### 2>&1 \43! RUN:   | FileCheck %s --check-prefix=NO-PIE44!45! On OpenBSD, -pie is not passed to the linker, but can be forced.46! RUN: %flang -target amd64-pc-openbsd -### %s 2>&1 \47! RUN:   | FileCheck %s --check-prefix=NO-PIE48! RUN: %flang -target i386-pc-openbsd -### %s 2>&1 \49! RUN:   | FileCheck %s --check-prefix=NO-PIE50! RUN: %flang -target aarch64-unknown-openbsd -### %s 2>&1 \51! RUN:   | FileCheck %s --check-prefix=NO-PIE52! RUN: %flang -target arm-unknown-openbsd -### %s 2>&1 \53! RUN:   | FileCheck %s --check-prefix=NO-PIE54! RUN: %flang -target powerpc-unknown-openbsd -### %s 2>&1 \55! RUN:   | FileCheck %s --check-prefix=NO-PIE56! RUN: %flang -target sparc64-unknown-openbsd -### %s 2>&1 \57! RUN:   | FileCheck %s --check-prefix=NO-PIE58! RUN: %flang -target i386-pc-openbsd -pie -### %s 2>&1 \59! RUN:   | FileCheck %s --check-prefix=PIE60!61! On FreeBSD, -pie is not passed to the linker, but can be forced.62! RUN: %flang -target amd64-pc-freebsd -### %s 2>&1 \63! RUN:   | FileCheck %s --check-prefix=NO-PIE64! RUN: %flang -target i386-pc-freebsd -### %s 2>&1 \65! RUN:   | FileCheck %s --check-prefix=NO-PIE66! RUN: %flang -target aarch64-unknown-freebsd -### %s 2>&1 \67! RUN:   | FileCheck %s --check-prefix=NO-PIE68! RUN: %flang -target arm-unknown-freebsd -### %s 2>&1 \69! RUN:   | FileCheck %s --check-prefix=NO-PIE70! RUN: %flang -target powerpc-unknown-freebsd -### %s 2>&1 \71! RUN:   | FileCheck %s --check-prefix=NO-PIE72! RUN: %flang -target sparc64-unknown-freebsd -### %s 2>&1 \73! RUN:   | FileCheck %s --check-prefix=NO-PIE74! RUN: %flang -target i386-pc-freebsd -pie -### %s 2>&1 \75! RUN:   | FileCheck %s --check-prefix=PIE76!77! On AIX, -pie is never passed to the linker.78! RUN: %flang -target powerpc64-unknown-aix -### %s 2>&1 \79! RUN:     | FileCheck %s --check-prefixes=NO-PIE80! RUN: %flang -target powerpc64-unknown-aix -pie -### %s 2>&1 \81! RUN:     | FileCheck %s --check-prefixes=NO-PIE,UNUSED82! RUN: %flang -target powerpc64-unknown-aix -no-pie -### %s 2>&1 \83! RUN:     | FileCheck %s --check-prefixes=NO-PIE,UNUSED84!85! On MinGW and Windows, -pie may be specified, but it is ignored.86! RUN: %flang -target aarch64-pc-windows-gnu -### %s 2>&1 \87! RUN:   | FileCheck %s --check-prefixes=NO-PIE88! RUN: %flang -target x86_64-pc-windows-gnu -pie -### %s 2>&1 \89! RUN:   | FileCheck %s --check-prefixes=NO-PIE,UNUSED90! RUN: %flang -target i686-pc-windows-gnu -no-pie -### %s 2>&1 \91! RUN:   | FileCheck %s --check-prefixes=NO-PIE,UNUSED92! RUN: %flang -target aarch64-windows-msvc -### %s 2>&1 \93! RUN:     | FileCheck %s --check-prefixes=NO-PIE94! RUN: %flang -target aarch64-windows-msvc -pie -### %s 2>&1 \95! RUN:     | FileCheck %s --check-prefixes=NO-PIE,UNUSED96! RUN: %flang -target aarch64-windows-msvc -no-pie -### %s 2>&1 \97! RUN:     | FileCheck %s --check-prefixes=NO-PIE,UNUSED98!99! PIE: "-pie"100! NO-PIE-NOT: "-pie"101! UNUSED: warning: argument unused during compilation: '{{(-no)?}}-pie'102! ------------------------------------------------------------------------------103 104program hello105  write(*,*), "Hello world!"106end program hello107