Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 258501 - Fixes for AIX SDM debugger compilation
Summary: Fixes for AIX SDM debugger compilation
Status: RESOLVED DUPLICATE of bug 399428
Alias: None
Product: PTP
Classification: Tools
Component: Debug SDM (show other bugs)
Version: 2.1   Edit
Hardware: Power PC AIX Motif
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Greg Watson CLA
QA Contact: clement chu CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-12-11 12:27 EST by David Wootton CLA
Modified: 2013-01-29 14:52 EST (History)
1 user (show)

See Also:


Attachments
AIX SDM patch (6.71 KB, patch)
2008-12-11 12:27 EST, David Wootton CLA
g.watson: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Wootton CLA 2008-12-11 12:27:52 EST
Created attachment 120223 [details]
AIX SDM patch

Currently the SDM debugger does not compile on AIX because of dependencies on GNU getopt() that are incompatible with AIX getopt().

This patch fixes AIX options parsing so SDM works correctly.

I had to update configure.in and Makefile.am files because of differences in compiler options betweeen AIX and Linux. I did not include updated copies of the configure and Makefile.in files since when I ran automake and autoconf on my Linux system, they complained about version differences between the tools that built the files in teh PTP build and the versions I had. I did not want to cause problems with the ptp build. Those should be updated on whatever system is compatible with the ptp build tools.
Comment 1 Greg Watson CLA 2008-12-12 22:47:27 EST
Applied, but I changed the #ifdef __linux__ to #ifndef _AIX so that Mac OS X would also work. Please check the AIX build is still ok.
Comment 2 David Wootton CLA 2008-12-15 14:42:51 EST
AIX build still works with modified patch
Comment 3 Dan Sun CLA 2012-05-04 00:03:39 EDT
(In reply to comment #1)
> Applied, but I changed the #ifdef __linux__ to #ifndef _AIX so that Mac OS X
> would also work. Please check the AIX build is still ok.
Hi Greg,

I have been trying to get sdm included in PTP5.0.7 to compile under AIX and I found the AIX build is currently broken. I think it may be caused by the following three errors:

1. there seems to be an error in function vasprintf inside in file compact.c, which is in org.eclipse.ptp.utils_5.0.7.201203231315/src/. The compiler is complaining about using variable ret without declaration first. I am guessing that ret is supposed to be the first parameter of the function, and I was able to compile the util library after I rename the first parameter of function vasprintf to ret.

2. Makefile generated for compiling libaif does not include linking to utils and its patch and it causes an undefined reference error when compiling this library. I resolved this error by adding "-lutils -L../../org.eclipse.ptp.utils_5.0.7.201203231315" to LIBS in the Makefile.

3. Makefile generated for compiling libmi does not include linking to utils and its patch and it causes an undefined reference error when compiling this library. I resolved this error by by using the same approach described in #2 as well.

Can you please verify if my changes are correct for resolving issues when building SDM under AIX?

Thanks and Regards,

DanS.
Comment 4 Greg Watson CLA 2012-05-23 17:40:12 EDT
Dan,

Sorry this has taken so long. We're about to release a new version of PTP so I presume you'd like these fixes in the new version rather than the current version? We're not planning any more releases of the current version.
Comment 5 Dan Sun CLA 2012-05-23 17:47:42 EDT
(In reply to comment #4)
> Dan,
> 
> Sorry this has taken so long. We're about to release a new version of PTP so I
> presume you'd like these fixes in the new version rather than the current
> version? We're not planning any more releases of the current version.

Yes, please include these fixes in the new version of PTP.

Thanks.
Comment 6 David Wootton CLA 2013-01-29 14:52:01 EST
The problems with asprintf and linking in the sdm directories are fixed by bug 399428

*** This bug has been marked as a duplicate of bug 399428 ***