Indeed, if I replace
character(len=100, kind=ucs4) :: string
simply by
character(len=100) :: string
in my program, ifx does read my UTF-8 file, does print the French characters in terminal and does write correctly the UTF-8 utf_out.txt
file…
$ ifx fr.f90 && ./a.out
Lire des caractères accentués n'est pas difficile. Inutile d'apprendre ça par cœur.
éèçàâäùëêïîüûöô
But the program then does not work anymore correctly with GFortran…
Things are not yet clear in my mind…