]> git.ipfire.org Git - thirdparty/gcc.git/blame - libgfortran/mk-sik-inc.sh
* MAINTAINERS: Update my email address.
[thirdparty/gcc.git] / libgfortran / mk-sik-inc.sh
CommitLineData
625be286
RH
1#!/bin/sh
2
3compile="$1"
4kinds=""
5possible_kinds="1 2 4 8 16"
6c=0
7
8for k in $possible_kinds; do
9 echo " integer (kind=$k) :: x" > tmp$$.f90
10 echo " end" >> tmp$$.f90
4349e292 11 if $compile -S tmp$$.f90 > /dev/null 2>&1; then
625be286
RH
12 kinds="$kinds $k"
13 c=`expr $c + 1`
14 fi
15 rm -f tmp$$.*
16done
17
18echo " integer, parameter :: c = $c"
19echo " type (int_info), parameter :: int_infos(c) = (/ &"
20
21i=0
22for k in $kinds; do
130abd17
EB
23 # echo -n is not portable
24 str=" int_info ($k, range(0_$k))"
625be286
RH
25 i=`expr $i + 1`
26 if [ $i -lt $c ]; then
130abd17 27 echo "$str, &"
625be286 28 else
130abd17 29 echo "$str /)"
625be286
RH
30 fi
31done
32
33exit 0