Suppose sub1.f90 contains subroutine sub1 sub45.f90 contains subroutines sub4 and sub5 % ar -r libsubs.a sub1.o sub45.o % ar -t libsubs.a sub1.o sub45.o % nm libsubs.a sub1.o: U _g95_filename U _g95_get_ioparm U _g95_ioparm U _g95_line U _g95_st_write U _g95_st_write_done U _g95_transfer_character 00000000 T sub1_ sub45.o: U _g95_filename U _g95_get_ioparm U _g95_ioparm U _g95_line U _g95_st_write U _g95_st_write_done U _g95_transfer_character U sub2_ 00000000 T sub4_ 00000078 T sub5_ "T" The symbol is in the text (code) section. "U" The symbol is undefined. Can write nm sub1.o as well. However: % strip sub1.o % nm sub1.o nm: sub1.o: no symbols -------------------------------------------------- typedef struct { double v[10]; int n; } my_mxArray; // void ex1(my_mxArray const * s[]) or void ex1(const my_mxArray * s[]) // Like the MEX-file { (*s[0]).v[5] = 7; // illegal s[0]->v[5] = 7; // illegal s[1] = s[0]; // OK } void ex2(my_mxArray * const s[]) { s[0]->v[5] = 7; // OK s[1] = s[0]; // illegal } void ex3(const my_mxArray * const s[]) { s[0]->v[5] = 7; // illegal s[1] = s[0]; // illegal } void ex4(const my_mxArray * const s[]) { double *pv; pv = (double *) s[0]->v; pv[5] = 7; // OK }