Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bindings do not compile using Mac OS 10.6 SDK #24

Open
GoogleCodeExporter opened this issue Mar 14, 2015 · 3 comments
Open

Bindings do not compile using Mac OS 10.6 SDK #24

GoogleCodeExporter opened this issue Mar 14, 2015 · 3 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. cabal install --user (no problems reported after fixing Block.h etc.).
2. cd Bindings; sh make-bindings-macos.sh --user

What is the expected output? What do you see instead?
Expected output: succesful build of the bindings.

What I see:

*** Processing Framework Foundation ***
Parsing Objective-C header files:                       [                       
  ]
Building initial entities:                              [                       
  ]
Resolving cross-references:                             [                       
  ]
Converting types:                                       [                       
  ]
Zapping unconvertable entities:                         [                       
  ]
Filling in additional instance declarations:            [                       
  ]
NSURLError.h:62:69: kCFURLErrorCancelled undefined      
[                       NSURLError.h:62:69: Couldn't handle enum value for 
NSURLErrorCancelled
NSURLError.h:63:66: kCFURLErrorBadURL undefined         
[                       NSURLError.h:63:66: Couldn't handle enum value for 
NSURLErrorBadURL
NSURLError.h:64:68: kCFURLErrorTimedOut undefined       
[                       NSURLError.h:64:68: Couldn't handle enum value for 
NSURLErrorTimedOut
NSURLError.h:65:74: kCFURLErrorUnsupportedURL undefined 
[                       NSURLError.h:65:74: Couldn't handle enum value for 
NSURLErrorUnsupportedURL
NSURLError.h:66:74: kCFURLErrorCannotFindHost undefined 
[                       NSURLError.h:66:74: Couldn't handle enum value for 
NSURLErrorCannotFindHost
NSURLError.h:67:79: kCFURLErrorCannotConnectToHost 
undefined                    NSURLError.h:67:79: Couldn't handle enum 
value for NSURLErrorCannotConnectToHost
NSURLError.h:68:81: kCFURLErrorNetworkConnectionLost 
undefined
NSURLError.h:68:81: Couldn't handle enum value for 
NSURLErrorNetworkConnectionLost
NSURLError.h:69:75: kCFURLErrorDNSLookupFailed undefined
NSURLError.h:69:75: Couldn't handle enum value for 
NSURLErrorDNSLookupFailed
NSURLError.h:70:80: kCFURLErrorHTTPTooManyRedirects 
undefined
NSURLError.h:70:80: Couldn't handle enum value for 
NSURLErrorHTTPTooManyRedirects
NSURLError.h:71:79: kCFURLErrorResourceUnavailable undefined
NSURLError.h:71:79: Couldn't handle enum value for 
NSURLErrorResourceUnavailable
NSURLError.h:72:82: kCFURLErrorNotConnectedToInternet 
undefined
NSURLError.h:72:82: Couldn't handle enum value for 
NSURLErrorNotConnectedToInternet
NSURLError.h:73:89: kCFURLErrorRedirectToNonExistentLocation 
undefined
NSURLError.h:73:89: Couldn't handle enum value for 
NSURLErrorRedirectToNonExistentLocation
NSURLError.h:74:77: kCFURLErrorBadServerResponse undefined
NSURLError.h:74:77: Couldn't handle enum value for 
NSURLErrorBadServerResponse
NSURLError.h:75:87: kCFURLErrorUserCancelledAuthentication 
undefined
NSURLError.h:75:87: Couldn't handle enum value for 
NSURLErrorUserCancelledAuthentication
NSURLError.h:76:86: kCFURLErrorUserAuthenticationRequired 
undefined
NSURLError.h:76:86: Couldn't handle enum value for 
NSURLErrorUserAuthenticationRequired
NSURLError.h:77:76: kCFURLErrorZeroByteResource undefined
NSURLError.h:77:76: Couldn't handle enum value for 
NSURLErrorZeroByteResource
NSURLError.h:78:79: kCFURLErrorCannotDecodeRawData 
undefined
NSURLError.h:78:79: Couldn't handle enum value for 
NSURLErrorCannotDecodeRawData
NSURLError.h:79:83: kCFURLErrorCannotDecodeContentData 
undefined
NSURLError.h:79:83: Couldn't handle enum value for 
NSURLErrorCannotDecodeContentData
NSURLError.h:80:79: kCFURLErrorCannotParseResponse 
undefined
NSURLError.h:80:79: Couldn't handle enum value for 
NSURLErrorCannotParseResponse
NSURLError.h:81:76: kCFURLErrorFileDoesNotExist undefined
NSURLError.h:81:76: Couldn't handle enum value for 
NSURLErrorFileDoesNotExist
NSURLError.h:82:75: kCFURLErrorFileIsDirectory undefined
NSURLError.h:82:75: Couldn't handle enum value for 
NSURLErrorFileIsDirectory
NSURLError.h:83:83: kCFURLErrorNoPermissionsToReadFile 
undefined
NSURLError.h:83:83: Couldn't handle enum value for 
NSURLErrorNoPermissionsToReadFile
NSURLError.h:85:84: kCFURLErrorDataLengthExceedsMaximum 
undefined
NSURLError.h:85:84: Couldn't handle enum value for 
NSURLErrorDataLengthExceedsMaximum
NSURLError.h:89:82: kCFURLErrorSecureConnectionFailed 
undefined
NSURLError.h:89:82: Couldn't handle enum value for 
NSURLErrorSecureConnectionFailed
NSURLError.h:90:87: kCFURLErrorServerCertificateHasBadDate 
undefined
NSURLError.h:90:87: Couldn't handle enum value for 
NSURLErrorServerCertificateHasBadDate
NSURLError.h:91:86: kCFURLErrorServerCertificateUntrusted 
undefined
NSURLError.h:91:86: Couldn't handle enum value for 
NSURLErrorServerCertificateUntrusted
NSURLError.h:92:91: 
kCFURLErrorServerCertificateHasUnknownRoot undefined
NSURLError.h:92:91: Couldn't handle enum value for 
NSURLErrorServerCertificateHasUnknownRoot
NSURLError.h:93:88: kCFURLErrorServerCertificateNotYetValid 
undefined
NSURLError.h:93:88: Couldn't handle enum value for 
NSURLErrorServerCertificateNotYetValid
NSURLError.h:94:85: kCFURLErrorClientCertificateRejected 
undefined
NSURLError.h:94:85: Couldn't handle enum value for 
NSURLErrorClientCertificateRejected
NSURLError.h:95:85: kCFURLErrorClientCertificateRequired 
undefined
NSURLError.h:95:85: Couldn't handle enum value for 
NSURLErrorClientCertificateRequired
NSURLError.h:96:81: kCFURLErrorCannotLoadFromNetwork 
undefined
NSURLError.h:96:81: Couldn't handle enum value for 
NSURLErrorCannotLoadFromNetwork
NSURLError.h:99:76: kCFURLErrorCannotCreateFile undefined
NSURLError.h:99:76: Couldn't handle enum value for 
NSURLErrorCannotCreateFile
NSURLError.h:100:74: kCFURLErrorCannotOpenFile undefined
NSURLError.h:100:74: Couldn't handle enum value for 
NSURLErrorCannotOpenFile
NSURLError.h:101:75: kCFURLErrorCannotCloseFile undefined
NSURLError.h:101:75: Couldn't handle enum value for 
NSURLErrorCannotCloseFile
NSURLError.h:102:77: kCFURLErrorCannotWriteToFile undefined
NSURLError.h:102:77: Couldn't handle enum value for 
NSURLErrorCannotWriteToFile
NSURLError.h:103:76: kCFURLErrorCannotRemoveFile undefined
NSURLError.h:103:76: Couldn't handle enum value for 
NSURLErrorCannotRemoveFile
NSURLError.h:104:74: kCFURLErrorCannotMoveFile undefined
NSURLError.h:104:74: Couldn't handle enum value for 
NSURLErrorCannotMoveFile
NSURLError.h:105:91: 
kCFURLErrorDownloadDecodingFailedMidStream undefined
NSURLError.h:105:91: Couldn't handle enum value for 
NSURLErrorDownloadDecodingFailedMidStream
NSURLError.h:106:92: 
kCFURLErrorDownloadDecodingFailedToComplete undefined
NSURLError.h:106:92: Couldn't handle enum value for 
NSURLErrorDownloadDecodingFailedToComplete
Parsing Objective-C header files:                       [                       
hoc-
ifgen: user error ("NSObjCRuntime.h" (line 193, column 71):
unexpected "("
expecting "__attribute__", identifier, "=", ";", "," or "{")


What version of the product are you using? On what operating 
system?
svn checkout of hoc from feb 5th on Snow Leopard with ghc 6.10.4, 
cabal 1.6.0.3, and cabal-install 0.6.4.

Original issue reported on code.google.com by jejan...@gmail.com on 6 Feb 2010 at 12:00

@GoogleCodeExporter
Copy link
Author

I found a workaround for this. If you change the bindings to use the 10.5 SDK 
(and 
have the 10.5 SDK installed), the bindings will compile.

Attached is a patch to let you select the SDK via an environment variable.  I 
run it like:

HOC_SDK=MacOSX10.5 sh ./make-bindings-macos.sh --user

Original comment by bickfo...@gmail.com on 21 Feb 2010 at 8:22

Attachments:

@GoogleCodeExporter
Copy link
Author

I have applied the fix-bindings.patch above (Thanks!) and modified the build 
instructions in README.txt to tell people to use HOC_SDK=MacOSX10.5.

This issue will remain open until parsing the 10.6 SDK works.

Original comment by aut...@gmail.com on 18 Jun 2010 at 12:30

  • Changed title: Bindings do not compile using Mac OS 10.6 SDK
  • Changed state: Accepted

@GoogleCodeExporter
Copy link
Author

One of the reasons Bindings do not compile using Mac OS 10.6 SDK is because of 
macros present in the header files breaking the parser. 

Using gcc -E -P on those headers before parsing them would expand all the 
macros, but also expand all the #includes. Do you think the preprocessor is a 
viable option for making the ifgen parse the header files successfully?

Original comment by meric...@gmail.com on 15 Feb 2012 at 3:09

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant