Commit graph

47 commits

Author SHA1 Message Date
John Ericson
0828e2d8c3 treewide: Remove usage of remaining redundant platform compatability stuff
Want to get this out of here for 18.09, so it can be deprecated
thereafter.
2018-08-30 17:20:32 -04:00
Matthew Bauer
b300dddae1 xcbuild: only override version with 1 arg
sometimes we want the "SDK" version from xcbuild so we do something
like:

$ xcbuild -version -sdk MacOSX10.10
SDKSettings.plist - MacOSX10.10 (MacOSX10.10)
SDKVersion: 10.10
Path: /nix/store/6k7crm1n4drf09ga0dwvbmb59x4zl2i2-SDKs/MacOSX10.10.sdk
PlatformPath: /nix/store/vhfwb1znfy65s2xs27j8xribk6mp6lbw-Platforms/MacOSX.platform
ProductName: Mac OS X
ProductVersion: 10.10

This was previously overriden by the current xcode version so you
would get:

Xcode 9.4.1
Build version 17E189

This should fix the other usage of -version in nodejs 6.x.
2018-08-20 13:16:37 -05:00
Matthew Bauer
c391bd3dd3 xcbuild: cleanup
fix shell shebang
2018-08-11 22:54:48 -05:00
Matthew Bauer
b5d529d52f xcbuild: cleanup 2018-08-11 22:54:48 -05:00
Matthew Bauer
0edb441a0e firefox: build on darwin
Fixes #30285
2018-08-11 22:54:48 -05:00
Jörg Thalheim
218298b30f
Merge branch 'master' into unused5 2018-07-21 15:41:22 +01:00
volth
52f53c69ce pkgs/*: remove unreferenced function arguments 2018-07-21 02:48:04 +00:00
volth
6d2857a311 [bot] treewide: remove unused 'inherit' in let blocks 2018-07-20 19:38:19 +00:00
Matthew Bauer
0534ceac81 xcbuild: move setup hook to xcbuildHook
Not every package that needs xcbuild will want to use its build phase.
I have moved the xcbuild setup hook to the new attribute xcbuildHook.
This means that dontUseXcbuild is no longer needed. If you just need
to call xcbuild on its own you can just refer to xcbuild.
2018-07-09 17:13:58 -04:00
Matthew Bauer
35b2c0edf2 xcbuild: refactor
This reworks some of xcbuild logic to make it more compatible with
Apple’s SDK.

- Add a fake version of xcrun & xcode-select
- Cleanup platform generation. Clang does not like having 20 char
  hashes in sysroot so it is much easier to just build the parent
  directory for each runCommand. This is a little awkward but I have
  renamed everything with an added ‘s’ to make the distinction more clear.
- Cleaned up wrapper.nix in some different ways
- Reuse some versioning logic so that we don’t end up with two
  different versions of Xcode or SDK reported.
2018-07-09 17:10:20 -04:00
Matthew Bauer
394c3fe0ab xcbuild: add missing bins
A few from cctools were missing. Ideally they would not be needed but
xcode provides them & we pretty much need to as well for a lot of
xcode projects.
2018-06-28 19:40:40 -04:00
Matthew Bauer
337b58950b generators: refactor toPlist
Address PR comments

Refactors

- Rename toPLIST -> toPlist
2018-06-28 15:24:12 -04:00
Matthew Bauer
d361371d23 generators: refactor toPLIST 2018-06-28 11:11:19 -04:00
Matthew Bauer
c672e37f4a xcbuild: rework to use lib.PLIST
This is a good way to test that plist works.

Sorry for the large diff. There are a bunch of cleanups in here that
needed to be done. Should make it possible to use in cross
compilation.
2018-06-27 15:36:00 -04:00
Matthew Bauer
d5dc446b38 xcbuild: fix wrapper
need $wrapper/usr/bin to exist for some SDK stuff
2018-04-12 14:12:29 -05:00
Matthew Bauer
7c1e39746d xcbuild: set SYMROOT and OBJROOT 2018-04-09 18:35:35 -05:00
Matthew Bauer
a77de95529 xcbuild: add framework product 2018-04-09 18:35:34 -05:00
Daiderd Jordan
6377391d68
xcbuild: include version in wrapper 2018-01-20 20:50:23 +01:00
Daiderd Jordan
6fba728a6d
xcbuild: include version in sdk
Without this xcbuild can detect an incorrect version for store paths
that have a sequence of digits in their hash.

ld: malformed 32-bit x.y.z version number: 85294

/nix/store/yz966rdvw1blblvzs15pxpcd85294isw-MacOSX.platform/Developer/SDKs/MacOSX.sdk
2018-01-20 20:42:29 +01:00
Dan Peebles
e86991e1e8 darwin: fix assorted xcbuild builds
This includes adding a new xcbuild-based libutil build to test the waters a bit there.
We'll need to get xcbuild into the stdenv bootstrap before we can make the main build,
but it's nice to see that it can work.
2017-10-12 07:16:22 -04:00
Dan Peebles
5de4d19392 xcbuild: 0.1.1 -> 0.1.2-pre
Also, add some static library stuff to the platform spec
2017-10-11 01:18:13 -04:00
Dan Peebles
f92e097cd4 xcbuild: add SDKROOT by default to the wrappers
This fixes #30269 and lets us do things like `xcrun -find cc`, for
example.
2017-10-10 16:41:44 -04:00
Matthew Bauer
f8f3384638
xcbuild: fix sdk dir name issue
Previously, this error was coming up in xcbuild:

ld: malformed 32-bit x.y.z version number: 1068638

It’s an interesting error because it only happens with certain hashes for the
nixpkgs sdk. For instance, on latest nixpkgs unstable channel, the hash for the
xcbuild sdk is:

/nix/store/w6mwbdaz9calyii0fyxspl51f1068638-nix.nixpkgs.sdk

that is an issue we pass -isysroot ${sdk} to clang where it will interpret that
hanging "1068638". It would probably go away as soon as the hash changes but
this hacky fix will solve the problem.
2017-09-01 15:11:12 -05:00
Lukas Werling
f0a1ab78b4 meson/ninja: add setup hooks (#28444)
* Add setupHook for meson/ninja build

* libhttpseverywhere: Use meson/ninja setupHooks

* jamomacore: Remove superfluous ninja buildInput

* Remove obsolete ninja buildPhases

These are all handled by ninja's setup hook.

* lean2, xcbuild: fix build with ninja setup hook

Ninja is a runtime dependency here. However, cmake can generate Ninja
build files as well to satisfy the setup hook.

* qtwebengine: fix build with ninja setup hook
2017-08-27 19:42:21 +02:00
Matthew Bauer
3d1d805245
Revert "xcbuild: try to fix sdk not found"
This reverts commit 87e6b2c50f.
2017-04-12 05:20:33 -05:00
Matthew Bauer
d697e5c8ee
ibtool: rename xib2nib 2017-04-12 03:23:28 -05:00
Matthew Bauer
f6860a6685
xcbuild: remove unnecessary flags 2017-04-12 03:21:58 -05:00
Matthew Bauer
87e6b2c50f
xcbuild: try to fix sdk not found
This is an attempt to get rid of the issues with sdk not found in
xcbuild when building pinentry_mac.
2017-04-09 04:27:56 -05:00
Matthew Bauer
34422f428d
ibtool: add to toolchain
- init package
- add into xcbuild/toolchain.nix
2017-04-09 04:27:21 -05:00
Matthew Bauer
5eb75ce205
xcbuild: add app bundle specs 2017-04-09 04:22:08 -05:00
Daniel Peebles
9e95fb05c5 Fix typo
I should learn to type properly 🙃
2017-03-22 12:33:37 -04:00
Dan Peebles
3263d02626 xcbuild: assorted fixes and cleanups
This is in preparation for the LLVM 4 upgrade (which gets more strict
about e.g., return false in xcbuild itself) and also for using xcbuild
more extensively in the Darwin stdenv bootstrap process, which is why I
killed the unnecessary gcc dependency in the toolchain. llvm-cov pretends
to be gcov anyway, so we're fine.
2017-03-21 23:22:15 -04:00
John Wiegley
6bbddcf7d1
xcbuild: Guard a glibc-only postPatch with \!isDarwin 2017-02-23 11:32:52 -08:00
Vladimír Čunát
fe8aa284c2
xcbuild: fixup build with glibc-2.25 2017-02-22 16:58:45 +01:00
Matthew Justin Bauer
10cfe945fe xcbuild: 0ab861ab -> 0.1.1 (#21895)
* xcbuild: add xcode-select wrapper
* xcbuild: update to 0.1.1
2017-01-19 22:21:00 +01:00
Daiderd Jordan
6e26fe3d57
xcbuild: add meta 2016-12-15 18:07:54 +01:00
Matthew Bauer
fc1f6f55ea
xcbuild: Get rid of developer.nix, move to wrapper
also:

- add custom outputs "specs" for xcbuild
- get rid of unneeded tools
- update xcbuild
- add more comments
- fixup xcbuild derivations

Affected xcbuild derivations include:

- adv_cmds
- network_cmds
- basic_cmds
2016-11-15 19:13:23 -06:00
Matthew Bauer
437bdc5e4b
xcbuild: fix toolchain on Linux 2016-11-15 19:13:22 -06:00
Matthew Bauer
0b6bfa49d5
xcbuild: Move extra specs to platform 2016-11-15 19:13:05 -06:00
Matthew Bauer
25485ece2a
xcbuild: add name to platform.nix 2016-11-15 18:58:13 -06:00
Matthew Bauer
1ee8685ee7
adv_cmds: add custom install phase 2016-11-15 18:58:10 -06:00
Matthew Bauer
78c3acc2ee
xcbuild: Add install phase
This phase is disabled for now but we can use it later.
2016-11-15 18:58:10 -06:00
Matthew Bauer
f1897116d0
xcbuild: temporarily fix cflags/ldflags
This gets everything to build.

adv_cmds: remove NIX_LDFLAGS

- unneeded
2016-11-15 18:58:09 -06:00
Matthew Bauer
ebf963ac6c
xcbuild: Update toolchain
- Rework spec files.
- Add more tool specs.
- Add ctags.
2016-11-15 18:58:09 -06:00
Matthew Bauer
44ad052c43
xcbuild: Make "xcbuild.raw" for original unwrapped 2016-11-15 18:58:08 -06:00
Matthew Bauer
de87138b9a
xcbuild: add wrapper
Also updates xcbuild version.

This changes the raw string expressions into nix expressions that are
then converted into json by builtins.toJSON. Then, converted to Plist
XML by Apple's plutil. Sadly, xcbuild does not support using raw JSON
but Apple's plutil does so we just convert the file from JSON to XML
using Apple's plutil. The result is not ideal but it looks like all OS X
systems have working plutil's.

- set mac version to 10.10
- add setup hook.
2016-11-15 18:57:20 -06:00
Dan Peebles
9617f61164 xcbuild: init at 49f8a592 2016-10-13 00:32:19 -04:00