{"action":"created","issue":{"url":"https://api.github.com/repos/haskell/cabal/issues/1493","repository_url":"https://api.github.com/repos/haskell/cabal","labels_url":"https://api.github.com/repos/haskell/cabal/issues/1493/labels{/name}","comments_url":"https://api.github.com/repos/haskell/cabal/issues/1493/comments","events_url":"https://api.github.com/repos/haskell/cabal/issues/1493/events","html_url":"https://github.com/haskell/cabal/issues/1493","id":19174330,"node_id":"MDU6SXNzdWUxOTE3NDMzMA==","number":1493,"title":"build Setup.hs with local compiler when cross-compiling","user":{"login":"rwbarton","id":22628,"node_id":"MDQ6VXNlcjIyNjI4","avatar_url":"https://avatars1.githubusercontent.com/u/22628?v=4","gravatar_id":"","url":"https://api.github.com/users/rwbarton","html_url":"https://github.com/rwbarton","followers_url":"https://api.github.com/users/rwbarton/followers","following_url":"https://api.github.com/users/rwbarton/following{/other_user}","gists_url":"https://api.github.com/users/rwbarton/gists{/gist_id}","starred_url":"https://api.github.com/users/rwbarton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rwbarton/subscriptions","organizations_url":"https://api.github.com/users/rwbarton/orgs","repos_url":"https://api.github.com/users/rwbarton/repos","events_url":"https://api.github.com/users/rwbarton/events{/privacy}","received_events_url":"https://api.github.com/users/rwbarton/received_events","type":"User","site_admin":false},"labels":[{"id":5625697,"node_id":"MDU6TGFiZWw1NjI1Njk3","url":"https://api.github.com/repos/haskell/cabal/labels/cabal-install:%20other","name":"cabal-install: other","color":"d93f0b","default":false},{"id":1389138,"node_id":"MDU6TGFiZWwxMzg5MTM4","url":"https://api.github.com/repos/haskell/cabal/labels/type:%20bug","name":"type: bug","color":"e99695","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":40,"created_at":"2013-09-09T03:28:54Z","updated_at":"2018-08-13T21:31:11Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"I have a script that invokes cabal with `--with-ghc=...`, `--with-ghc-pkg=...`, `--with-gcc=...`, etc. for cross-compiling to Android.  It works great for most packages, but fails for a package with Build-type: Custom, because it builds `Setup.hs` with the cross-compiler specified on the command-line, and then obviously it can't run `dist/setup/setup` because it's an ARM executable.\n\nI can work around the issue by doing an ordinary cabal configure with no `--with-ghc=...` options first, then doing a cabal install with my cross-compiler script, because the second invocation uses the cached `dist/setup/setup` from the first one.  But that's a hack, obviously, and annoying to do when the package I'm installing is a dependency of the one I actually want.\n\nWhat I would like is a separate set of options for specifying the program configuration to use to build `Setup.hs`; or at least an option to tell cabal to just use the ones on my path.  I found that using `defaultSetupScriptOptions` for `setupScriptOptions` in `configure` and `performInstallations` seemed to do the trick for me, to give an idea of what I want to happen, though I haven't tested the resulting libraries.  I couldn't determine whether there is already a way to achieve the same effect through command-line options.\n"},"comment":{"url":"https://api.github.com/repos/haskell/cabal/issues/comments/412671758","html_url":"https://github.com/haskell/cabal/issues/1493#issuecomment-412671758","issue_url":"https://api.github.com/repos/haskell/cabal/issues/1493","id":412671758,"node_id":"MDEyOklzc3VlQ29tbWVudDQxMjY3MTc1OA==","user":{"login":"Ericson2314","id":1055245,"node_id":"MDQ6VXNlcjEwNTUyNDU=","avatar_url":"https://avatars3.githubusercontent.com/u/1055245?v=4","gravatar_id":"","url":"https://api.github.com/users/Ericson2314","html_url":"https://github.com/Ericson2314","followers_url":"https://api.github.com/users/Ericson2314/followers","following_url":"https://api.github.com/users/Ericson2314/following{/other_user}","gists_url":"https://api.github.com/users/Ericson2314/gists{/gist_id}","starred_url":"https://api.github.com/users/Ericson2314/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ericson2314/subscriptions","organizations_url":"https://api.github.com/users/Ericson2314/orgs","repos_url":"https://api.github.com/users/Ericson2314/repos","events_url":"https://api.github.com/users/Ericson2314/events{/privacy}","received_events_url":"https://api.github.com/users/Ericson2314/received_events","type":"User","site_admin":false},"created_at":"2018-08-13T21:31:11Z","updated_at":"2018-08-13T21:31:11Z","author_association":"COLLABORATOR","body":"It's still on my radar, but no direct work yet."}}
{"actor":{"display_login":"Ericson2314"}}