SYSTEM is a function that returns an integer result, so declare a variable:
integer iret
and then change the call to:
iret = system(tmpline)
The Fortran standard does not allow calling a function as a subroutine. Indeed, earlier versions of our compiler did allow this, under some conditions, but the restrictions were not enough to avoid possible bad results and, after long debate, we decided that as the number of cases where this was harmless was small enough it was simpler to just make it an error. The problem has to do with mismatched assumptions about where arguments and return values get placed.
Reference: Error: The CALL statement is invoking a function subprogram as a subroutine