RuntimeError: unable to find C type for type integer(kind=kind(0))

36 views
Skip to first unread message

Ondrej Certik

unread,
Aug 9, 2010, 5:56:58 PM8/9/10
to fwrap...@googlegroups.com
Hi,

I have now tried to run tests and I got:

$ python runtests.py -vv --fcompiler=gnu95 --no-cleanup
Python 2.6.4 (r264:75706, Jun 12 2010, 15:15:24)
[GCC 4.1.2 20080704 (Red Hat 4.1.2-48)]

wrapping all_char.f90 ... ERROR
wrapping char_args.f90 ... ERROR
wrapping cmplx_array.f90 ... ERROR
wrapping default_types.f90 ... ERROR
wrapping int_args.f90 ... ERROR
wrapping many_args.f90 ... ERROR
wrapping old_decl.f90 ... ERROR
wrapping py_kw_arg.f90 ... ERROR
wrapping simple_array.f90 ... ERROR
compiling and running all_char.f90 ... ERROR
compiling and running all_char_arrays.f90 ... ERROR
compiling and running all_complex.f90 ... ERROR
compiling and running all_complex_arrays.f90 ... ERROR
compiling and running all_integer_arrays.f90 ... ERROR
compiling and running all_ints.f90 ... ERROR
compiling and running all_logical_arrays.f90 ... ERROR
compiling and running all_logicals.f90 ... ERROR
compiling and running all_real_arrays.f90 ... ERROR
compiling and running all_reals.f90 ... ERROR
compiling and running array_intents.f90 ... ERROR
compiling and running array_types.f90 ... ERROR
compiling and running char_array.f90 ... ERROR
compiling and running default_types.f90 ... ERROR
compiling and running dim_expr.f90 ... ERROR
compiling and running func_returns.f90 ... ERROR
compiling and running int_args.f90 ... ERROR
compiling and running ndims.f90 ... ERROR
compiling and running old_decl.f90 ... ERROR

======================================================================
ERROR: wrapping all_char.f90
----------------------------------------------------------------------
Traceback (most recent call last):
File "runtests.py", line 207, in runTest
build_ext=True)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/main.py", line 600, in main
wrap(source_files, **parsed_options.__dict__)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/main.py", line 240, in wrap
run_setup(file_name, script_args=make_scriptargs(kargs))
File "/home/certik1/repos/femhub/local/lib/python/distutils/core.py",
line 221, in run_setup
exec open(script_name, 'r').read() in g, l
File "<string>", line 6, in <module>
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 77, in setup
np_setup(*args, **kwargs)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/core.py",
line 184, in setup
return old_setup(**new_attr)
File "/home/certik1/repos/femhub/local/lib/python/distutils/core.py",
line 152, in setup
dist.run_commands()
File "/home/certik1/repos/femhub/local/lib/python/distutils/dist.py",
line 975, in run_commands
self.run_command(cmd)
File "/home/certik1/repos/femhub/local/lib/python/distutils/dist.py",
line 995, in run_command
cmd_obj.run()
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 130, in run
self.build_sources()
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 147, in build_sources
self.build_extension_sources(ext)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 250, in build_extension_sources
sources = self.generate_sources(sources, ext)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 307, in generate_sources
source = func(extension, build_dir)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 91,
in generate_type_config
return gen_type_map_files(config_cmd)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 106,
in gen_type_map_files
find_types(ctps, config_cmd)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 123,
in find_types
"unable to find C type for type %s" % ctp.odecl)
RuntimeError: unable to find C type for type character(1)

======================================================================
ERROR: wrapping char_args.f90
----------------------------------------------------------------------
Traceback (most recent call last):
File "runtests.py", line 207, in runTest
build_ext=True)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/main.py", line 600, in main
wrap(source_files, **parsed_options.__dict__)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/main.py", line 240, in wrap
run_setup(file_name, script_args=make_scriptargs(kargs))
File "/home/certik1/repos/femhub/local/lib/python/distutils/core.py",
line 221, in run_setup
exec open(script_name, 'r').read() in g, l
File "<string>", line 6, in <module>
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 77, in setup
np_setup(*args, **kwargs)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/core.py",
line 184, in setup
return old_setup(**new_attr)
File "/home/certik1/repos/femhub/local/lib/python/distutils/core.py",
line 152, in setup
dist.run_commands()
File "/home/certik1/repos/femhub/local/lib/python/distutils/dist.py",
line 975, in run_commands
self.run_command(cmd)
File "/home/certik1/repos/femhub/local/lib/python/distutils/dist.py",
line 995, in run_command
cmd_obj.run()
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 130, in run
self.build_sources()
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 147, in build_sources
self.build_extension_sources(ext)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 250, in build_extension_sources
sources = self.generate_sources(sources, ext)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 307, in generate_sources
source = func(extension, build_dir)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 91,
in generate_type_config
return gen_type_map_files(config_cmd)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 106,
in gen_type_map_files
find_types(ctps, config_cmd)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 123,
in find_types
"unable to find C type for type %s" % ctp.odecl)
RuntimeError: unable to find C type for type character(1)

======================================================================
ERROR: wrapping cmplx_array.f90
----------------------------------------------------------------------
Traceback (most recent call last):
File "runtests.py", line 207, in runTest
build_ext=True)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/main.py", line 600, in main
wrap(source_files, **parsed_options.__dict__)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/main.py", line 240, in wrap
run_setup(file_name, script_args=make_scriptargs(kargs))
File "/home/certik1/repos/femhub/local/lib/python/distutils/core.py",
line 221, in run_setup
exec open(script_name, 'r').read() in g, l
File "<string>", line 6, in <module>
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 77, in setup
np_setup(*args, **kwargs)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/core.py",
line 184, in setup
return old_setup(**new_attr)
File "/home/certik1/repos/femhub/local/lib/python/distutils/core.py",
line 152, in setup
dist.run_commands()
File "/home/certik1/repos/femhub/local/lib/python/distutils/dist.py",
line 975, in run_commands
self.run_command(cmd)
File "/home/certik1/repos/femhub/local/lib/python/distutils/dist.py",
line 995, in run_command
cmd_obj.run()
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 130, in run
self.build_sources()
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 147, in build_sources
self.build_extension_sources(ext)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 250, in build_extension_sources
sources = self.generate_sources(sources, ext)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 307, in generate_sources
source = func(extension, build_dir)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 91,
in generate_type_config
return gen_type_map_files(config_cmd)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 106,
in gen_type_map_files
find_types(ctps, config_cmd)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 123,
in find_types
"unable to find C type for type %s" % ctp.odecl)
RuntimeError: unable to find C type for type character(1)

======================================================================
ERROR: wrapping default_types.f90
----------------------------------------------------------------------
Traceback (most recent call last):
File "runtests.py", line 207, in runTest
build_ext=True)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/main.py", line 600, in main
wrap(source_files, **parsed_options.__dict__)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/main.py", line 240, in wrap
run_setup(file_name, script_args=make_scriptargs(kargs))
File "/home/certik1/repos/femhub/local/lib/python/distutils/core.py",
line 221, in run_setup
exec open(script_name, 'r').read() in g, l
File "<string>", line 6, in <module>
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 77, in setup
np_setup(*args, **kwargs)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/core.py",
line 184, in setup
return old_setup(**new_attr)
File "/home/certik1/repos/femhub/local/lib/python/distutils/core.py",
line 152, in setup
dist.run_commands()
File "/home/certik1/repos/femhub/local/lib/python/distutils/dist.py",
line 975, in run_commands
self.run_command(cmd)
File "/home/certik1/repos/femhub/local/lib/python/distutils/dist.py",
line 995, in run_command
cmd_obj.run()
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 130, in run
self.build_sources()
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 147, in build_sources
self.build_extension_sources(ext)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 250, in build_extension_sources
sources = self.generate_sources(sources, ext)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 307, in generate_sources
source = func(extension, build_dir)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 91,
in generate_type_config
return gen_type_map_files(config_cmd)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 106,
in gen_type_map_files
find_types(ctps, config_cmd)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 123,
in find_types
"unable to find C type for type %s" % ctp.odecl)
RuntimeError: unable to find C type for type integer(kind=kind(0))

======================================================================
ERROR: wrapping int_args.f90
----------------------------------------------------------------------
Traceback (most recent call last):
File "runtests.py", line 207, in runTest
build_ext=True)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/main.py", line 600, in main
wrap(source_files, **parsed_options.__dict__)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/main.py", line 240, in wrap
run_setup(file_name, script_args=make_scriptargs(kargs))
File "/home/certik1/repos/femhub/local/lib/python/distutils/core.py",
line 221, in run_setup
exec open(script_name, 'r').read() in g, l
File "<string>", line 6, in <module>
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 77, in setup
np_setup(*args, **kwargs)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/core.py",
line 184, in setup
return old_setup(**new_attr)
File "/home/certik1/repos/femhub/local/lib/python/distutils/core.py",
line 152, in setup
dist.run_commands()
File "/home/certik1/repos/femhub/local/lib/python/distutils/dist.py",
line 975, in run_commands
self.run_command(cmd)
File "/home/certik1/repos/femhub/local/lib/python/distutils/dist.py",
line 995, in run_command
cmd_obj.run()
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 130, in run
self.build_sources()
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 147, in build_sources
self.build_extension_sources(ext)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 250, in build_extension_sources
sources = self.generate_sources(sources, ext)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 307, in generate_sources
source = func(extension, build_dir)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 91,
in generate_type_config
return gen_type_map_files(config_cmd)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 106,
in gen_type_map_files
find_types(ctps, config_cmd)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 123,
in find_types
"unable to find C type for type %s" % ctp.odecl)
RuntimeError: unable to find C type for type integer(kind=2)

======================================================================
ERROR: wrapping many_args.f90
----------------------------------------------------------------------
Traceback (most recent call last):
File "runtests.py", line 207, in runTest
build_ext=True)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/main.py", line 600, in main
wrap(source_files, **parsed_options.__dict__)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/main.py", line 240, in wrap
run_setup(file_name, script_args=make_scriptargs(kargs))
File "/home/certik1/repos/femhub/local/lib/python/distutils/core.py",
line 221, in run_setup
exec open(script_name, 'r').read() in g, l
File "<string>", line 6, in <module>
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 77, in setup
np_setup(*args, **kwargs)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/core.py",
line 184, in setup
return old_setup(**new_attr)
File "/home/certik1/repos/femhub/local/lib/python/distutils/core.py",
line 152, in setup
dist.run_commands()
File "/home/certik1/repos/femhub/local/lib/python/distutils/dist.py",
line 975, in run_commands
self.run_command(cmd)
File "/home/certik1/repos/femhub/local/lib/python/distutils/dist.py",
line 995, in run_command
cmd_obj.run()
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 130, in run
self.build_sources()
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 147, in build_sources
self.build_extension_sources(ext)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 250, in build_extension_sources
sources = self.generate_sources(sources, ext)
File "/home/certik1/repos/femhub/local/lib/python2.6/site-packages/numpy/distutils/command/build_src.py",
line 307, in generate_sources
source = func(extension, build_dir)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 91,
in generate_type_config
return gen_type_map_files(config_cmd)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 106,
in gen_type_map_files
find_types(ctps, config_cmd)
File "/home/certik1/ext/fwrap-0.1.1/fwrap/fwrap_setup.py", line 123,
in find_types
"unable to find C type for type %s" % ctp.odecl)
RuntimeError: unable to find C type for type integer(kind=kind(0))
[...]

and lots of errors like this.


$ gfortran -v
Using built-in specs.
Target: i386-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
--infodir=/usr/share/info --enable-shared --enable-threads=posix
--enable-checking=release --with-system-zlib --enable-__cxa_atexit
--disable-libunwind-exceptions --enable-libgcj-multifile
--enable-languages=c,c++,objc,obj-c++,java,fortran,ada
--enable-java-awt=gtk --disable-dssi --enable-plugin
--with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre
--with-cpu=generic --host=i386-redhat-linux
Thread model: posix
gcc version 4.1.2 20080704 (Red Hat 4.1.2-48)

$ cython -V
Cython version 0.13pre


Ondrej

Ondrej Certik

unread,
Aug 9, 2010, 5:57:50 PM8/9/10
to fwrap...@googlegroups.com
On Mon, Aug 9, 2010 at 2:56 PM, Ondrej Certik <ond...@certik.cz> wrote:
> Hi,
>
> I have now tried to run tests and I got:
>
> $ python runtests.py -vv --fcompiler=gnu95 --no-cleanup
[...]
> and lots of errors like this.
>
>
> $ gfortran -v
> Using built-in specs.
> Target: i386-redhat-linux
> Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
> --infodir=/usr/share/info --enable-shared --enable-threads=posix
> --enable-checking=release --with-system-zlib --enable-__cxa_atexit
> --disable-libunwind-exceptions --enable-libgcj-multifile
> --enable-languages=c,c++,objc,obj-c++,java,fortran,ada
> --enable-java-awt=gtk --disable-dssi --enable-plugin
> --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre
> --with-cpu=generic --host=i386-redhat-linux
> Thread model: posix
> gcc version 4.1.2 20080704 (Red Hat 4.1.2-48)
>
> $ cython -V
> Cython version 0.13pre

$ python -V
Python 2.6.4

O.

Kurt Smith

unread,
Aug 9, 2010, 6:07:54 PM8/9/10
to fwrap...@googlegroups.com
On Mon, Aug 9, 2010 at 4:56 PM, Ondrej Certik <ond...@certik.cz> wrote:
> Hi,
>
> I have now tried to run tests and I got:
>
> $ python runtests.py -vv --fcompiler=gnu95 --no-cleanup
> Python 2.6.4 (r264:75706, Jun 12 2010, 15:15:24)
> [GCC 4.1.2 20080704 (Red Hat 4.1.2-48)]
>
[...]

> [...]
>
> and lots of errors like this.
>
>
> $ gfortran -v
> Using built-in specs.
> Target: i386-redhat-linux
> Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
> --infodir=/usr/share/info --enable-shared --enable-threads=posix
> --enable-checking=release --with-system-zlib --enable-__cxa_atexit
> --disable-libunwind-exceptions --enable-libgcj-multifile
> --enable-languages=c,c++,objc,obj-c++,java,fortran,ada
> --enable-java-awt=gtk --disable-dssi --enable-plugin
> --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre
> --with-cpu=generic --host=i386-redhat-linux
> Thread model: posix
> gcc version 4.1.2 20080704 (Red Hat 4.1.2-48)
>
> $ cython -V
> Cython version 0.13pre

Unfortunately you need gfortran >= 4.4.1 for fwrap. (4.3.2 and
greater will work with some bugs in the corner cases).

See the README for fortran compilers that are known to work (g95 >=
0.92 works, as does ifort >= 11.1).

>
>
> Ondrej

Ondrej Certik

unread,
Aug 9, 2010, 6:16:38 PM8/9/10
to fwrap...@googlegroups.com

That's right, I noticed that. Hm. I am in the LLNL lab and this is the
fortran that I have (I don't have a root access to my computer). I
also installed femhub and there the fortran is:

$ sage_fortran -v
Using built-in specs.
Target:
Configured with: ../configure --enable-languages=c
Thread model: posix
gcc version 4.0.3 (g95 0.91!) Jul 17 2007


So I think that I am out of luck. Can you give me some hints why this
exception is happening? Is it really because of my old compiler? What
kind of new features are you using from gcc 4.4.1?

Ondrej

Ondrej Certik

unread,
Aug 9, 2010, 6:28:08 PM8/9/10
to fwrap...@googlegroups.com

Ok, I have logged onto my server with the following configuration:

$ gfortran -v
Using built-in specs.

Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu
4.4.3-4ubuntu5'
--with-bugurl=file:///usr/share/doc/gcc-4.4/README.Bugs
--enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr
--enable-shared --enable-multiarch --enable-linker-build-id
--with-system-zlib --libexecdir=/usr/lib --without-included-gettext
--enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.4
--program-suffix=-4.4 --enable-nls --enable-clocale=gnu
--enable-libstdcxx-debug --enable-plugin --enable-objc-gc
--disable-werror --with-arch-32=i486 --with-tune=generic
--enable-checking=release --build=x86_64-linux-gnu
--host=x86_64-linux-gnu --target=x86_64-linux-gnu
Thread model: posix
gcc version 4.4.3 (Ubuntu 4.4.3-4ubuntu5)


$ cython -V
Cython version 0.12.1


$ python -V
Python 2.6.5


and I got the following errors (I am using the latest hg fwrap-dev):

Python 2.6.5 (r265:79063, Apr 16 2010, 13:57:41)
[GCC 4.4.3]

wrapping all_char.f90 ... ERROR
wrapping char_args.f90 ... ERROR

wrapping cmplx_array.f90 ... ok
wrapping default_types.f90 ... ok
wrapping int_args.f90 ... ok
wrapping many_args.f90 ... ok
wrapping old_decl.f90 ... ok
wrapping py_kw_arg.f90 ... ok


wrapping simple_array.f90 ... ERROR
compiling and running all_char.f90 ... ERROR
compiling and running all_char_arrays.f90 ... ERROR
compiling and running all_complex.f90 ... ERROR
compiling and running all_complex_arrays.f90 ... ERROR
compiling and running all_integer_arrays.f90 ... ERROR

compiling and running all_ints.f90 ... Doctest: all_ints_fwrap_doctest ... ok


compiling and running all_logical_arrays.f90 ... ERROR

compiling and running all_logicals.f90 ... Doctest:
all_logicals_fwrap_doctest ... ok


compiling and running all_real_arrays.f90 ... ERROR

compiling and running all_reals.f90 ... Doctest: all_reals_fwrap_doctest ... ok
compiling and running array_intents.f90 ... Doctest:
array_intents_fwrap_doctest ... ok
compiling and running array_types.f90 ... Doctest:
array_types_fwrap_doctest ... ok


compiling and running char_array.f90 ... ERROR

compiling and running default_types.f90 ... Doctest:
default_types_fwrap_doctest ... ok


compiling and running dim_expr.f90 ... ERROR
compiling and running func_returns.f90 ... ERROR

compiling and running int_args.f90 ... Doctest: int_args_fwrap_doctest ... ok
compiling and running ndims.f90 ... Doctest: ndims_fwrap_doctest.test_D1 ... ok
Doctest: ndims_fwrap_doctest.test_D2 ... ok
Doctest: ndims_fwrap_doctest.test_D3 ... ok
compiling and running old_decl.f90 ... Doctest: old_decl_fwrap_doctest ... ok

======================================================================
ERROR: wrapping all_char.f90
----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/compile/all_char_fwrap/all_char_fwrap.so:
undefined symbol: _gfortran_concat_string

======================================================================
ERROR: wrapping char_args.f90
----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/compile/char_args_fwrap/char_args_fwrap.so:
undefined symbol: _gfortran_os_error

======================================================================
ERROR: wrapping simple_array.f90


----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/compile/simple_array_fwrap/simple_array_fwrap.so:
undefined symbol: _gfortran_st_write_done

======================================================================


ERROR: compiling and running all_char.f90

----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 241, in run
self.runTest()
File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/run/all_char_fwrap/all_char_fwrap.so:
undefined symbol: _gfortran_concat_string

======================================================================


ERROR: compiling and running all_char_arrays.f90

----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 241, in run
self.runTest()
File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/run/all_char_arrays_fwrap/all_char_arrays_fwrap.so:
undefined symbol: _gfortran_concat_string

======================================================================


ERROR: compiling and running all_complex.f90

----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 241, in run
self.runTest()
File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/run/all_complex_fwrap/all_complex_fwrap.so:
undefined symbol: _gfortran_pow_c8_i4

======================================================================


ERROR: compiling and running all_complex_arrays.f90

----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 241, in run
self.runTest()
File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/run/all_complex_arrays_fwrap/all_complex_arrays_fwrap.so:
undefined symbol: _gfortran_os_error

======================================================================


ERROR: compiling and running all_integer_arrays.f90

----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 241, in run
self.runTest()
File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/run/all_integer_arrays_fwrap/all_integer_arrays_fwrap.so:
undefined symbol: _gfortran_os_error

======================================================================


ERROR: compiling and running all_logical_arrays.f90

----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 241, in run
self.runTest()
File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/run/all_logical_arrays_fwrap/all_logical_arrays_fwrap.so:
undefined symbol: _gfortran_os_error

======================================================================


ERROR: compiling and running all_real_arrays.f90

----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 241, in run
self.runTest()
File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/run/all_real_arrays_fwrap/all_real_arrays_fwrap.so:
undefined symbol: _gfortran_os_error

======================================================================


ERROR: compiling and running char_array.f90

----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 241, in run
self.runTest()
File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/run/char_array_fwrap/char_array_fwrap.so:
undefined symbol: __iso_c_binding_c_f_pointer_s0

======================================================================


ERROR: compiling and running dim_expr.f90

----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 241, in run
self.runTest()
File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/run/dim_expr_fwrap/dim_expr_fwrap.so:
undefined symbol: _gfortran_os_error

======================================================================


ERROR: compiling and running func_returns.f90

----------------------------------------------------------------------
Traceback (most recent call last):

File "runtests.py", line 241, in run
self.runTest()
File "runtests.py", line 208, in runTest
self.runCompileTest_distutils()
File "runtests.py", line 217, in runCompileTest_distutils
__import__(self.projname)
ImportError: /home/ondrej/repos/fwrap-dev/BUILD/run/func_returns_fwrap/func_returns_fwrap.so:
undefined symbol: _gfortran_os_error

----------------------------------------------------------------------
Ran 39 tests in 55.202s

FAILED (errors=13)


So this is an improvement, some tests pass.

What about the rest?


Ondrej

Kurt Smith

unread,
Aug 9, 2010, 6:28:17 PM8/9/10
to fwrap...@googlegroups.com

Since most versions of *gcc* are ABI compatible the gcc version isn't
that important; gcc 4.0.3 might work fine. It's the *gfortran*
version that matters.

Is the sage_fortran *g95*, or *gfortran*? I can't tell. If it's g95
you should try it, it might work.

The reason fwrap requires gfortran >= 4.4.1 is because that's the
earliest gfortran that supports the basic set of C binding features
fwrap requires (gfortran 4.3 has most of it, but one key function is
buggy).

Believe me, I really want to improve this situation and support
gfortran back to 4.2 or 4.1. Unfortunately I only have time right now
to work on features key for my own work; you probably know how it
goes.

Kurt

>
> Ondrej

Ondrej Certik

unread,
Aug 9, 2010, 6:29:35 PM8/9/10
to fwrap...@googlegroups.com

Absolutely, let's get it working with the latest gfortran first and
then people can help with porting it backwards.

If I commit the generated Cython + header files, will it work with any fortran?

Ondrej

Kurt Smith

unread,
Aug 9, 2010, 6:34:37 PM8/9/10
to fwrap...@googlegroups.com

Did you set the F90 and LDFLAGS environment vars? See the README.

You can do

$ fwrapc.py --help-fcompiler --fcompiler=gnu95

to troubleshoot the fortran compiler stuff.

>
>
> Ondrej
>
> --
> You received this message because you are subscribed to the Google Groups "Fwrap Users" group.
> To post to this group, send email to fwrap...@googlegroups.com.
> To unsubscribe from this group, send email to fwrap-users...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/fwrap-users?hl=en.
>
>

Ondrej Certik

unread,
Aug 9, 2010, 6:42:00 PM8/9/10
to fwrap...@googlegroups.com
[...]

>> What about the rest?
>
> Did you set the F90 and LDFLAGS environment vars?  See the README.
>
> You can do
>
> $ fwrapc.py --help-fcompiler --fcompiler=gnu95
>
> to troubleshoot the fortran compiler stuff.

You are right! So here is how to make it work:

$ export F90=/usr/bin/gfortran
$ export LDFLAGS=-lgfortran


$ python runtests.py -vv --fcompiler=gnu95 --no-cleanup

[...]
Ran 52 tests in 55.118s

OK

So that's excellent. Thanks Kurt for helping me so quickly!

Ondrej

Reply all
Reply to author
Forward
0 new messages