Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 276591 - MAC OS: Replace malloc.h references with stdlib.h
Summary: MAC OS: Replace malloc.h references with stdlib.h
Status: CLOSED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: TPTP (show other bugs)
Version: unspecified   Edit
Hardware: All Mac OS X - Carbon (unsup.)
: P2 major (vote)
Target Milestone: ---   Edit
Assignee: Paul Klicnik CLA
QA Contact: Kathy Chan CLA
URL:
Whiteboard: closed471
Keywords:
Depends on:
Blocks: 68111
  Show dependency tree
 
Reported: 2009-05-16 04:42 EDT by Spundun Bhatt CLA
Modified: 2016-05-05 10:52 EDT (History)
2 users (show)

See Also:


Attachments
malloc.h patch (7.65 KB, patch)
2009-05-16 04:43 EDT, Spundun Bhatt CLA
no flags Details | Diff
updated paths. (8.18 KB, patch)
2009-05-17 01:39 EDT, Spundun Bhatt CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Spundun Bhatt CLA 2009-05-16 04:42:23 EDT
malloc.h is a non-standard library reference. The correct reference is stdlib.h. This file is available on all the platforms supported by TPTP currently, and it's blocking the build of the Agent Controller on Mac OSX. Here is a patch that removes malloc.h refernces from src-native-new directory.

It's a very simple patch and should work for all your builds. I have left 3 malloc.h references in the source tree, they are guarded by ifdef _HPUX . In my opinion those should go also, as on HPUX also it's recommended to use stdlib.h instead of malloc.h http://www.informatik.uni-frankfurt.de/doc/man/hpux/malloc.3c.html . But those are not in my way so I didn't touch them, I suggest you replace those also.

I suspect that some of these header references are not even used. And they are breaking the Mac OSX build. 

Thanks.
Comment 1 Spundun Bhatt CLA 2009-05-16 04:43:43 EDT
Created attachment 136097 [details]
malloc.h patch

A unified diff patch removing/replacing malloc.h references in snn
Comment 2 Kathy Chan CLA 2009-05-16 18:33:48 EDT
Jonathan,

Please take a look at the patch proposed.  Tentatively targeting TPTP 4.6 for now pending more detail assessment.
Comment 3 Spundun Bhatt CLA 2009-05-17 01:39:10 EDT
Created attachment 136114 [details]
updated paths.

now the patch is  rooted at project root
Comment 4 Jonathan West CLA 2009-05-24 22:12:10 EDT
Comment on attachment 136097 [details]
malloc.h patch

Contributer has posted an updated patch.
Comment 5 Jonathan West CLA 2009-05-24 22:17:34 EDT
Hi Spundun, patch looks good, and I agree with your assessment, thanks for your contribution! We are presently closing off 4.6.0 (e.g. full code freeze), so I will work to find an appropriate time to check this in.
Comment 6 Kathy Chan CLA 2009-05-25 17:04:16 EDT
Thanks!

Paul, please take a look at merging these MAC OS patches to the current code base in HEAD for post TPTP 4.6.
Comment 7 Kathy Chan CLA 2009-07-13 15:07:06 EDT
Hi Spundun,

Could you please add a comment to this bugzilla to confirm that you authored 100% of the content submitted in this patch and you have the rights to donate the content to Eclipse under the EPL (http://eclipse.org/legal/epl-v10.html)? Note that the answer to the above question is part of the requirement for getting legal approval for checking in your contributions to CVS.
Comment 8 Spundun Bhatt CLA 2009-07-21 19:49:55 EDT
Hi Kathy,

Please read the following three points carefully, I'll try to make it as short as I can.

-> I Authorize all the work that I've done, to be used under EPL, by the project that this bugzilla currently belongs to.

-> It should be noted that some of the contribution has come under my time at work with my employer "University of Southern California, Information Sciences Institute". The official url is www.isi.edu . 

-> Please understand that my efforts were mostly spent in re-organizing existing patches and code. This code was already contributed to bug #68111 by other folks. I *did* contribute improvements to the existing patch, in terms of better organization, readability, and overall compatibility with current CVS head.

Comment 9 Spundun Bhatt CLA 2009-07-21 19:52:37 EDT
Also  I have gotten the approval of my employer for this contribution
Comment 10 Kathy Chan CLA 2009-07-28 14:25:11 EDT
Please add the following to the header of all files contributed by Spundun:

Contributed by Spundun Bhatt (spundun@gmail.com), with the support and encouragement of the University of Southern California Information Sciences Institute Distributed Scalable Systems Division.
Comment 11 Kathy Chan CLA 2009-07-29 12:33:45 EDT
Note that the CQ for Spundun's contribution to RFE bug 68111 (and it's child defects bug 276591 bug 276607, bug 276615 and bug 276640) have been approved by the Eclipse IPO under CQ 3397 (https://dev.eclipse.org/ipzilla/show_bug.cgi?id=3397).  The patch can be checked in now with the above update to the header of all files contributed by Spundun.
Comment 12 Jonathan West CLA 2009-08-06 20:55:18 EDT
Patch checked into HEAD. Thanks Spundun!
Comment 13 Kathy Chan CLA 2010-11-18 18:53:39 EST
As of TPTP 4.6.0, TPTP is in maintenance mode and focusing on improving quality by resolving relevant enhancements/defects and increasing test coverage through test creation, automation, Build Verification Tests (BVTs), and expanded run-time execution. As part of the TPTP Bugzilla housecleaning process (see http://wiki.eclipse.org/Bugzilla_Housecleaning_Processes), this enhancement/defect is verified/closed by the Project Lead since this enhancement/defect has been resolved and unverified for more than 1 year and considered to be fixed. If this enhancement/defect is still unresolved and reproducible in the latest TPTP release (http://www.eclipse.org/tptp/home/downloads/), please re-open.