From aixtools at gmail.com  Fri Feb 19 11:06:35 2016
From: aixtools at gmail.com (Michael Felt)
Date: Fri, 19 Feb 2016 11:06:35 +0100
Subject: [Rd] R,
 AIX 64-bit builds - trying to understand root cause for message:
 "Error: Line starting 'Package: tools ...' is malformed!"
In-Reply-To: <11C4A052-1585-41A9-BFBD-1756E6DC8B96@r-project.org>
References: <56825A4B.7010508@gmail.com> <56839C9E.2010401@gmail.com>
	<5685466E.7000804@gmail.com>
	<4BED4A65-8EE9-49B8-8AFB-4E6CC3BB5BBF@r-project.org>
	<F92F30A1-4E5C-4312-B151-692F27013F8B@r-project.org>
	<F68557F2-67ED-4EF3-8BDF-F7981D8F38C0@gmail.com>
	<56894556.3020902@gmail.com>
	<5138BF7E-44C2-4ABE-9D3F-0730BCF90BC9@r-project.org>
	<568A1285.5000709@gmail.com>
	<11C4A052-1585-41A9-BFBD-1756E6DC8B96@r-project.org>
Message-ID: <56C6E92B.1080809@gmail.com>

Hi Simon,

I have been busy with work, but I finally got around to repackaging 
libiconv for AIX - in a way that both adds GNU libiconv support 
(libiconv.so.2 member) and is both 32 and 64 bit without breaking 
support for IBM iconv applications.

I concur that iconv is a pain as IBM and GNU made different decesions 
about an 'implementor' choice to call a translation to an error or not - 
when the output map(?) does not include a character. IBM choose to 
output ASCII 32 (space) and GNU calls it an error. The standard states 
it is an error when a char (or code) is used in the input, but is not in 
the input table. Enough said imho - IBM and GNU differ in their approach 
and autotools test for this difference.

So, I have a way to have both approaches available via /usr/lib. For a 
bit more detail please see: http://www.aixtools.net/index.php/libiconv - 
I do hope this 'fixes' the libiconv issues! for OSS.

Using this library you should be able to replace: (what you sent in an 
earlier e-mail as your configure statement)

On 2016-01-04 15:52, Simon Urbanek wrote:
>> >  I would be "pleased" if you would try packages - i.e., none of "Toolbox" or Perzl rpm's.
>> >  
> R requires iconv, so you have to get that somehow. I tried to bypass the check and build it anyway against the system one, but that fails as there is a iconv conversion further down the line that is not supported. Building iconv is a PITA because it conflicts with the system one so other tools break when you modify the load path. Perzl's iconv fixes that by incorporating both the system objects and the GNU ones into the same binary and that seems to work reliably so far. That is the only dependency I was using (his iconv doesn't have any dependencies itself).
>
>
configure CC=xlc_r CXX=xlc++_r F77=xlf_r FC=xlf95_r LIBS='-L/opt/freeware/lib /opt/freeware/lib/libiconv.a -lpthread' --prefix=/opt/freeware CPPFLAGS=-I/opt/freeware/include

with export OBJECT_MODE=64 in the env (and libiconv from perzl.org RPMs - iconv is a serious pain).


with

export OBJECT_MODE=64
configure CC=xlc_r CXX=xlc++_r F77=xlf_r FC=xlf95_r LIBS='-lpthread' --prefix=/opt/freeware


You may even be able to replace --prefix=/opt/freeware to --prefix=/opt (I use the latter to not step on anything in /opt/freeware)



[Rd] R, AIX 64-bit builds - trying to understand root cause for message: "Error: Line starting 'Package: tools ...' is malformed!"
Michael Felt