Compile on windows

565 views
Skip to first unread message

halve...@gmail.com

unread,
Mar 24, 2009, 3:39:54 AM3/24/09
to TANGO Project - ALGENCAN
I have downloaded the algencan file along with mingw and am attempting
to compile on windows. I installed the mingw fortran compiler and have
changed the "FC" line in Makefile to "FC=g77" I have also changed
"PYTHONINC := c:/python25
PYTHONLIB := c:/python25/lib"

However when I run make I get

C:/Program Files/pythonxy/mingw/bin/make -C C:/Algencan/sources/
algencan
-e was unexpected at this time.
-e was unexpected at this time.
-e was unexpected at this time.
-e was unexpected at this time.
make[1]: Entering directory `C:/Algencan/sources/algencan'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `C:/Algencan/sources/algencan'
C:/Program Files/pythonxy/mingw/bin/make -C C:/Algencan/sources/
problems all install
make[1]: Entering directory `C:/Algencan/sources/problems'
gcc -O4 -shared -o .o
gcc: no input files
make[1]: *** [.o] Error 1
make[1]: Leaving directory `C:/Algencan/sources/problems'
make: *** [algencan] Error 2
PS C:\Algencan>

egbi...@gmail.com

unread,
Mar 24, 2009, 6:26:44 AM3/24/09
to TANGO Project - ALGENCAN
To compile the Python interface you must type:

make algencan-py

(see the README file for details).

The output you showed corresponds to compile the standalone Fortran
version of ALGENCAN, that must be compiled typing "make
PROBNAME=toyprob", where toyprob is the Fortran code of the problem
you are trying to solve. As you type just make, that is why the
compiler is claiming that there is no "problem source code" to be
compiled.

Ernesto.

On Mar 24, 4:39 am, "halverso...@gmail.com" <halverso...@gmail.com>
wrote:

halve...@gmail.com

unread,
Mar 25, 2009, 9:39:13 AM3/25/09
to TANGO Project - ALGENCAN
Sorry, I had run make algencan-py but make seemed more manageable to
post "make algencan-py: gives me

PS C:\Algencan> make algencan-py
C:/Program Files/pythonxy/mingw/bin/make -C C:/Algencan/sources/
algencan
-e was unexpected at this time.
-e was unexpected at this time.
-e was unexpected at this time.
-e was unexpected at this time.
make[1]: Entering directory `C:/Algencan/sources/algencan'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `C:/Algencan/sources/algencan'
C:/Program Files/pythonxy/mingw/bin/make -C C:/Algencan/sources/
interfaces/py all install
make[1]: Entering directory `C:/Algencan/sources/interfaces/py'
gcc -O4 -Df2cFortran -fPIC -Ic:\python25 \
-Ic:\python25\lib/site-packages/numpy/core/
include \
-c pywrapper.c
pywrapper.c:1: warning: -fPIC ignored for target (all code is position
independent)
pywrapper.c:57:20: Python.h: No such file or directory
In file included from c:/python25/lib/site-packages/numpy/core/include/
numpy/arrayobject.h:14,
from pywrapper.c:58:
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
114:2: #error Must use Python with uni
d.
In file included from c:/python25/lib/site-packages/numpy/core/include/
numpy/arrayobject.h:14,
from pywrapper.c:58:
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
934: error: syntax error before "npy_i
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
934: warning: data definition has no t
age class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
935: error: syntax error before "npy_u
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
935: warning: data definition has no t
age class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1037: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1037: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1038: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1040: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1051: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1053: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1056: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1061: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1066: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1068: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1069: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1071: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1075: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1077: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1079: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1085: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1085: warning: no semicolon at end of
nion
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1087: error: syntax error before '}' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1087: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1098: error: syntax error before "PyAr
Func"
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1098: warning: no semicolon at end of
nion
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1150: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1150: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1162: error: syntax error before '}' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1162: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1199: error: syntax error before "PyOb
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1199: warning: no semicolon at end of
nion
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1218: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1218: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1222: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1222: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1225: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1225: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1227: error: syntax error before '}' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1227: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1230: error: syntax error before "PyAr
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1230: warning: no semicolon at end of
nion
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1231: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1232: error: syntax error before '}' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1232: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1241: error: syntax error before "PyOb
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1241: warning: no semicolon at end of
nion
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1244: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1244: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1245: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1245: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1247: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1247: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1255: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1255: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1257: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1257: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1258: error: syntax error before '}' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1258: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1266: error: syntax error before "PyOb
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1266: warning: no semicolon at end of
nion
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1269: error: syntax error before '}' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1269: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1274: error: syntax error before "PyOb
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1274: warning: no semicolon at end of
nion
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1277: error: syntax error before "len"
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1277: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1279: error: syntax error before '}' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1279: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1281: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1423: error: syntax error before "PyOb
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1423: warning: no semicolon at end of
nion
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1425: warning: built-in function 'inde
as non-function
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1425: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1426: error: syntax error before "coor
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1426: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1427: error: syntax error before "dims
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1427: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1428: error: syntax error before "stri
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1428: error: conflicting types for 'st
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1245: error: previous declaration of '
s here
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1428: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1429: error: syntax error before "back
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1429: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1430: error: syntax error before "fact
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1430: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1431: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1431: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1434: error: syntax error before '}' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1434: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1570: error: syntax error before "PyOb
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1570: warning: no semicolon at end of
nion
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1572: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1573: error: syntax error before "inde
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1573: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1575: error: syntax error before "dime
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1575: error: conflicting types for 'di
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1244: error: previous declaration of '
was here
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1575: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1576: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1576: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1577: error: syntax error before '}' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1577: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1624: error: syntax error before "PyOb
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1624: warning: no semicolon at end of
nion
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1630: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1632: error: syntax error before "inde
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1632: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1634: error: syntax error before "dime
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1634: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1635: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1635: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1637: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1637: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1641: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1641: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1650: error: syntax error before "bsco
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1650: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1652: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1652: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1656: error: syntax error before '}' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1656: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1837: error: syntax error before "npy_
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1837: warning: no semicolon at end of
nion
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1838: error: conflicting types for 'st
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1428: error: previous declaration of '
s here
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1838: error: conflicting types for 'st
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1428: error: previous declaration of '
s here
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1838: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1840: error: syntax error before '*' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1840: warning: data definition has no
rage class
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1842: error: syntax error before '}' t
c:/python25/lib/site-packages/numpy/core/include/numpy/ndarrayobject.h:
1842: warning: data definition has no
rage class
In file included from c:/python25/lib/site-packages/numpy/core/include/
numpy/ndarrayobject.h:1852,
from c:/python25/lib/site-packages/numpy/core/include/
numpy/arrayobject.h:14,
from pywrapper.c:58:
c:/python25/lib/site-packages/numpy/core/include/numpy/
__multiarray_api.h:403: error: `NULL' undeclared here
unction)
c:/python25/lib/site-packages/numpy/core/include/numpy/
__multiarray_api.h: In function `_import_array':
c:/python25/lib/site-packages/numpy/core/include/numpy/
__multiarray_api.h:960: error: `PyObject' undeclared (
n this function)
c:/python25/lib/site-packages/numpy/core/include/numpy/
__multiarray_api.h:960: error: (Each undeclared identi
orted only once
c:/python25/lib/site-packages/numpy/core/include/numpy/
__multiarray_api.h:960: error: for each function it ap
c:/python25/lib/site-packages/numpy/core/include/numpy/
__multiarray_api.h:960: error: `numpy' undeclared (fir
his function)
c:/python25/lib/site-packages/numpy/core/include/numpy/
__multiarray_api.h:961: error: `c_api' undeclared (fir
his function)
c:/python25/lib/site-packages/numpy/core/include/numpy/
__multiarray_api.h:973: error: `PyExc_RuntimeError' un
irst use in this function)
In file included from pywrapper.c:60:
pywrapper.h: At top level:
pywrapper.h:1: error: syntax error before '*' token
pywrapper.h:1: warning: data definition has no type or storage class
pywrapper.h:2: error: syntax error before '*' token
pywrapper.h:2: warning: data definition has no type or storage class
pywrapper.h:3: error: syntax error before '*' token
pywrapper.h:3: warning: data definition has no type or storage class
pywrapper.h:4: error: syntax error before '*' token
pywrapper.h:4: warning: data definition has no type or storage class
pywrapper.h:5: error: syntax error before '*' token
pywrapper.h:5: warning: data definition has no type or storage class
pywrapper.h:6: error: syntax error before '*' token
pywrapper.h:6: warning: data definition has no type or storage class
pywrapper.h:7: error: syntax error before '*' token
pywrapper.h:7: warning: data definition has no type or storage class
pywrapper.h:8: error: syntax error before '*' token
pywrapper.h:8: warning: data definition has no type or storage class
pywrapper.h:9: error: syntax error before '*' token
pywrapper.h:9: warning: data definition has no type or storage class
pywrapper.h:10: error: syntax error before '*' token
pywrapper.h:10: warning: data definition has no type or storage class
pywrapper.h:11: error: syntax error before '*' token
pywrapper.h:11: warning: data definition has no type or storage class
pywrapper.h:12: error: syntax error before '*' token
pywrapper.h:12: warning: data definition has no type or storage class
pywrapper.h:13: error: syntax error before '*' token
pywrapper.h:13: warning: data definition has no type or storage class
pywrapper.h:15: error: syntax error before '*' token
pywrapper.h:15: warning: data definition has no type or storage class
pywrapper.h:17: error: syntax error before '*' token
pywrapper.h:17: error: syntax error before '*' token
pywrapper.h:17: warning: data definition has no type or storage class
pywrapper.h:54: error: syntax error before "PyObject"
pywrapper.h:56: error: syntax error before "PyObject"
pywrapper.h:58: error: syntax error before "PyObject"
pywrapper.h:60: error: syntax error before "PyObject"
pywrapper.c:62: error: syntax error before "pywrapper_methods"
pywrapper.c:63: warning: braces around scalar initializer
pywrapper.c:63: warning: (near initialization for `pywrapper_methods
[0]')
pywrapper.c:63: warning: initialization makes integer from pointer
without a cast
pywrapper.c:63: warning: excess elements in scalar initializer
pywrapper.c:63: warning: (near initialization for `pywrapper_methods
[0]')
pywrapper.c:63: error: `METH_VARARGS' undeclared here (not in a
function)
pywrapper.c:63: warning: excess elements in scalar initializer
pywrapper.c:63: warning: (near initialization for `pywrapper_methods
[0]')
pywrapper.c:63: warning: excess elements in scalar initializer
pywrapper.c:63: warning: (near initialization for `pywrapper_methods
[0]')
pywrapper.c:64: warning: braces around scalar initializer
pywrapper.c:64: warning: (near initialization for `pywrapper_methods
[1]')
pywrapper.c:64: warning: initialization makes integer from pointer
without a cast
pywrapper.c:64: warning: excess elements in scalar initializer
pywrapper.c:64: warning: (near initialization for `pywrapper_methods
[1]')
pywrapper.c:64: warning: excess elements in scalar initializer
pywrapper.c:64: warning: (near initialization for `pywrapper_methods
[1]')
pywrapper.c:64: warning: excess elements in scalar initializer
pywrapper.c:64: warning: (near initialization for `pywrapper_methods
[1]')
pywrapper.c:65: warning: data definition has no type or storage class
pywrapper.c:70: error: syntax error before "initpywrapper"
pywrapper.c: In function `initpywrapper':
pywrapper.c:73: error: `PyExc_ImportError' undeclared (first use in
this function)
pywrapper.c: At top level:
pywrapper.c:80: error: syntax error before '*' token
pywrapper.c:80: error: syntax error before '*' token
pywrapper.c: In function `pywrapper_solver':
pywrapper.c:89: error: `Py_None' undeclared (first use in this
function)
pywrapper.c:92: error: `args' undeclared (first use in this function)
pywrapper.c:93: error: `PyFunction_Type' undeclared (first use in this
function)
pywrapper.c:105: error: `PyDict_Type' undeclared (first use in this
function)
pywrapper.c: In function `inip':
pywrapper.c:167: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:167: error: `result' undeclared (first use in this
function)
pywrapper.c:167: error: `x_py' undeclared (first use in this function)
pywrapper.c:167: error: `l_py' undeclared (first use in this function)
pywrapper.c:167: error: `u_py' undeclared (first use in this function)
pywrapper.c:167: error: `lambda_py' undeclared (first use in this
function)
pywrapper.c:167: error: `equatn_py' undeclared (first use in this
function)
pywrapper.c:167: error: `linear_py' undeclared (first use in this
function)
pywrapper.c:168: error: `coded_py' undeclared (first use in this
function)
pywrapper.c: In function `evalf':
pywrapper.c:220: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:220: error: `result' undeclared (first use in this
function)
pywrapper.c:220: error: `x_py' undeclared (first use in this function)
pywrapper.c: In function `evalg':
pywrapper.c:256: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:256: error: `result' undeclared (first use in this
function)
pywrapper.c:256: error: `x_py' undeclared (first use in this function)
pywrapper.c:256: error: `g_py' undeclared (first use in this function)
pywrapper.c: In function `evalh':
pywrapper.c:301: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:301: error: `result' undeclared (first use in this
function)
pywrapper.c:301: error: `x_py' undeclared (first use in this function)
pywrapper.c:301: error: `hlin_py' undeclared (first use in this
function)
pywrapper.c:301: error: `hcol_py' undeclared (first use in this
function)
pywrapper.c:301: error: `hval_py' undeclared (first use in this
function)
pywrapper.c: In function `evalc':
pywrapper.c:352: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:352: error: `result' undeclared (first use in this
function)
pywrapper.c:352: error: `x_py' undeclared (first use in this function)
pywrapper.c: In function `evaljac':
pywrapper.c:390: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:390: error: `result' undeclared (first use in this
function)
pywrapper.c:390: error: `x_py' undeclared (first use in this function)
pywrapper.c:390: error: `jcvar_py' undeclared (first use in this
function)
pywrapper.c:390: error: `jcval_py' undeclared (first use in this
function)
pywrapper.c: In function `evalhc':
pywrapper.c:440: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:440: error: `result' undeclared (first use in this
function)
pywrapper.c:440: error: `x_py' undeclared (first use in this function)
pywrapper.c:440: error: `hclin_py' undeclared (first use in this
function)
pywrapper.c:440: error: `hccol_py' undeclared (first use in this
function)
pywrapper.c:440: error: `hcval_py' undeclared (first use in this
function)
pywrapper.c: In function `evalfc':
pywrapper.c:491: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:491: error: `result' undeclared (first use in this
function)
pywrapper.c:491: error: `x_py' undeclared (first use in this function)
pywrapper.c:491: error: `c_py' undeclared (first use in this function)
pywrapper.c: In function `evalgjac':
pywrapper.c:536: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:536: error: `result' undeclared (first use in this
function)
pywrapper.c:536: error: `x_py' undeclared (first use in this function)
pywrapper.c:536: error: `g_py' undeclared (first use in this function)
pywrapper.c:536: error: `jcfun_py' undeclared (first use in this
function)
pywrapper.c:536: error: `jcvar_py' undeclared (first use in this
function)
pywrapper.c:536: error: `jcval_py' undeclared (first use in this
function)
pywrapper.c: In function `evalhl':
pywrapper.c:589: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:589: error: `result' undeclared (first use in this
function)
pywrapper.c:589: error: `x_py' undeclared (first use in this function)
pywrapper.c:589: error: `lambda_py' undeclared (first use in this
function)
pywrapper.c:589: error: `scalec_py' undeclared (first use in this
function)
pywrapper.c:590: error: `hllin_py' undeclared (first use in this
function)
pywrapper.c:590: error: `hlcol_py' undeclared (first use in this
function)
pywrapper.c:590: error: `hlval_py' undeclared (first use in this
function)
pywrapper.c: In function `evalhlp':
pywrapper.c:647: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:647: error: `result' undeclared (first use in this
function)
pywrapper.c:647: error: `x_py' undeclared (first use in this function)
pywrapper.c:647: error: `lambda_py' undeclared (first use in this
function)
pywrapper.c:647: error: `scalec_py' undeclared (first use in this
function)
pywrapper.c:648: error: `p_py' undeclared (first use in this function)
pywrapper.c:648: error: `hp_py' undeclared (first use in this
function)
pywrapper.c: In function `endp':
pywrapper.c:699: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:699: error: `result' undeclared (first use in this
function)
pywrapper.c:699: error: `x_py' undeclared (first use in this function)
pywrapper.c:699: error: `l_py' undeclared (first use in this function)
pywrapper.c:699: error: `u_py' undeclared (first use in this function)
pywrapper.c:700: error: `lambda_py' undeclared (first use in this
function)
pywrapper.c:700: error: `equatn_py' undeclared (first use in this
function)
pywrapper.c:700: error: `linear_py' undeclared (first use in this
function)
pywrapper.c: In function `param':
pywrapper.c:746: error: `PyExc_TypeError' undeclared (first use in
this function)
pywrapper.c:752: warning: comparison between pointer and integer
pywrapper.c:753: error: `PyExc_ValueError' undeclared (first use in
this function)
pywrapper.c:759: warning: comparison between pointer and integer
pywrapper.c:766: warning: comparison between pointer and integer
pywrapper.c:773: warning: comparison between pointer and integer
pywrapper.c: At top level:
pywrapper.c:784: error: syntax error before "PyObject"
pywrapper.c: In function `BuildIntArray':
pywrapper.c:787: error: `array_py' undeclared (first use in this
function)
pywrapper.c:789: error: `input' undeclared (first use in this
function)
pywrapper.c:791: error: syntax error before ')' token
pywrapper.c:792: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:792: error: syntax error before ')' token
pywrapper.c:792: error: syntax error before ',' token
pywrapper.c:792: error: syntax error before ')' token
pywrapper.c:795: error: syntax error before ')' token
pywrapper.c:796: error: `PyExc_ValueError' undeclared (first use in
this function)
pywrapper.c:801: error: `array' undeclared (first use in this
function)
pywrapper.c:801: error: syntax error before ')' token
pywrapper.c: At top level:
pywrapper.c:816: error: syntax error before "PyObject"
pywrapper.c: In function `BuildRealArray':
pywrapper.c:819: error: `array_py' undeclared (first use in this
function)
pywrapper.c:821: error: `input' undeclared (first use in this
function)
pywrapper.c:823: error: syntax error before ')' token
pywrapper.c:824: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:824: error: syntax error before ')' token
pywrapper.c:824: error: syntax error before ',' token
pywrapper.c:824: error: syntax error before ')' token
pywrapper.c:827: error: syntax error before ')' token
pywrapper.c:828: error: `PyExc_ValueError' undeclared (first use in
this function)
pywrapper.c:833: error: `array' undeclared (first use in this
function)
pywrapper.c:833: error: syntax error before ')' token
pywrapper.c: At top level:
pywrapper.c:848: error: syntax error before "PyObject"
pywrapper.c: In function `BuildIntPyArray':
pywrapper.c:850: error: syntax error before "dimensions"
pywrapper.c:855: error: `array' undeclared (first use in this
function)
pywrapper.c:855: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:855: error: syntax error before ')' token
pywrapper.c:855: error: `PyTypeObject' undeclared (first use in this
function)
pywrapper.c:855: error: syntax error before ',' token
pywrapper.c: At top level:
pywrapper.c:866: error: syntax error before "PyObject"
pywrapper.c: In function `BuildRealPyArray':
pywrapper.c:868: error: syntax error before "dimensions"
pywrapper.c:873: error: `array' undeclared (first use in this
function)
pywrapper.c:873: error: `PyObject' undeclared (first use in this
function)
pywrapper.c:873: error: syntax error before ')' token
pywrapper.c:873: error: `PyTypeObject' undeclared (first use in this
function)
pywrapper.c:873: error: syntax error before ',' token
make[1]: *** [pywrapper.o] Error 1
make[1]: Leaving directory `C:/Algencan/sources/interfaces/py'
make: *** [algencan-py] Error 2

Jan Marcel Gentil

unread,
Mar 25, 2009, 10:11:53 AM3/25/09
to TANGO Project - ALGENCAN
The line

pywrapper.c:57:20: Python.h: No such file or directory

in the error log included in your last post lead us to believe that
the PYTHONINC variable in incorrectly defined in the main Makefile.
Please check if file c:/python25/Python.h does exist on your machine
and if not, change PYTHONINC accordingly in ALGENCAN Makefile so that
the directory PYTHONINC contains the standard Python include files
(namely, Python.h).

If any queries may arise, please do not hesitate to contact us.


--
Jan Marcel

On Mar 25, 10:39 am, "halverso...@gmail.com" <halverso...@gmail.com>
wrote:
> 1426: ...
>
> read more »

halve...@gmail.com

unread,
Mar 26, 2009, 3:22:01 PM3/26/09
to TANGO Project - ALGENCAN
So I changed my Pyhtoninc directory to c:\python25\include
and I rerun make algencan-py and I get

make: *** [clean] Error 2
PS C:\Algencan> make algencan-py
C:/Program Files/pythonxy/mingw/bin/make -C C:/Algencan/sources/
algencan
-e was unexpected at this time.
-e was unexpected at this time.
-e was unexpected at this time.
-e was unexpected at this time.
make[1]: Entering directory `C:/Algencan/sources/algencan'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `C:/Algencan/sources/algencan'
C:/Program Files/pythonxy/mingw/bin/make -C C:/Algencan/sources/
interfaces/py all install
make[1]: Entering directory `C:/Algencan/sources/interfaces/py'
g77 -O4 -shared pywrapper.o C:/Algencan/sources/algencan/algencan.o C:/
Algencan/sources/algencan/auglag.o C:/Algencan/so
urces/algencan/backtrack.o C:/Algencan/sources/algencan/betra.o C:/
Algencan/sources/algencan/calc.o C:/Algencan/sources/
algencan/cgm.o C:/Algencan/sources/algencan/checkder.o C:/Algencan/
sources/algencan/dogleg.o C:/Algencan/sources/algenca
n/drand.o C:/Algencan/sources/algencan/extrap.o C:/Algencan/sources/
algencan/evalal.o C:/Algencan/sources/algencan/fpara
m.o C:/Algencan/sources/algencan/gencan.o C:/Algencan/sources/algencan/
happrox.o C:/Algencan/sources/algencan/lss.o C:/A
lgencan/sources/algencan/moresor.o C:/Algencan/sources/algencan/
newtd.o C:/Algencan/sources/algencan/newtonkkt.o C:/Alge
ncan/sources/algencan/scl.o C:/Algencan/sources/algencan/setpoint.o C:/
Algencan/sources/algencan/sevalus.o C:/Algencan/s
ources/algencan/spgls.o C:/Algencan/sources/algencan/tevalus.o C:/
Algencan/sources/algencan/tnls.o C:/Algencan/sources/a
lgencan/uevalus.o C:/Algencan/sources/algencan/vevalus.o -o
pywrapper.so
pywrapper.o:pywrapper.c:(.text+0x2f): undefined reference to
`_imp__Py_InitModule4'
pywrapper.o:pywrapper.c:(.text+0x3c): undefined reference to
`_imp__PyImport_ImportModule'
pywrapper.o:pywrapper.c:(.text+0x54): undefined reference to
`_imp__PyObject_GetAttrString'
pywrapper.o:pywrapper.c:(.text+0x64): undefined reference to
`_imp__PyCObject_Type'
pywrapper.o:pywrapper.c:(.text+0x92): undefined reference to
`_imp__PyErr_Print'
pywrapper.o:pywrapper.c:(.text+0x97): undefined reference to
`_imp__PyExc_ImportError'
pywrapper.o:pywrapper.c:(.text+0xab): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0xbb): undefined reference to
`_imp__PyCObject_AsVoidPtr'
pywrapper.o:pywrapper.c:(.text+0xee): undefined reference to
`_imp__PyExc_RuntimeError'
pywrapper.o:pywrapper.c:(.text+0xf9): undefined reference to
`_imp__PyErr_Format'
pywrapper.o:pywrapper.c:(.text+0x217): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x22b): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x31a): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x32e): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x362): undefined reference to
`_imp__PyEval_CallFunction'
pywrapper.o:pywrapper.c:(.text+0x3c4): undefined reference to
`_imp__PyArg_ParseTuple'
pywrapper.o:pywrapper.c:(.text+0xa92): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0xaa6): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0xabf): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0xad3): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0xafa): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0xb0e): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0xb35): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0xb49): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0xb70): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0xb84): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0xbb9): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0xbcd): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0xbd7): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0xbeb): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0xedf): undefined reference to
`_imp__PyEval_CallFunction'
pywrapper.o:pywrapper.c:(.text+0xf10): undefined reference to
`_imp__PyArg_ParseTuple'
pywrapper.o:pywrapper.c:(.text+0x10c6): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x10da): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x1347): undefined reference to
`_imp__PyEval_CallFunction'
pywrapper.o:pywrapper.c:(.text+0x138a): undefined reference to
`_imp__PyArg_ParseTuple'
pywrapper.o:pywrapper.c:(.text+0x16d3): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x16e7): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x1700): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x1714): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x172d): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x1741): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x18a6): undefined reference to
`_imp__PyEval_CallFunction'
pywrapper.o:pywrapper.c:(.text+0x18f0): undefined reference to
`_imp__PyArg_ParseTuple'
pywrapper.o:pywrapper.c:(.text+0x1ced): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x1d01): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x1d1a): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x1d2e): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x1d55): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x1d69): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x1d82): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x1d96): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x1eaf): undefined reference to
`_imp__PyEval_CallFunction'
pywrapper.o:pywrapper.c:(.text+0x1ee4): undefined reference to
`_imp__PyArg_ParseTuple'
pywrapper.o:pywrapper.c:(.text+0x2059): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x206d): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x2195): undefined reference to
`_imp__PyEval_CallFunction'
pywrapper.o:pywrapper.c:(.text+0x21d8): undefined reference to
`_imp__PyArg_ParseTuple'
pywrapper.o:pywrapper.c:(.text+0x252e): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x2542): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x255b): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x256f): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x2588): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x259c): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x26c6): undefined reference to
`_imp__PyEval_CallFunction'
pywrapper.o:pywrapper.c:(.text+0x2702): undefined reference to
`_imp__PyArg_ParseTuple'
pywrapper.o:pywrapper.c:(.text+0x298c): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x29a0): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x29ab): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x29bf): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x2ad1): undefined reference to
`_imp__PyEval_CallFunction'
pywrapper.o:pywrapper.c:(.text+0x2af4): undefined reference to
`_imp__PyArg_ParseTuple'
pywrapper.o:pywrapper.c:(.text+0x2c7e): undefined reference to
`_imp__PyEval_CallFunction'
pywrapper.o:pywrapper.c:(.text+0x2cc1): undefined reference to
`_imp__PyArg_ParseTuple'
pywrapper.o:pywrapper.c:(.text+0x3018): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x302c): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x3045): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x3059): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x3072): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x3086): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x3198): undefined reference to
`_imp__PyEval_CallFunction'
pywrapper.o:pywrapper.c:(.text+0x31c6): undefined reference to
`_imp__PyArg_ParseTuple'
pywrapper.o:pywrapper.c:(.text+0x3353): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x3367): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x3469): undefined reference to
`_imp__PyEval_CallFunction'
pywrapper.o:pywrapper.c:(.text+0x348c): undefined reference to
`_imp__PyArg_ParseTuple'
pywrapper.o:pywrapper.c:(.text+0x393c): undefined reference to
`_imp__PyEval_CallFunction'
pywrapper.o:pywrapper.c:(.text+0x39dd): undefined reference to
`_imp__PyDict_Type'
pywrapper.o:pywrapper.c:(.text+0x39f2): undefined reference to
`_imp__PyType_IsSubtype'
pywrapper.o:pywrapper.c:(.text+0x3a0d): undefined reference to
`_imp__PyDict_GetItemString'
pywrapper.o:pywrapper.c:(.text+0x3a16): undefined reference to
`_imp__PyFloat_AsDouble'
pywrapper.o:pywrapper.c:(.text+0x3a21): undefined reference to
`_imp__PyErr_Occurred'
pywrapper.o:pywrapper.c:(.text+0x3a33): undefined reference to
`_imp__PyExc_ValueError'
pywrapper.o:pywrapper.c:(.text+0x3a3e): undefined reference to
`_imp__PyErr_SetString'
pywrapper.o:pywrapper.c:(.text+0x3a51): undefined reference to
`_imp__PyExc_TypeError'
pywrapper.o:pywrapper.c:(.text+0x3a74): undefined reference to
`_imp__PyDict_GetItemString'
pywrapper.o:pywrapper.c:(.text+0x3a7d): undefined reference to
`_imp__PyFloat_AsDouble'
pywrapper.o:pywrapper.c:(.text+0x3a88): undefined reference to
`_imp__PyErr_Occurred'
pywrapper.o:pywrapper.c:(.text+0x3aa4): undefined reference to
`_imp__PyDict_GetItemString'
pywrapper.o:pywrapper.c:(.text+0x3aad): undefined reference to
`_imp__PyInt_AsLong'
pywrapper.o:pywrapper.c:(.text+0x3ab8): undefined reference to
`_imp__PyErr_Occurred'
pywrapper.o:pywrapper.c:(.text+0x3aee): undefined reference to
`_imp__PyDict_GetItemString'
pywrapper.o:pywrapper.c:(.text+0x3af7): undefined reference to
`_imp__PyInt_AsLong'
pywrapper.o:pywrapper.c:(.text+0x3b02): undefined reference to
`_imp__PyErr_Occurred'
pywrapper.o:pywrapper.c:(.text+0x3b2d): undefined reference to
`_imp___Py_NoneStruct'
pywrapper.o:pywrapper.c:(.text+0x3b6d): undefined reference to
`_imp__PyDict_Type'
pywrapper.o:pywrapper.c:(.text+0x3b76): undefined reference to
`_imp__PyFunction_Type'
pywrapper.o:pywrapper.c:(.text+0x3c1d): undefined reference to
`_imp__PyArg_ParseTuple'
collect2: ld returned 1 exit status
make[1]: *** [pywrapper.so] Error 1
make[1]: Leaving directory `C:/Algencan/sources/interfaces/py'
make: *** [algencan-py] Error 2
PS C:\Algencan>
> ...
>
> read more »

Jan Marcel Paiva Gentil

unread,
Mar 28, 2009, 10:55:13 AM3/28/09
to TANGO Project - ALGENCAN
Hi,

Now that both your PYTHONINC and PYTHONLIB variables are correctly
set, a complete recompilation of all the object files is called for.
In order to accomplish this, please run "make distclean" in your
ALGENCAN installation directory prior to executing "make algencan-py"
once again. Hopefully, those error messages will vanish this time.


--
Jan Marcel

halve...@gmail.com

unread,
Mar 29, 2009, 12:53:07 AM3/29/09
to TANGO Project - ALGENCAN
I run make distclean and recieve the exact same errors as above e.g.
"pywrapper.o:pywrapper.c:(.text+0x2f): undefined reference to
`_imp__Py_InitModule4' "

On Mar 28, 8:55 am, Jan Marcel Paiva Gentil <jgmar...@ime.usp.br>
wrote:
> Hi,
>
> Now that both your PYTHONINC and PYTHONLIB variables are correctly
> set, a complete recompilation of all the object files is called for.
> In order to accomplish this, please run "make distclean" in your
> ALGENCAN installation directory prior to executing "make algencan-py"
> once again. Hopefully, those error messages will vanish this time.
>
> --
> Jan Marcel
>
> ...
>
> read more »

Yafeng Wang

unread,
Jan 22, 2013, 10:03:35 AM1/22/13
to tango-...@googlegroups.com

I got the same issue, can anyone fix it?

ps: I use 64bit python in win64 and mingw64

Ricardo Andrade

unread,
Jan 30, 2013, 8:27:03 AM1/30/13
to tango-...@googlegroups.com
Hi,
I was able to reproduce the same problem using Cygwin.
I'm using python 2.6 gcc and gfortran 4.5.3 .

I managed to solve the problem by doing the following change in the file sources/interfaces/py/Makefile :
Add the flag -lpython2.6 to the end of the line where is written:
        $(FC) $(LDFLAGS) $^ -o $@
so that the line be like this:
        $(FC) $(LDFLAGS) $^ -o $@ -lpython2.6

Maybe this can solve the problem in your case too.


   Best regards,


         Ricardo

Yafeng Wang

unread,
Feb 6, 2013, 4:42:49 AM2/6/13
to tango-...@googlegroups.com

Hi Ricardo

Thanks for your suggestion, adding -lpythonXX fix linking problems except Py_InitModule4.

I use 64bit python on 64bit windows 7.

By changing the Py_InitModule in the file to Py_InitModule4_64, there is no linking problem now.

But when I import the pywrapper, It shows a warning message that "Python C API version mismatch for module pywrapper: This Python has API version 1013, module pywrapper has version 74196000".

And when I run the provided example, it shows a typeError: "param must be a dictionary". But I think param is already a dictionary.

Thanks.

Yafeng 
Reply all
Reply to author
Forward
0 new messages