[ python-Bugs-1005737 ] compile errors on _codecs_iso2022.c

SourceForge.net noreply at sourceforge.net
Wed Aug 18 16:56:06 CEST 2004


Bugs item #1005737, was opened at 2004-08-09 03:36
Message generated for change (Comment added) made by rptownsend
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1005737&group_id=5470

Category: Build
Group: Python 2.4
Status: Open
Resolution: None
Priority: 6
Submitted By: roadkill (dharma_roadkill)
Assigned to: Hye-Shik Chang (perky)
Summary: compile errors on _codecs_iso2022.c

Initial Comment:
Building
Python-2.4a2
on uname -a
OSF1 ***.tnzi.com V5.1 2650 alpha
(HP Tru64 5.1B on alpha server)
One of the modules won't compile correctly.
I note with interest that another submitter to Bug 
Tracker had an intermittant core dump in the iso2022 
area.  Maybe this is related to that other problem.  The 
Tru64 cc compiler is fairly sensitive and gives 
warnings/errors when other compilers would be silent but 
those warnings/errors are usually worth looking at!

cc: Error: /u13/home/doug/python/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c, line 1053: 
In the initializer for iso2022_kr_config, an array's element 
type
is incomplete, which precludes its initialization. 
(incompelinit)
cc: Error: /u13/home/doug/python/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c, line 1058: 
In the initializer for iso2022_jp_config, an array's element 
type
is incomplete, which precludes its initialization. 
(incompelinit)
cc: Error: /u13/home/doug/python/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c, line 1064: 
In the initializer for iso2022_jp_1_config, an array's 
element typ
e is incomplete, which precludes its initialization. 
(incompelinit)
cc: Error: /u13/home/doug/python/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c, line 1070: 
In the initializer for iso2022_jp_2_config, an array's 
element typ
e is incomplete, which precludes its initialization. 
(incompelinit)
cc: Error: /u13/home/doug/python/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c, line 1077: 
In the initializer for iso2022_jp_2004_config, an array's 
element
type is incomplete, which precludes its initialization. 
(incompelinit)
cc: Error: /u13/home/doug/python/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c, line 1084: 
In the initializer for iso2022_jp_3_config, an array's 
element typ
e is incomplete, which precludes its initialization. 
(incompelinit)
cc: Error: /u13/home/doug/python/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c, line 1091: 
In the initializer for iso2022_jp_ext_config, an array's 
element t
ype is incomplete, which precludes its initialization. 
(incompelinit)

----------------------------------------------------------------------

Comment By: Richard Townsend (rptownsend)
Date: 2004-08-18 15:56

Message:
Logged In: YES 
user_id=200117

Sorry for the confusion, but it doesn't compile on HP-UX with 
the last patch.

My post of 2004-08-12 16:57 was just correcting a typo in 
the previous post.

----------------------------------------------------------------------

Comment By: Hye-Shik Chang (perky)
Date: 2004-08-18 14:52

Message:
Logged In: YES 
user_id=55188

Thanks for testing. Do you mean that it compiles on HP-UX
with the current patch?

----------------------------------------------------------------------

Comment By: Richard Townsend (rptownsend)
Date: 2004-08-12 16:57

Message:
Logged In: YES 
user_id=200117

Oops! that was a fresh install of Python-2.4a2...

----------------------------------------------------------------------

Comment By: Richard Townsend (rptownsend)
Date: 2004-08-12 16:55

Message:
Logged In: YES 
user_id=200117

I did a fresh install of Python-2.2a2 and applied your new 
patch, but I'm still getting compile errors for line 200:

building '_codecs_iso2022' extension
cc -Ae -DNDEBUG +O2 -z +Onofltacc +ESlit +Oentrysched 
+Odataprefetch +Onolimit +DA2.0 +Z -I. -
I/home/richardt/python-24/Python-2.4a2/./Include -
I/opt/python/include -I/usr/local/include -
I/home/richardt/python-24/Python-2.4a2/Include -
I/home/richardt/python-24/Python-2.4a2 -
c /home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c -o 
build/temp.hp-ux-B.11.11-9000/785-2.4/_codecs_iso2022.o
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 200: error 
1521: Incorrect initialization.
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 200: error 
1521: Incorrect initialization.

Here are lines 198-203 after applying the patch

#if Py_UNICODE_SIZE == 2
				if (length == 2) {
					ucs4_t u4in
[2] = {(ucs4_t)IN1, (ucs4_t)IN2};
					encoded = 
dsg->encoder(u4in, &length);
				} else
					encoded = 
dsg->encoder(&c, &length);

One of my collegues says that you can't initialise one variable 
with another variable, when using the cc compiler.


----------------------------------------------------------------------

Comment By: Hye-Shik Chang (perky)
Date: 2004-08-12 14:03

Message:
Logged In: YES 
user_id=55188

Thanks for testing!
I uploaded new patch fixed the problem.
Can you both test the patch whether it compiles?

----------------------------------------------------------------------

Comment By: Richard Townsend (rptownsend)
Date: 2004-08-12 08:37

Message:
Logged In: YES 
user_id=200117

After applying the patch I am still getting two comple errors 
on HP-UX 11i

building '_codecs_iso2022' extension
cc -Ae -DNDEBUG +O2 -z +Onofltacc +ESlit +Oentrysched 
+Odataprefetch +Onolimit +DA2.0 +Z -I. -
I/home/richardt/python-24/Python-2.4a2/./Include -
I/opt/python/include -I/usr/local/include -
I/home/richardt/python-24/Python-2.4a2/Include -
I/home/richardt/python-24/Python-2.4a2 -
c /home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c -o 
build/temp.hp-ux-B.11.11-9000/785-2.4/_codecs_iso2022.o
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 200: error 
1521: Incorrect initialization.
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 200: error 
1521: Incorrect initialization.


----------------------------------------------------------------------

Comment By: Hye-Shik Chang (perky)
Date: 2004-08-11 23:14

Message:
Logged In: YES 
user_id=55188

The attached patch converts C99 usages to plain legacy C.
Can you please test it on HP-UX whether the problem is resolved?

----------------------------------------------------------------------

Comment By: Richard Townsend (rptownsend)
Date: 2004-08-09 09:15

Message:
Logged In: YES 
user_id=200117

I am getting slightly different errors on HP-UX 11i using the 
native C compiler 'cc'.

building '_codecs_iso2022' extension
cc -Ae -DNDEBUG +O2 -z +Onofltacc +ESlit +Oentrysched 
+Odataprefetch +Onolimit +DA2.0 +Z -I. -
I/home/richardt/python-24/Python-2.4a2/./Include -
I/opt/python/include -I/usr/local/include -
I/home/richardt/python-24/Python-2.4a2/Include -
I/home/richardt/python-24/Python-2.4a2 -
c /home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c -o 
build/temp.hp-ux-B.11.11-9000/785-2.4/_codecs_iso2022.o
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 120: error 
1578: Size of struct or union member is unknown.
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 200: error 
1521: Incorrect initialization.
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 200: error 
1521: Incorrect initialization.
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 1058: 
error 1523: Too many initializers.
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 1064: 
error 1523: Too many initializers.
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 1070: 
error 1523: Too many initializers.
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 1078: 
error 1523: Too many initializers.
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 1085: 
error 1523: Too many initializers.
cc: "/home/richardt/python-24/Python-
2.4a2/Modules/cjkcodecs/_codecs_iso2022.c", line 1091: 
error 1523: Too many initializers.

uname -a
HP-UX capulet B.11.11 U 9000/785 2002932658 unlimited-user 
license



----------------------------------------------------------------------

Comment By: Hye-Shik Chang (perky)
Date: 2004-08-09 06:10

Message:
Logged In: YES 
user_id=55188

It seems that I used C99 grammar in that lines.  Sorry.
I'll fix it for C89 compilers soon.  Thank you for the report!


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1005737&group_id=5470


More information about the Python-bugs-list mailing list