@@ -126,8 +126,8 @@ shards_to_test = expand_cxxstring_abis(expand_gfortran_versions(shards_to_test))
126
126
# Build for ALL the platforms
127
127
shards_to_test,
128
128
products,
129
- # No dependencies
130
- Dependency[ ];
129
+ # Express a dependency on CSL to silence warning for fortran code
130
+ [ Dependency ( " CompilerSupportLibraries_jll " ) ];
131
131
# We need to be able to build go and rust and whatnot
132
132
compilers= [:c , :go , :rust ],
133
133
)
@@ -190,15 +190,38 @@ end
190
190
Windows (:i686 ; compiler_abi= CompilerABI (;libgfortran_version= v " 3" )),
191
191
],
192
192
[ExecutableProduct (" hello_world_fortran" , :hello_world_fortran )],
193
- # No dependencies
194
- Dependency[ ];
193
+ # Express a dependency on CSL to silence warning for fortran code
194
+ [ Dependency ( " CompilerSupportLibraries_jll " ) ];
195
195
preferred_gcc_version= gcc_version,
196
196
)
197
197
198
198
# Just a simple test to ensure that it worked.
199
199
@test length (keys (build_output_meta)) == 6
200
200
end
201
201
end
202
+
203
+ # Test that building something that links against gfortran suggests depending on CSL
204
+ @test_logs (:warn , r" CompilerSupportLibraries_jll" ) match_mode= :any begin
205
+ mktempdir () do build_path
206
+ build_output_meta = autobuild (
207
+ build_path,
208
+ " csl_dependency" ,
209
+ v " 1.0.0" ,
210
+ # No sources
211
+ FileSource[],
212
+ # Build the test suite, install the binaries into our prefix's `bin`
213
+ raw """
214
+ # Build testsuite
215
+ make -j${nproc} -sC /usr/share/testsuite/fortran/hello_world install
216
+ # Install fake license just to silence the warning
217
+ install_license /usr/share/licenses/libuv/LICENSE
218
+ """ ,
219
+ [Linux (:x86_64 ; compiler_abi= CompilerABI (;libgfortran_version= v " 3" ))],
220
+ [ExecutableProduct (" hello_world_fortran" , :hello_world_fortran )],
221
+ Dependency[],
222
+ )
223
+ end
224
+ end
202
225
end
203
226
204
227
@testset " Invalid Arguments" begin
0 commit comments