On Mon, 2007-08-06 at 10:28 -0700, Steve Ellcey wrote: > I am running into a problem running the gfortran.dg/c_kind_params.f90 > and am wondering how to address it. This test has a C language > component in gfortran.dg/c_kinds.c. This C file includes stdint.h and > uses types like int32_t and int64_t. On HPPA HP-UX platforms we don't > have a stdint.h header file so I would like to disable the test on that > platform. We currently have a test for this so I put > > ! { dg-require-effective-target stdint_types } > > in gfortran.dg/c_kind_params.f90. This did turn off the test for the > HPPA platforms but it also seemed to turn it off on the Linux platforms > and it should not have done that. > > So my question is: is it OK to run this type of check (where the check > compiles C code) in a non-C testsuite like gfortran.dg? Should I put > the check in c_kinds.c instead? I didn't try that but I don't think it > would work. Or can I just not use this test in gfortran.dg?
I added it to c_kind_params.f90 in this position: ! { dg-do run } ! { dg-require-effective-target stdint_types } ! { dg-additional-sources c_kinds.c } ! { dg-options "-w -std=c99" } and the test runs on powerpc64-linux for both -m32 and -m64. Did you have it in a different position? If so I'll try that and see if I can figure out why it would be skipped. Also, which target were you testing? Most of the effective target checks use C code. I think it's safe to assume that the build or install tree being tested will always have a C compiler available. Janis