Merge remote-tracking branch 'upstream/staging' into HEAD
This commit is contained in:
commit
804285f589
@ -187,7 +187,7 @@
|
||||
How does this work in practice? Nixpkgs is now structured so that build-time dependencies are taken from <varname>buildPackages</varname>, whereas run-time dependencies are taken from the top level attribute set.
|
||||
For example, <varname>buildPackages.gcc</varname> should be used at build time, while <varname>gcc</varname> should be used at run time.
|
||||
Now, for most of Nixpkgs's history, there was no <varname>buildPackages</varname>, and most packages have not been refactored to use it explicitly.
|
||||
Instead, one can use the four attributes used for specifying dependencies as documented in <xref linkend="ssec-stdenv-attributes"/>.
|
||||
Instead, one can use the six (<emphasis>gasp</emphasis>) attributes used for specifying dependencies as documented in <xref linkend="ssec-stdenv-dependencies"/>.
|
||||
We "splice" together the run-time and build-time package sets with <varname>callPackage</varname>, and then <varname>mkDerivation</varname> for each of four attributes pulls the right derivation out.
|
||||
This splicing can be skipped when not cross compiling as the package sets are the same, but is a bit slow for cross compiling.
|
||||
Because of this, a best-of-both-worlds solution is in the works with no splicing or explicit access of <varname>buildPackages</varname> needed.
|
||||
@ -200,6 +200,45 @@
|
||||
</para></note>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<title>Cross packagaing cookbook</title>
|
||||
<para>
|
||||
Some frequently problems when packaging for cross compilation are good to just spell and answer.
|
||||
Ideally the information above is exhaustive, so this section cannot provide any new information,
|
||||
but its ludicrous and cruel to expect everyone to spend effort working through the interaction of many features just to figure out the same answer to the same common problem.
|
||||
Feel free to add to this list!
|
||||
</para>
|
||||
<qandaset>
|
||||
<qandaentry>
|
||||
<question><para>
|
||||
What if my package's build system needs to build a C program to be run under the build environment?
|
||||
</para></question>
|
||||
<answer><para>
|
||||
<programlisting>depsBuildBuild = [ buildPackages.stdenv.cc ];</programlisting>
|
||||
Add it to your <function>mkDerivation</function> invocation.
|
||||
</para></answer>
|
||||
</qandaentry>
|
||||
<qandaentry>
|
||||
<question><para>
|
||||
My package fails to find <command>ar</command>.
|
||||
</para></question>
|
||||
<answer><para>
|
||||
Many packages assume that an unprefixed <command>ar</command> is available, but Nix doesn't provide one.
|
||||
It only provides a prefixed one, just as it only does for all the other binutils programs.
|
||||
It may be necessary to patch the package to fix the build system to use a prefixed `ar`.
|
||||
</para></answer>
|
||||
</qandaentry>
|
||||
<qandaentry>
|
||||
<question><para>
|
||||
My package's testsuite needs to run host platform code.
|
||||
</para></question>
|
||||
<answer><para>
|
||||
<programlisting>doCheck = stdenv.hostPlatform != stdenv.buildPlatfrom;</programlisting>
|
||||
Add it to your <function>mkDerivation</function> invocation.
|
||||
</para></answer>
|
||||
</qandaentry>
|
||||
</qandaset>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
<!--============================================================-->
|
||||
|
387
doc/stdenv.xml
387
doc/stdenv.xml
@ -179,6 +179,269 @@ genericBuild
|
||||
</section>
|
||||
|
||||
|
||||
<section xml:id="ssec-stdenv-dependencies"><title>Specifying dependencies</title>
|
||||
|
||||
<para>
|
||||
As described in the Nix manual, almost any <filename>*.drv</filename> store path in a derivation's attribute set will induce a dependency on that derivation.
|
||||
<varname>mkDerivation</varname>, however, takes a few attributes intended to, between them, include all the dependencies of a package.
|
||||
This is done both for structure and consistency, but also so that certain other setup can take place.
|
||||
For example, certain dependencies need their bin directories added to the <envar>PATH</envar>.
|
||||
That is built-in, but other setup is done via a pluggable mechanism that works in conjunction with these dependency attributes.
|
||||
See <xref linkend="ssec-setup-hooks"/> for details.
|
||||
</para>
|
||||
<para>
|
||||
Dependencies can be broken down along three axes: their host and target platforms relative to the new derivation's, and whether they are propagated.
|
||||
The platform distinctions are motivated by cross compilation; see <xref linkend="chap-cross"/> for exactly what each platform means.
|
||||
<footnote><para>
|
||||
The build platform is ignored because it is a mere implementation detail of the package satisfying the dependency:
|
||||
As a general programming principle, dependencies are always <emphasis>specified</emphasis> as interfaces, not concrete implementation.
|
||||
</para></footnote>
|
||||
But even if one is not cross compiling, the platforms imply whether or not the dependency is needed at run-time or build-time, a concept that makes perfect sense outside of cross compilation.
|
||||
For now, the run-time/build-time distinction is just a hint for mental clarity, but in the future it perhaps could be enforced.
|
||||
</para>
|
||||
<para>
|
||||
The extension of <envar>PATH</envar> with dependencies, alluded to above, proceeds according to the relative platforms alone.
|
||||
The process is carried out only for dependencies whose host platform matches the new derivation's build platform–i.e. which run on the platform where the new derivation will be built.
|
||||
<footnote><para>
|
||||
Currently, that means for native builds all dependencies are put on the <envar>PATH</envar>.
|
||||
But in the future that may not be the case for sake of matching cross:
|
||||
the platforms would be assumed to be unique for native and cross builds alike, so only the <varname>depsBuild*</varname> and <varname>nativeBuildDependencies</varname> dependencies would affect the <envar>PATH</envar>.
|
||||
</para></footnote>
|
||||
For each dependency <replaceable>dep</replaceable> of those dependencies, <filename><replaceable>dep</replaceable>/bin</filename>, if present, is added to the <envar>PATH</envar> environment variable.
|
||||
</para>
|
||||
<para>
|
||||
The dependency is propagated when it forces some of its other-transitive (non-immediate) downstream dependencies to also take it on as an immediate dependency.
|
||||
Nix itself already takes a package's transitive dependencies into account, but this propagation ensures nixpkgs-specific infrastructure like setup hooks (mentioned above) also are run as if the propagated dependency.
|
||||
</para>
|
||||
<para>
|
||||
It is important to note dependencies are not necessary propagated as the same sort of dependency that they were before, but rather as the corresponding sort so that the platform rules still line up.
|
||||
The exact rules for dependency propagation can be given by assigning each sort of dependency two integers based one how it's host and target platforms are offset from the depending derivation's platforms.
|
||||
Those offsets are given are given below in the descriptions of each dependency list attribute.
|
||||
Algorithmically, we traverse propagated inputs, accumulating every propagated dep's propagated deps and adjusting them to account for the "shift in perspective" described by the current dep's platform offsets.
|
||||
This results in sort a transitive closure of the dependency relation, with the offsets being approximately summed when two dependency links are combined.
|
||||
We also prune transitive deps whose combined offsets go out-of-bounds, which can be viewed as a filter over that transitive closure removing dependencies that are blatantly absurd.
|
||||
</para>
|
||||
<para>
|
||||
We can define the process precisely with <link xlink:href="https://en.wikipedia.org/wiki/Natural_deduction">Natural Deduction</link> using the inference rules.
|
||||
This probably seems a bit obtuse, but so is the bash code that actually implements it!
|
||||
<footnote><para>
|
||||
The <function>findInputs</function> function, currently residing in <filename>pkgs/stdenv/generic/setup.sh</filename>, implements the propagation logic.
|
||||
</para></footnote>
|
||||
They're confusing in very different ways so...hopefully if something doesn't make sense in one presentation, it does in the other!
|
||||
<programlisting>
|
||||
let mapOffset(h, t, i) = i + (if i <= 0 then h else t - 1)
|
||||
|
||||
propagated-dep(h0, t0, A, B)
|
||||
propagated-dep(h1, t1, B, C)
|
||||
h0 + h1 in {-1, 0, 1}
|
||||
h0 + t1 in {-1, 0, 1}
|
||||
-------------------------------------- Transitive property
|
||||
propagated-dep(mapOffset(h0, t0, h1),
|
||||
mapOffset(h0, t0, t1),
|
||||
A, C)</programlisting>
|
||||
<programlisting>
|
||||
let mapOffset(h, t, i) = i + (if i <= 0 then h else t - 1)
|
||||
|
||||
dep(h0, _, A, B)
|
||||
propagated-dep(h1, t1, B, C)
|
||||
h0 + h1 in {-1, 0, 1}
|
||||
h0 + t1 in {-1, 0, -1}
|
||||
-------------------------------------- Take immediate deps' propagated deps
|
||||
propagated-dep(mapOffset(h0, t0, h1),
|
||||
mapOffset(h0, t0, t1),
|
||||
A, C)</programlisting>
|
||||
<programlisting>
|
||||
propagated-dep(h, t, A, B)
|
||||
-------------------------------------- Propagated deps count as deps
|
||||
dep(h, t, A, B)</programlisting>
|
||||
Some explanation of this monstrosity is in order.
|
||||
In the common case, the target offset of a dependency is the successor to the target offset: <literal>t = h + 1</literal>.
|
||||
That means that:
|
||||
<programlisting>
|
||||
let f(h, t, i) = i + (if i <= 0 then h else t - 1)
|
||||
let f(h, h + 1, i) = i + (if i <= 0 then h else (h + 1) - 1)
|
||||
let f(h, h + 1, i) = i + (if i <= 0 then h else h)
|
||||
let f(h, h + 1, i) = i + h
|
||||
</programlisting>
|
||||
This is where the "sum-like" comes from above:
|
||||
We can just sum all the host offset to get the host offset of the transitive dependency.
|
||||
The target offset is the transitive dep is simply the host offset + 1, just as it was with the dependencies composed to make this transitive one;
|
||||
it can be ignored as it doesn't add any new information.
|
||||
</para>
|
||||
<para>
|
||||
Because of the bounds checks, the uncommon cases are <literal>h = t</literal> and <literal>h + 2 = t</literal>.
|
||||
In the former case, the motivation for <function>mapOffset</function> is that since its host and target platforms are the same, no transitive dep of it should be able to "discover" an offset greater than its reduced target offsets.
|
||||
<function>mapOffset</function> effectively "squashes" all its transitive dependencies' offsets so that none will ever be greater than the target offset of the original <literal>h = t</literal> package.
|
||||
In the other case, <literal>h + 1</literal> is skipped over between the host and target offsets.
|
||||
Instead of squashing the offsets, we need to "rip" them apart so no transitive dependencies' offset is that one.
|
||||
</para>
|
||||
<para>
|
||||
Overall, the unifying theme here is that propagation shouldn't be introducing transitive dependencies involving platforms the needing package is unaware of.
|
||||
The offset bounds checking and definition of <function>mapOffset</function> together ensure that this is the case.
|
||||
Discovering a new offset is discovering a new platform, and since those platforms weren't in the derivation "spec" of the needing package, they cannot be relevant.
|
||||
From a capability perspective, we can imagine that the host and target platforms of a package are the capabilities a package requires, and the depending package must provide the capability to the dependency.
|
||||
</para>
|
||||
|
||||
<variablelist>
|
||||
<title>Variables specifying dependencies</title>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>depsBuildBuild</varname></term>
|
||||
<listitem>
|
||||
<para>
|
||||
A list of dependencies whose host and target platforms are the new derivation's build platform.
|
||||
This means a <literal>-1</literal> host and <literal>-1</literal> target offset from the new derivation's platforms.
|
||||
They are programs/libraries used at build time that furthermore produce programs/libraries also used at build time.
|
||||
If the dependency doesn't care about the target platform (i.e. isn't a compiler or similar tool), put it in <varname>nativeBuildInputs</varname>instead.
|
||||
The most common use for this <literal>buildPackages.stdenv.cc</literal>, the default C compiler for this role.
|
||||
That example crops up more than one might think in old commonly used C libraries.
|
||||
</para>
|
||||
<para>
|
||||
Since these packages are able to be run at build time, that are always added to the <envar>PATH</envar>, as described above.
|
||||
But since these packages are only guaranteed to be able to run then, they shouldn't persist as run-time dependencies.
|
||||
This isn't currently enforced, but could be in the future.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>nativeBuildInputs</varname></term>
|
||||
<listitem>
|
||||
<para>
|
||||
A list of dependencies whose host platform is the new derivation's build platform, and target platform is the new derivation's host platform.
|
||||
This means a <literal>-1</literal> host offset and <literal>0</literal> target offset from the new derivation's platforms.
|
||||
They are programs/libraries used at build time that, if they are a compiler or similar tool, produce code to run at run time—i.e. tools used to build the new derivation.
|
||||
If the dependency doesn't care about the target platform (i.e. isn't a compiler or similar tool), put it here, rather than in <varname>depsBuildBuild</varname> or <varname>depsBuildTarget</varname>.
|
||||
This would be called <varname>depsBuildHost</varname> but for historical continuity.
|
||||
</para>
|
||||
<para>
|
||||
Since these packages are able to be run at build time, that are added to the <envar>PATH</envar>, as described above.
|
||||
But since these packages only are guaranteed to be able to run then, they shouldn't persist as run-time dependencies.
|
||||
This isn't currently enforced, but could be in the future.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>depsBuildTarget</varname></term>
|
||||
<listitem>
|
||||
<para>
|
||||
A list of dependencies whose host platform is the new derivation's build platform, and target platform is the new derivation's target platform.
|
||||
This means a <literal>-1</literal> host offset and <literal>1</literal> target offset from the new derivation's platforms.
|
||||
They are programs used at build time that produce code to run at run with code produced by the depending package.
|
||||
Most commonly, these would tools used to build the runtime or standard library the currently-being-built compiler will inject into any code it compiles.
|
||||
In many cases, the currently-being built compiler is itself employed for that task, but when that compiler won't run (i.e. its build and host platform differ) this is not possible.
|
||||
Other times, the compiler relies on some other tool, like binutils, that is always built separately so the dependency is unconditional.
|
||||
</para>
|
||||
<para>
|
||||
This is a somewhat confusing dependency to wrap ones head around, and for good reason.
|
||||
As the only one where the platform offsets are not adjacent integers, it requires thinking of a bootstrapping stage <emphasis>two</emphasis> away from the current one.
|
||||
It and it's use-case go hand in hand and are both considered poor form:
|
||||
try not to need this sort dependency, and try not avoid building standard libraries / runtimes in the same derivation as the compiler produces code using them.
|
||||
Instead strive to build those like a normal library, using the newly-built compiler just as a normal library would.
|
||||
In short, do not use this attribute unless you are packaging a compiler and are sure it is needed.
|
||||
</para>
|
||||
<para>
|
||||
Since these packages are able to be run at build time, that are added to the <envar>PATH</envar>, as described above.
|
||||
But since these packages only are guaranteed to be able to run then, they shouldn't persist as run-time dependencies.
|
||||
This isn't currently enforced, but could be in the future.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>depsHostHost</varname></term>
|
||||
<listitem><para>
|
||||
A list of dependencies whose host and target platforms match the new derivation's host platform.
|
||||
This means a both <literal>0</literal> host offset and <literal>0</literal> target offset from the new derivation's host platform.
|
||||
These are packages used at run-time to generate code also used at run-time.
|
||||
In practice, that would usually be tools used by compilers for metaprogramming/macro systems, or libraries used by the macros/metaprogramming code itself.
|
||||
It's always preferable to use a <varname>depsBuildBuild</varname> dependency in the derivation being built than a <varname>depsHostHost</varname> on the tool doing the building for this purpose.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>buildInputs</varname></term>
|
||||
<listitem>
|
||||
<para>
|
||||
A list of dependencies whose host platform and target platform match the new derivation's.
|
||||
This means a <literal>0</literal> host offset and <literal>1</literal> target offset from the new derivation's host platform.
|
||||
This would be called <varname>depsHostTarget</varname> but for historical continuity.
|
||||
If the dependency doesn't care about the target platform (i.e. isn't a compiler or similar tool), put it here, rather than in <varname>depsBuildBuild</varname>.
|
||||
</para>
|
||||
<para>
|
||||
These often are programs/libraries used by the new derivation at <emphasis>run</emphasis>-time, but that isn't always the case.
|
||||
For example, the machine code in a statically linked library is only used at run time, but the derivation containing the library is only needed at build time.
|
||||
Even in the dynamic case, the library may also be needed at build time to appease the linker.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>depsTargetTarget</varname></term>
|
||||
<listitem><para>
|
||||
A list of dependencies whose host platform matches the new derivation's target platform.
|
||||
This means a <literal>1</literal> offset from the new derivation's platforms.
|
||||
These are packages that run on the target platform, e.g. the standard library or run-time deps of standard library that a compiler insists on knowing about.
|
||||
It's poor form in almost all cases for a package to depend on another from a future stage [future stage corresponding to positive offset].
|
||||
Do not use this attribute unless you are packaging a compiler and are sure it is needed.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>depsBuildBuildPropagated</varname></term>
|
||||
<listitem><para>
|
||||
The propagated equivalent of <varname>depsBuildBuild</varname>.
|
||||
This perhaps never ought to be used, but it is included for consistency [see below for the others].
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>propagatedNativeBuildInputs</varname></term>
|
||||
<listitem><para>
|
||||
The propagated equivalent of <varname>nativeBuildInputs</varname>.
|
||||
This would be called <varname>depsBuildHostPropagated</varname> but for historical continuity.
|
||||
For example, if package <varname>Y</varname> has <literal>propagatedNativeBuildInputs = [X]</literal>, and package <varname>Z</varname> has <literal>buildInputs = [Y]</literal>, then package <varname>Z</varname> will be built as if it included package <varname>X</varname> in its <varname>nativeBuildInputs</varname>.
|
||||
If instead, package <varname>Z</varname> has <literal>nativeBuildInputs = [Y]</literal>, then <varname>Z</varname> will be built as if it included <varname>X</varname> in the <varname>depsBuildBuild</varname> of package <varname>Z</varname>, because of the sum of the two <literal>-1</literal> host offsets.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>depsBuildTargetPropagated</varname></term>
|
||||
<listitem><para>
|
||||
The propagated equivalent of <varname>depsBuildTarget</varname>.
|
||||
This is prefixed for the same reason of alerting potential users.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>depsHostHostPropagated</varname></term>
|
||||
<listitem><para>
|
||||
The propagated equivalent of <varname>depsHostHost</varname>.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>propagatedBuildInputs</varname></term>
|
||||
<listitem><para>
|
||||
The propagated equivalent of <varname>buildInputs</varname>.
|
||||
This would be called <varname>depsHostTargetPropagated</varname> but for historical continuity.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>depsTargetTarget</varname></term>
|
||||
<listitem><para>
|
||||
The propagated equivalent of <varname>depsTargetTarget</varname>.
|
||||
This is prefixed for the same reason of alerting potential users.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
</variablelist>
|
||||
|
||||
</section>
|
||||
|
||||
|
||||
<section xml:id="ssec-stdenv-attributes"><title>Attributes</title>
|
||||
|
||||
<variablelist>
|
||||
@ -198,54 +461,6 @@ genericBuild
|
||||
|
||||
</variablelist>
|
||||
|
||||
<variablelist>
|
||||
<title>Variables specifying dependencies</title>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>nativeBuildInputs</varname></term>
|
||||
<listitem><para>
|
||||
A list of dependencies used by the new derivation at <emphasis>build</emphasis>-time.
|
||||
I.e. these dependencies should not make it into the package's runtime-closure, though this is currently not checked.
|
||||
For each dependency <replaceable>dir</replaceable>, the directory <filename><replaceable>dir</replaceable>/bin</filename>, if it exists, is added to the <envar>PATH</envar> environment variable.
|
||||
Other environment variables are also set up via a pluggable mechanism.
|
||||
For instance, if <varname>buildInputs</varname> contains Perl, then the <filename>lib/site_perl</filename> subdirectory of each input is added to the <envar>PERL5LIB</envar> environment variable.
|
||||
See <xref linkend="ssec-setup-hooks"/> for details.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>buildInputs</varname></term>
|
||||
<listitem><para>
|
||||
A list of dependencies used by the new derivation at <emphasis>run</emphasis>-time.
|
||||
Currently, the build-time environment is modified in the exact same way as with <varname>nativeBuildInputs</varname>.
|
||||
This is problematic in that when cross-compiling, foreign executables can clobber native ones on the <envar>PATH</envar>.
|
||||
Even more confusing is static-linking.
|
||||
A statically-linked library should be listed here because ultimately that generated machine code will be used at run-time, even though a derivation containing the object files or static archives will only be used at build-time.
|
||||
A less confusing solution to this would be nice.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>propagatedNativeBuildInputs</varname></term>
|
||||
<listitem><para>
|
||||
Like <varname>nativeBuildInputs</varname>, but these dependencies are <emphasis>propagated</emphasis>:
|
||||
that is, the dependencies listed here are added to the <varname>nativeBuildInputs</varname> of any package that uses <emphasis>this</emphasis> package as a dependency.
|
||||
So if package Y has <literal>propagatedNativeBuildInputs = [X]</literal>, and package Z has <literal>nativeBuildInputs = [Y]</literal>,
|
||||
then package X will appear in Z’s build environment automatically.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>propagatedBuildInputs</varname></term>
|
||||
<listitem><para>
|
||||
Like <varname>buildInputs</varname>, but propagated just like <varname>propagatedNativeBuildInputs</varname>.
|
||||
This inherits <varname>buildInputs</varname>'s flaws of clobbering native executables when cross-compiling and being confusing for static linking.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
</variablelist>
|
||||
|
||||
<variablelist>
|
||||
<title>Variables affecting build properties</title>
|
||||
|
||||
@ -656,7 +871,7 @@ script) if it exists.</para>
|
||||
By default, when cross compiling, the configure script has <option>--build=...</option> and <option>--host=...</option> passed.
|
||||
Packages can instead pass <literal>[ "build" "host" "target" ]</literal> or a subset to control exactly which platform flags are passed.
|
||||
Compilers and other tools should use this to also pass the target platform, for example.
|
||||
Note eventually these will be passed when in native builds too, to improve determinism: build-time guessing, as is done today, is a risk of impurity.
|
||||
<footnote><para>Eventually these will be passed when in native builds too, to improve determinism: build-time guessing, as is done today, is a risk of impurity.</para></footnote>
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
@ -923,6 +1138,20 @@ following:
|
||||
<listitem><para>If set, libraries and executables are not
|
||||
stripped. By default, they are.</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term><varname>dontStripHost</varname></term>
|
||||
<listitem><para>
|
||||
Like <varname>dontStripHost</varname>, but only affects the <command>strip</command> command targetting the package's host platform.
|
||||
Useful when supporting cross compilation, but otherwise feel free to ignore.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term><varname>dontStripTarget</varname></term>
|
||||
<listitem><para>
|
||||
Like <varname>dontStripHost</varname>, but only affects the <command>strip</command> command targetting the packages' target platform.
|
||||
Useful when supporting cross compilation, but otherwise feel free to ignore.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>dontMoveSbin</varname></term>
|
||||
@ -1353,8 +1582,55 @@ someVar=$(stripHash $name)
|
||||
|
||||
<section xml:id="ssec-setup-hooks"><title>Package setup hooks</title>
|
||||
|
||||
<para>The following packages provide a setup hook:
|
||||
|
||||
<para>
|
||||
Nix itself considers a build-time dependency merely something that should previously be built and accessible at build time—packages themselves are on their own to perform any additional setup.
|
||||
In most cases, that is fine, and the downstream derivation can deal with it's own dependencies.
|
||||
But for a few common tasks, that would result in almost every package doing the same sort of setup work---depending not on the package itself, but entirely on which dependencies were used.
|
||||
</para>
|
||||
<para>
|
||||
In order to alleviate this burden, the <firstterm>setup hook></firstterm>mechanism was written, where any package can include a shell script that [by convention rather than enforcement by Nix], any downstream reverse-dependency will source as part of its build process.
|
||||
That allows the downstream dependency to merely specify its dependencies, and lets those dependencies effectively initialize themselves.
|
||||
No boilerplate mirroring the list of dependencies is needed.
|
||||
</para>
|
||||
<para>
|
||||
The Setup hook mechanism is a bit of a sledgehammer though: a powerful feature with a broad and indiscriminate area of effect.
|
||||
The combination of its power and implicit use may be expedient, but isn't without costs.
|
||||
Nix itself is unchanged, but the spirit of adding dependencies being effect-free is violated even if the letter isn't.
|
||||
For example, if a derivation path is mentioned more than once, Nix itself doesn't care and simply makes sure the dependency derivation is already built just the same—depending is just needing something to exist, and needing is idempotent.
|
||||
However, a dependency specified twice will have its setup hook run twice, and that could easily change the build environment (though a well-written setup hook will therefore strive to be idempotent so this is in fact not observable).
|
||||
More broadly, setup hooks are anti-modular in that multiple dependencies, whether the same or different, should not interfere and yet their setup hooks may well do so.
|
||||
</para>
|
||||
<para>
|
||||
The most typical use of the setup hook is actually to add other hooks which are then run (i.e. after all the setup hooks) on each dependency.
|
||||
For example, the C compiler wrapper's setup hook feeds itself flags for each dependency that contains relevant libaries and headers.
|
||||
This is done by defining a bash function, and appending its name to one of
|
||||
<envar>envBuildBuildHooks</envar>`,
|
||||
<envar>envBuildHostHooks</envar>`,
|
||||
<envar>envBuildTargetHooks</envar>`,
|
||||
<envar>envHostHostHooks</envar>`,
|
||||
<envar>envHostTargetHooks</envar>`, or
|
||||
<envar>envTargetTargetHooks</envar>`.
|
||||
These 6 bash variables correspond to the 6 sorts of dependencies by platform (there's 12 total but we ignore the propagated/non-propagated axis).
|
||||
</para>
|
||||
<para>
|
||||
Packages adding a hook should not hard code a specific hook, but rather choose a variable <emphasis>relative</emphasis> to how they are included.
|
||||
Returning to the C compiler wrapper example, if it itself is an <literal>n</literal> dependency, then it only wants to accumulate flags from <literal>n + 1</literal> dependencies, as only those ones match the compiler's target platform.
|
||||
The <envar>hostOffset</envar> variable is defined with the current dependency's host offset <envar>targetOffset</envar> with its target offset, before it's setup hook is sourced.
|
||||
Additionally, since most environment hooks don't care about the target platform,
|
||||
That means the setup hook can append to the right bash array by doing something like
|
||||
<programlisting language="bash">
|
||||
addEnvHooks "$hostOffset" myBashFunction
|
||||
</programlisting>
|
||||
</para>
|
||||
<para>
|
||||
The <emphasis>existence</emphasis> of setups hooks has long been documented and packages inside Nixpkgs are free to use these mechanism.
|
||||
Other packages, however, should not rely on these mechanisms not changing between Nixpkgs versions.
|
||||
Because of the existing issues with this system, there's little benefit from mandating it be stable for any period of time.
|
||||
</para>
|
||||
<para>
|
||||
Here are some packages that provide a setup hook.
|
||||
Since the mechanism is modular, this probably isn't an exhaustive list.
|
||||
Then again, since the mechanism is only to be used as a last resort, it might be.
|
||||
<variablelist>
|
||||
|
||||
<varlistentry>
|
||||
@ -1421,9 +1697,12 @@ someVar=$(stripHash $name)
|
||||
|
||||
<varlistentry>
|
||||
<term>Perl</term>
|
||||
<listitem><para>Adds the <filename>lib/site_perl</filename> subdirectory
|
||||
of each build input to the <envar>PERL5LIB</envar>
|
||||
environment variable.</para></listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
Adds the <filename>lib/site_perl</filename> subdirectory of each build input to the <envar>PERL5LIB</envar> environment variable.
|
||||
For instance, if <varname>buildInputs</varname> contains Perl, then the <filename>lib/site_perl</filename> subdirectory of each input is added to the <envar>PERL5LIB</envar> environment variable.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
|
@ -20,6 +20,22 @@ has the following highlights: </para>
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para>
|
||||
MariaDB 10.2, updated from 10.1, is now the default MySQL implementation. While upgrading a few changes
|
||||
have been made to the infrastructure involved:
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>libmysql</literal> has been deprecated, please use <literal>mysql.connector-c</literal>
|
||||
instead, a compatibility passthru has been added to the MySQL packages.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
The <literal>mysql57</literal> package has a new <literal>static</literal> output containing
|
||||
the static libraries including <literal>libmysqld.a</literal>
|
||||
</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
@ -103,6 +119,18 @@ following incompatible changes:</para>
|
||||
Other more obscure ones are just moved.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
The propagation logic has been changed.
|
||||
The new logic, along with new types of dependencies that go with, is thoroughly documented in the "Specifying dependencies" section of the "Standard Environment" chapter of the nixpkgs manual.
|
||||
<!-- That's <xref linkend="ssec-stdenv-attributes"> were we to merge the manuals. -->
|
||||
The old logic isn't but is easy to describe: dependencies were propagated as the same type of dependency no matter what.
|
||||
In practice, that means that many <function>propagatedNativeBuildInputs</function> should instead be <function>propagatedBuildInputs</function>.
|
||||
Thankfully, that was and is the least used type of dependency.
|
||||
Also, it means that some <function>propagatedBuildInputs</function> should instead be <function>depsTargetTargetPropagated</function>.
|
||||
Other types dependencies should be unaffected.
|
||||
</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
|
||||
</section>
|
||||
|
@ -65,7 +65,7 @@
|
||||
foldingathome = 37;
|
||||
sabnzbd = 38;
|
||||
#kdm = 39; # dropped in 17.03
|
||||
ghostone = 40;
|
||||
#ghostone = 40; # dropped in 18.03
|
||||
git = 41;
|
||||
fourstore = 42;
|
||||
fourstorehttp = 43;
|
||||
@ -348,7 +348,7 @@
|
||||
#foldingathome = 37; # unused
|
||||
#sabnzd = 38; # unused
|
||||
#kdm = 39; # unused, even before 17.03
|
||||
ghostone = 40;
|
||||
#ghostone = 40; # dropped in 18.03
|
||||
git = 41;
|
||||
fourstore = 42;
|
||||
fourstorehttp = 43;
|
||||
|
@ -220,7 +220,6 @@
|
||||
./services/editors/emacs.nix
|
||||
./services/editors/infinoted.nix
|
||||
./services/games/factorio.nix
|
||||
./services/games/ghost-one.nix
|
||||
./services/games/minecraft-server.nix
|
||||
./services/games/minetest-server.nix
|
||||
./services/games/terraria.nix
|
||||
|
@ -7,14 +7,12 @@ let
|
||||
cfg = config.services.mysql;
|
||||
|
||||
mysql = cfg.package;
|
||||
|
||||
isMariaDB =
|
||||
|
||||
isMariaDB =
|
||||
let
|
||||
pName = _p: (builtins.parseDrvName (_p.name)).name;
|
||||
in pName mysql == pName pkgs.mariadb;
|
||||
|
||||
atLeast55 = versionAtLeast mysql.mysqlVersion "5.5";
|
||||
|
||||
pidFile = "${cfg.pidDir}/mysqld.pid";
|
||||
|
||||
mysqldOptions =
|
||||
@ -28,13 +26,6 @@ let
|
||||
${optionalString (cfg.bind != null) "bind-address = ${cfg.bind}" }
|
||||
${optionalString (cfg.replication.role == "master" || cfg.replication.role == "slave") "log-bin=mysql-bin"}
|
||||
${optionalString (cfg.replication.role == "master" || cfg.replication.role == "slave") "server-id = ${toString cfg.replication.serverId}"}
|
||||
${optionalString (cfg.replication.role == "slave" && !atLeast55)
|
||||
''
|
||||
master-host = ${cfg.replication.masterHost}
|
||||
master-user = ${cfg.replication.masterUser}
|
||||
master-password = ${cfg.replication.masterPassword}
|
||||
master-port = ${toString cfg.replication.masterPort}
|
||||
''}
|
||||
${optionalString (cfg.ensureUsers != [])
|
||||
''
|
||||
plugin-load-add = auth_socket.so
|
||||
@ -315,7 +306,7 @@ in
|
||||
fi
|
||||
'') cfg.initialDatabases}
|
||||
|
||||
${optionalString (cfg.replication.role == "master" && atLeast55)
|
||||
${optionalString (cfg.replication.role == "master")
|
||||
''
|
||||
# Set up the replication master
|
||||
|
||||
@ -326,7 +317,7 @@ in
|
||||
) | ${mysql}/bin/mysql -u root -N
|
||||
''}
|
||||
|
||||
${optionalString (cfg.replication.role == "slave" && atLeast55)
|
||||
${optionalString (cfg.replication.role == "slave")
|
||||
''
|
||||
# Set up the replication slave
|
||||
|
||||
|
@ -1,105 +0,0 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
with lib;
|
||||
let
|
||||
|
||||
cfg = config.services.ghostOne;
|
||||
ghostUser = "ghostone";
|
||||
stateDir = "/var/lib/ghost-one";
|
||||
|
||||
in
|
||||
{
|
||||
|
||||
###### interface
|
||||
|
||||
options = {
|
||||
services.ghostOne = {
|
||||
|
||||
enable = mkOption {
|
||||
default = false;
|
||||
description = "Enable Ghost-One Warcraft3 game hosting server.";
|
||||
};
|
||||
|
||||
language = mkOption {
|
||||
default = "English";
|
||||
type = types.enum [ "English" "Spanish" "Russian" "Serbian" "Turkish" ];
|
||||
description = "The language of bot messages: English, Spanish, Russian, Serbian or Turkish.";
|
||||
};
|
||||
|
||||
war3path = mkOption {
|
||||
default = "";
|
||||
description = ''
|
||||
The path to your local Warcraft III directory, which must contain war3.exe, storm.dll, and game.dll.
|
||||
'';
|
||||
};
|
||||
|
||||
mappath = mkOption {
|
||||
default = "";
|
||||
description = ''
|
||||
The path to the directory where you keep your map files. GHost One doesn't require
|
||||
map files but if it has access to them it can send them to players and automatically
|
||||
calculate most map config values. GHost One will search [bot_mappath + map_localpath]
|
||||
for the map file (map_localpath is set in each map's config file).
|
||||
'';
|
||||
};
|
||||
|
||||
config = mkOption {
|
||||
default = "";
|
||||
description = "Extra configuration options.";
|
||||
};
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
###### implementation
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
users.extraUsers = singleton
|
||||
{ name = ghostUser;
|
||||
uid = config.ids.uids.ghostone;
|
||||
description = "Ghost One game server user";
|
||||
home = stateDir;
|
||||
};
|
||||
|
||||
users.extraGroups = singleton
|
||||
{ name = ghostUser;
|
||||
gid = config.ids.gids.ghostone;
|
||||
};
|
||||
|
||||
services.ghostOne.config = ''
|
||||
# bot_log = /dev/stderr
|
||||
bot_language = ${pkgs.ghostOne}/share/ghost-one/languages/${cfg.language}.cfg
|
||||
bot_war3path = ${cfg.war3path}
|
||||
|
||||
bot_mapcfgpath = mapcfgs
|
||||
bot_savegamepath = savegames
|
||||
bot_mappath = ${cfg.mappath}
|
||||
bot_replaypath = replays
|
||||
'';
|
||||
|
||||
systemd.services."ghost-one" = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
script = ''
|
||||
mkdir -p ${stateDir}
|
||||
cd ${stateDir}
|
||||
chown ${ghostUser}:${ghostUser} .
|
||||
|
||||
mkdir -p mapcfgs
|
||||
chown ${ghostUser}:${ghostUser} mapcfgs
|
||||
|
||||
mkdir -p replays
|
||||
chown ${ghostUser}:${ghostUser} replays
|
||||
|
||||
mkdir -p savegames
|
||||
chown ${ghostUser}:${ghostUser} savegames
|
||||
|
||||
ln -sf ${pkgs.writeText "ghost.cfg" cfg.config} ghost.cfg
|
||||
ln -sf ${pkgs.ghostOne}/share/ghost-one/ip-to-country.csv
|
||||
${pkgs.su}/bin/su -s ${pkgs.stdenv.shell} ${ghostUser} \
|
||||
-c "LANG=C ${pkgs.ghostOne}/bin/ghost++"
|
||||
'';
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
}
|
@ -3,7 +3,7 @@
|
||||
, qca-qt5, qjson, qtscript, qtwebkit
|
||||
, kcmutils, kconfig, kdelibs4support, kdnssd, kinit, knewstuff, knotifyconfig, ktexteditor
|
||||
, phonon, plasma-framework, threadweaver
|
||||
, curl, ffmpeg, gdk_pixbuf, libaio, libmtp, loudmouth, lzo, lz4, mariadb, pcre, snappy, taglib, taglib_extras
|
||||
, curl, ffmpeg, gdk_pixbuf, libaio, libmtp, loudmouth, lzo, lz4, mysql57, pcre, snappy, taglib, taglib_extras
|
||||
}:
|
||||
|
||||
let
|
||||
@ -26,7 +26,8 @@ in mkDerivation {
|
||||
qca-qt5 qjson qtscript qtwebkit
|
||||
kcmutils kconfig kdelibs4support kdnssd kinit knewstuff knotifyconfig ktexteditor
|
||||
phonon plasma-framework threadweaver
|
||||
curl ffmpeg gdk_pixbuf libaio libmtp loudmouth lz4 lzo mariadb pcre snappy taglib taglib_extras
|
||||
curl ffmpeg gdk_pixbuf libaio libmtp loudmouth lz4 lzo mysql57.server mysql57.server.static
|
||||
pcre snappy taglib taglib_extras
|
||||
];
|
||||
enableParallelBuilding = true;
|
||||
|
||||
|
@ -4,15 +4,15 @@
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "grass-7.0.2";
|
||||
name = "grass-7.2.2";
|
||||
src = fetchurl {
|
||||
url = http://grass.osgeo.org/grass70/source/grass-7.0.2.tar.gz;
|
||||
sha256 = "02qrdgn46gxr60amxwax4b8fkkmhmjxi6qh4yfvpbii6ai6diarf";
|
||||
url = http://grass.osgeo.org/grass72/source/grass-7.2.2.tar.gz;
|
||||
sha256 = "0yzljbrxlqp4wbw08n1dvmm4vmwkg8glf1ff4xyh589r5ryb7gxv";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkgconfig ];
|
||||
buildInputs = [ flex bison zlib proj gdal libtiff libpng fftw sqlite cairo
|
||||
readline ffmpeg makeWrapper wxGTK30 netcdf geos postgresql mysql.client blas ]
|
||||
readline ffmpeg makeWrapper wxGTK30 netcdf geos postgresql mysql.connector-c blas ]
|
||||
++ (with python2Packages; [ python dateutil wxPython30 numpy ]);
|
||||
|
||||
configureFlags = [
|
||||
@ -22,9 +22,12 @@ stdenv.mkDerivation {
|
||||
"--with-wxwidgets"
|
||||
"--with-netcdf"
|
||||
"--with-geos"
|
||||
"--with-postgres" "--with-postgres-libs=${postgresql.lib}/lib/"
|
||||
"--with-postgres"
|
||||
"--with-postgres-libs=${postgresql.lib}/lib/"
|
||||
# it complains about missing libmysqld but doesn't really seem to need it
|
||||
"--with-mysql" "--with-mysql-includes=${stdenv.lib.getDev mysql.client}/include/mysql"
|
||||
"--with-mysql"
|
||||
"--with-mysql-includes=${mysql.connector-c}/include/mysql"
|
||||
"--with-mysql-libs=${mysql.connector-c}/lib/mysql"
|
||||
"--with-blas"
|
||||
];
|
||||
|
||||
@ -40,17 +43,20 @@ stdenv.mkDerivation {
|
||||
scripts/r.pack/r.pack.py \
|
||||
scripts/r.tileset/r.tileset.py \
|
||||
scripts/r.unpack/r.unpack.py \
|
||||
scripts/v.krige/v.krige.py \
|
||||
scripts/v.rast.stats/v.rast.stats.py \
|
||||
scripts/v.to.lines/v.to.lines.py \
|
||||
scripts/v.what.strds/v.what.strds.py \
|
||||
scripts/v.unpack/v.unpack.py \
|
||||
scripts/wxpyimgview/*.py \
|
||||
gui/wxpython/animation/g.gui.animation.py \
|
||||
gui/wxpython/datacatalog/g.gui.datacatalog.py \
|
||||
gui/wxpython/rlisetup/g.gui.rlisetup.py \
|
||||
gui/wxpython/vdigit/g.gui.vdigit.py \
|
||||
temporal/t.rast.accumulate/t.rast.accumulate.py \
|
||||
temporal/t.rast.accdetect/t.rast.accdetect.py \
|
||||
temporal/t.rast.algebra/t.rast.algebra.py \
|
||||
temporal/t.rast3d.algebra/t.rast3d.algebra.py \
|
||||
temporal/t.vect.algebra/t.vect.algebra.py \
|
||||
temporal/t.select/t.select.py
|
||||
for d in gui lib scripts temporal tools; do
|
||||
patchShebangs $d
|
||||
@ -58,7 +64,7 @@ stdenv.mkDerivation {
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
wrapProgram $out/bin/grass70 \
|
||||
wrapProgram $out/bin/grass72 \
|
||||
--set PYTHONPATH $PYTHONPATH \
|
||||
--set GRASS_PYTHON ${python2Packages.python}/bin/${python2Packages.python.executable} \
|
||||
--suffix LD_LIBRARY_PATH ':' '${gdal}/lib'
|
||||
@ -72,6 +78,5 @@ stdenv.mkDerivation {
|
||||
description = "GIS software suite used for geospatial data management and analysis, image processing, graphics and maps production, spatial modeling, and visualization";
|
||||
license = stdenv.lib.licenses.gpl2Plus;
|
||||
platforms = stdenv.lib.platforms.all;
|
||||
broken = true;
|
||||
};
|
||||
}
|
||||
|
@ -75,7 +75,6 @@ mkDerivation rec {
|
||||
libqtav
|
||||
libusb1
|
||||
mesa
|
||||
mysql
|
||||
opencv3
|
||||
pcre
|
||||
|
||||
|
@ -10,7 +10,7 @@ mkDerivation {
|
||||
license = [ lib.licenses.lgpl21 ];
|
||||
maintainers = kdepimTeam;
|
||||
};
|
||||
nativeBuildInputs = [ extra-cmake-modules ki18n ];
|
||||
buildInputs = [ kcodecs qtbase ];
|
||||
nativeBuildInputs = [ extra-cmake-modules ];
|
||||
buildInputs = [ kcodecs ki18n qtbase ];
|
||||
outputs = [ "out" "dev" ];
|
||||
}
|
||||
|
@ -8,8 +8,8 @@ mkDerivation {
|
||||
license = with licenses; [ gpl2 lgpl21 bsd3 ];
|
||||
maintainers = with maintainers; [ peterhoeg ];
|
||||
};
|
||||
nativeBuildInputs = [ extra-cmake-modules ];
|
||||
buildInputs = [ qtbase kdoctools ];
|
||||
nativeBuildInputs = [ extra-cmake-modules kdoctools ];
|
||||
buildInputs = [ qtbase ];
|
||||
propagatedBuildInputs = [
|
||||
kcodecs ki18n kio kwidgetsaddons
|
||||
libmusicbrainz5
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, fetchFromGitHub, pkgconfig, gtk3, vala, cmake, vte, libgee, wnck, zssh, gettext, librsvg, libsecret, json_glib }:
|
||||
{ stdenv, fetchurl, fetchFromGitHub, pkgconfig, gtk3, vala, cmake, vte, libgee, wnck, zssh, gettext, librsvg, libsecret, json_glib, gobjectIntrospection }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "deepin-terminal-${version}";
|
||||
@ -25,7 +25,11 @@ stdenv.mkDerivation rec {
|
||||
substituteInPlace ssh_login.sh --replace /usr/lib/deepin-terminal/zssh "${zssh}/bin/zssh"
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [ pkgconfig vala cmake gettext ];
|
||||
nativeBuildInputs = [
|
||||
pkgconfig vala cmake gettext
|
||||
# For setup hook
|
||||
gobjectIntrospection
|
||||
];
|
||||
buildInputs = [ gtk3 vte libgee wnck librsvg libsecret json_glib ];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
|
@ -1,6 +1,6 @@
|
||||
{ stdenv, fetchFromGitHub, makeWrapper, automake, autoconf, libtool,
|
||||
{ stdenv, fetchFromGitHub, automake, autoconf, libtool,
|
||||
pkgconfig, file, intltool, libxml2, json_glib , sqlite, itstool,
|
||||
librsvg, vala_0_34, gnome3, wrapGAppsHook
|
||||
librsvg, vala_0_34, gnome3, wrapGAppsHook, gobjectIntrospection
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
@ -15,7 +15,6 @@ stdenv.mkDerivation rec {
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
makeWrapper
|
||||
pkgconfig
|
||||
automake autoconf libtool
|
||||
file
|
||||
@ -23,6 +22,8 @@ stdenv.mkDerivation rec {
|
||||
vala_0_34
|
||||
gnome3.yelp_tools
|
||||
wrapGAppsHook
|
||||
# For setup hook
|
||||
gobjectIntrospection
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
|
@ -1,15 +1,17 @@
|
||||
{ stdenv, fetchurl, pythonPackages }:
|
||||
{ stdenv, fetchurl, python }:
|
||||
|
||||
pythonPackages.buildPythonApplication rec {
|
||||
version = "0.4.2";
|
||||
name = "haxor-news-${version}";
|
||||
with python.pkgs;
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/donnemartin/haxor-news/archive/${version}.tar.gz";
|
||||
sha256 = "0543k5ys044f2a1q8k36djnnq2h2dffnwbkva9snjjy30nlwwdgs";
|
||||
buildPythonApplication rec {
|
||||
pname = "haxor-news";
|
||||
version = "0.4.3";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "5b9af8338a0f8b95a8133b66ef106553823813ac171c0aefa3f3f2dbeb4d7f88";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = with pythonPackages; [
|
||||
propagatedBuildInputs = [
|
||||
click
|
||||
colorama
|
||||
requests
|
||||
@ -18,6 +20,12 @@ pythonPackages.buildPythonApplication rec {
|
||||
six
|
||||
];
|
||||
|
||||
checkInputs = [ mock ];
|
||||
|
||||
checkPhase = ''
|
||||
${python.interpreter} -m unittest discover -s tests -v
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
homepage = https://github.com/donnemartin/haxor-news;
|
||||
description = "Browse Hacker News like a haxor";
|
||||
|
@ -3,6 +3,7 @@
|
||||
, fetchurl
|
||||
, intltool
|
||||
, python3Packages
|
||||
, gobjectIntrospection
|
||||
, gtk3
|
||||
, dbus
|
||||
, libwnck3
|
||||
@ -22,7 +23,11 @@ buildPythonApplication rec {
|
||||
sha256 = "0c9xjx13r8ckfr4az116bhxsd3pk78v04c3lz6lqhraak0rp4d92";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ wrapGAppsHook intltool ];
|
||||
nativeBuildInputs = [
|
||||
wrapGAppsHook intltool
|
||||
# For setup hook
|
||||
gobjectIntrospection
|
||||
];
|
||||
buildInputs = [ hicolor_icon_theme docutils libwnck3 keybinder3 ];
|
||||
propagatedBuildInputs = [ pygobject3 gtk3 pyxdg dbus-python pycairo ];
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
{ stdenv, fetchFromGitHub, cmake, makeWrapper, pkgconfig, vala, gtk3, libgee
|
||||
, poppler, libpthreadstubs, gstreamer, gst-plugins-base, librsvg, pcre }:
|
||||
, poppler, libpthreadstubs, gstreamer, gst-plugins-base, librsvg, pcre, gobjectIntrospection }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "${product}-${version}";
|
||||
@ -13,7 +13,11 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "00qfmmk8h762p53z46g976z7j4fbxyi16w5axzsv1ymvdq95ds8c";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake pkgconfig vala ];
|
||||
nativeBuildInputs = [
|
||||
cmake pkgconfig vala
|
||||
# For setup hook
|
||||
gobjectIntrospection
|
||||
];
|
||||
buildInputs = [ gstreamer gst-plugins-base gtk3 libgee poppler
|
||||
libpthreadstubs makeWrapper librsvg pcre ];
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
{ stdenv, fetchurl, intltool, pkgconfig, glib, libnotify, gtk3, libgee
|
||||
, keybinder3, json_glib, zeitgeist, vala_0_34, hicolor_icon_theme
|
||||
, keybinder3, json_glib, zeitgeist, vala_0_34, hicolor_icon_theme, gobjectIntrospection
|
||||
}:
|
||||
|
||||
let
|
||||
@ -12,7 +12,11 @@ in stdenv.mkDerivation rec {
|
||||
sha256 = "04cnsmwf9xa52dh7rpb4ia715c0ls8jg1p7llc9yf3lbg1m0bvzv";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkgconfig intltool vala_0_34 ];
|
||||
nativeBuildInputs = [
|
||||
pkgconfig intltool vala_0_34
|
||||
# For setup hook
|
||||
gobjectIntrospection
|
||||
];
|
||||
buildInputs = [
|
||||
glib libnotify gtk3 libgee keybinder3 json_glib zeitgeist
|
||||
hicolor_icon_theme
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchFromGitHub, cmake, gtk3, vala, pkgconfig, gnome3 }:
|
||||
{ stdenv, fetchFromGitHub, cmake, gtk3, vala, pkgconfig, gnome3, gobjectIntrospection }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "1.3.1";
|
||||
@ -11,8 +11,12 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "18969v870737jg1q0l3d05pb9mxsrcpdi0mnyz94rwkspszvxxqi";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkgconfig ];
|
||||
buildInputs = [ cmake gtk3 vala gnome3.libgee ];
|
||||
nativeBuildInputs = [
|
||||
cmake vala pkgconfig
|
||||
# For setup hook
|
||||
gobjectIntrospection
|
||||
];
|
||||
buildInputs = [ gtk3 gnome3.libgee ];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "A fast dmenu-like gtk3 application launcher";
|
||||
|
@ -22,9 +22,9 @@ stdenv.mkDerivation rec {
|
||||
|
||||
configureFlags = [ "--enable-widec" ] ++ stdenv.lib.optional sslSupport "--with-ssl";
|
||||
|
||||
nativeBuildInputs = stdenv.lib.optional sslSupport pkgconfig
|
||||
++ stdenv.lib.optional (hostPlatform != buildPlatform) buildPackages.stdenv.cc
|
||||
++ [ nukeReferences ];
|
||||
depsBuildBuild = [ buildPackages.stdenv.cc ];
|
||||
nativeBuildInputs = [ nukeReferences ]
|
||||
++ stdenv.lib.optional sslSupport pkgconfig;
|
||||
|
||||
buildInputs = [ ncurses gzip ] ++ stdenv.lib.optional sslSupport openssl.dev;
|
||||
|
||||
|
@ -4,7 +4,7 @@
|
||||
breeze-icons, karchive, kcodecs, kcompletion, kconfig, kconfigwidgets, kcoreaddons,
|
||||
kcrash, kguiaddons, ki18n, kiconthemes, kitemviews, kio, ktexteditor, ktextwidgets,
|
||||
kwidgetsaddons, kxmlgui,
|
||||
kdb, kproperty, kreport, lcms2, libmysql, marble, postgresql
|
||||
kdb, kproperty, kreport, lcms2, mysql, marble, postgresql
|
||||
}:
|
||||
|
||||
mkDerivation rec {
|
||||
@ -24,7 +24,7 @@ mkDerivation rec {
|
||||
breeze-icons karchive kcodecs kcompletion kconfig kconfigwidgets kcoreaddons
|
||||
kcrash kguiaddons ki18n kiconthemes kitemviews kio ktexteditor ktextwidgets
|
||||
kwidgetsaddons kxmlgui
|
||||
kdb kproperty kreport lcms2 libmysql marble postgresql
|
||||
kdb kproperty kreport lcms2 mysql.connector-c marble postgresql
|
||||
];
|
||||
|
||||
propagatedUserEnvPkgs = [ kproperty ];
|
||||
|
@ -14,9 +14,12 @@ mkDerivation rec {
|
||||
sha256 = "1dbvdrkdpgv39v8h7k3mri0nzlslfyd5kk410czj0jdn4qq400md";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake extra-cmake-modules shared_mime_info ];
|
||||
nativeBuildInputs = [
|
||||
cmake extra-cmake-modules kdoctools shared_mime_info
|
||||
];
|
||||
|
||||
buildInputs = [ qtwebkit qtscript grantlee kxmlgui kwallet kparts kdoctools
|
||||
buildInputs = [
|
||||
qtwebkit qtscript grantlee kxmlgui kwallet kparts
|
||||
kjobwidgets kdesignerplugin kiconthemes knewstuff sqlcipher qca-qt5
|
||||
kactivities karchive kguiaddons knotifyconfig krunner kwindowsystem libofx
|
||||
];
|
||||
|
@ -1,13 +1,14 @@
|
||||
{ stdenv, pythonPackages }:
|
||||
{ stdenv, pythonPackages, fetchpatch }:
|
||||
|
||||
pythonPackages.buildPythonApplication rec {
|
||||
with pythonPackages;
|
||||
|
||||
buildPythonApplication rec {
|
||||
pname = "td-watson";
|
||||
name = "${pname}-${version}";
|
||||
version = "1.4.0";
|
||||
version = "1.5.2";
|
||||
|
||||
src = pythonPackages.fetchPypi {
|
||||
src = fetchPypi {
|
||||
inherit version pname;
|
||||
sha256 = "1py0g4990jmvq0dn7jasda7f10kzr41bix46hnbyc1rshjzc17hq";
|
||||
sha256 = "6e03d44a9278807fe5245e9ed0943f13ffb88e11249a02655c84cb86260b27c8";
|
||||
};
|
||||
|
||||
# uses tox, test invocation fails
|
||||
@ -15,8 +16,16 @@ pythonPackages.buildPythonApplication rec {
|
||||
checkPhase = ''
|
||||
py.test -vs tests
|
||||
'';
|
||||
checkInputs = with pythonPackages; [ py pytest pytest-datafiles mock pytest-mock pytestrunner ];
|
||||
propagatedBuildInputs = with pythonPackages; [ requests click arrow ];
|
||||
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
url = https://github.com/TailorDev/Watson/commit/f5760c71cbc22de4e12ede8f6f7257515a9064d3.patch;
|
||||
sha256 = "0s9h26915ilpbd0qhmvk77r3gmrsdrl5l7dqxj0l5q66fp0z6b0g";
|
||||
})
|
||||
];
|
||||
|
||||
checkInputs = [ py pytest pytest-datafiles mock pytest-mock pytestrunner ];
|
||||
propagatedBuildInputs = [ requests click arrow ];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
homepage = https://tailordev.github.io/Watson/;
|
||||
@ -24,4 +33,4 @@ pythonPackages.buildPythonApplication rec {
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ mguentner ] ;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
@ -60,7 +60,7 @@ stdenv.mkDerivation {
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks=(''${envHooks[@]} addCoqPath)
|
||||
addEnvHooks "$targetOffset" addCoqPath
|
||||
'';
|
||||
|
||||
passthru = {
|
||||
|
@ -110,7 +110,7 @@ self = stdenv.mkDerivation {
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks=(''${envHooks[@]} addCoqPath)
|
||||
addEnvHooks "$targetOffset" addCoqPath
|
||||
'';
|
||||
|
||||
preConfigure = ''
|
||||
|
@ -1,5 +1,7 @@
|
||||
addRLibPath () {
|
||||
addToSearchPath R_LIBS_SITE $1/library
|
||||
if [[ -d "$1/library" ]]; then
|
||||
addToSearchPath R_LIBS_SITE "$1/library"
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks+=(addRLibPath)
|
||||
addEnvHooks "$targetOffset" addRLibPath
|
||||
|
@ -10,7 +10,7 @@ stdenv.mkDerivation {
|
||||
sha256 = "0w8xxfnw2snflz8wdr2ca9f5g91w5vbyp1hwlx1v7vg83d4bwqs7";
|
||||
};
|
||||
|
||||
buildInputs = [ freeglut mesa mysql.lib mpfr gmp
|
||||
buildInputs = [ freeglut mesa mysql.connector-c mpfr gmp
|
||||
libtiff libjpeg libpng giflib ]
|
||||
++ (with ocamlPackages; [
|
||||
ocaml findlib ocaml_mysql lablgl camlimages_4_0 mlgmpidl
|
||||
|
@ -130,7 +130,7 @@ in stdenv.mkDerivation rec {
|
||||
libmpeg2 libsamplerate libmad
|
||||
libogg libvorbis flac libxslt systemd
|
||||
lzo libcdio libmodplug libass libbluray
|
||||
sqlite mysql.lib avahi lame
|
||||
sqlite mysql.connector-c avahi lame
|
||||
curl bzip2 zip unzip glxinfo xdpyinfo
|
||||
libcec libcec_platform dcadec libuuid
|
||||
libgcrypt libgpgerror libunistring
|
||||
|
@ -102,7 +102,8 @@ stdenv.mkDerivation rec {
|
||||
rm -rf ffmpeg
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [ buildPackages.stdenv.cc pkgconfig yasm ];
|
||||
depsBuildBuild = [ buildPackages.stdenv.cc ];
|
||||
nativeBuildInputs = [ pkgconfig yasm ];
|
||||
buildInputs = with stdenv.lib;
|
||||
[ freetype ffmpeg ]
|
||||
++ optional aalibSupport aalib
|
||||
|
@ -164,7 +164,21 @@ stdenv.mkDerivation {
|
||||
set +u
|
||||
'';
|
||||
|
||||
propagatedBuildInputs = extraPackages;
|
||||
emulation = let
|
||||
fmt =
|
||||
/**/ if targetPlatform.isDarwin then "mach-o"
|
||||
else if targetPlatform.isWindows then "pe"
|
||||
else "elf" + toString targetPlatform.parsed.cpu.bits;
|
||||
endianPrefix = if targetPlatform.isBigEndian then "big" else "little";
|
||||
arch =
|
||||
/**/ if targetPlatform.isAarch64 then endianPrefix + "aarch64"
|
||||
else if targetPlatform.isArm then endianPrefix + "arm"
|
||||
else if targetPlatform.isx86_64 then "x86-64"
|
||||
else if targetPlatform.isi686 then "i386"
|
||||
else throw "unknown emulation for platform: " + targetPlatform.config;
|
||||
in targetPlatform.platform.bfdEmulation or (fmt + "-" + arch);
|
||||
|
||||
depsTargetTargetPropagated = extraPackages;
|
||||
|
||||
setupHook = ./setup-hook.sh;
|
||||
|
||||
|
@ -67,6 +67,11 @@ fi
|
||||
|
||||
extraAfter+=($NIX_@infixSalt@_LDFLAGS_AFTER)
|
||||
|
||||
# Specify the target emulation if nothing is passed in ("-m" overrides this
|
||||
# environment variable). Ensures we never blindly fallback on targeting the host
|
||||
# platform.
|
||||
: ${LDEMULATION:=@emulation@}
|
||||
|
||||
# Three tasks:
|
||||
#
|
||||
# 1. Find all -L... switches for rpath
|
||||
|
@ -2,12 +2,20 @@
|
||||
#
|
||||
# See comments in cc-wrapper's setup hook. This works exactly the same way.
|
||||
|
||||
set -u
|
||||
|
||||
# Skip setup hook if we're neither a build-time dep, nor, temporarily, doing a
|
||||
# native compile.
|
||||
#
|
||||
# TODO(@Ericson2314): No native exception
|
||||
[[ -z ${crossConfig-} ]] || (( "$hostOffset" < 0 )) || return 0
|
||||
|
||||
bintoolsWrapper_addLDVars () {
|
||||
case $depOffset in
|
||||
case $depHostOffset in
|
||||
-1) local role='BUILD_' ;;
|
||||
0) local role='' ;;
|
||||
1) local role='TARGET_' ;;
|
||||
*) echo "bintools-wrapper: Error: Cannot be used with $depOffset-offset deps, " >2;
|
||||
*) echo "bintools-wrapper: Error: Cannot be used with $depHostOffset-offset deps" >2;
|
||||
return 1 ;;
|
||||
esac
|
||||
|
||||
@ -20,17 +28,29 @@ bintoolsWrapper_addLDVars () {
|
||||
fi
|
||||
}
|
||||
|
||||
if [ -n "${crossConfig:-}" ]; then
|
||||
export NIX_BINTOOLS_WRAPPER_@infixSalt@_TARGET_BUILD=1
|
||||
role_pre='BUILD_'
|
||||
role_post='_FOR_BUILD'
|
||||
else
|
||||
export NIX_BINTOOLS_WRAPPER_@infixSalt@_TARGET_HOST=1
|
||||
role_pre=""
|
||||
role_post=''
|
||||
fi
|
||||
case $targetOffset in
|
||||
-1)
|
||||
export NIX_BINTOOLS_WRAPPER_@infixSalt@_TARGET_BUILD=1
|
||||
role_pre='BUILD_'
|
||||
role_post='_FOR_BUILD'
|
||||
;;
|
||||
0)
|
||||
export NIX_BINTOOLS_WRAPPER_@infixSalt@_TARGET_HOST=1
|
||||
role_pre=''
|
||||
role_post=''
|
||||
;;
|
||||
1)
|
||||
export NIX_BINTOOLS_WRAPPER_@infixSalt@_TARGET_TARGET=1
|
||||
role_pre='TARGET_'
|
||||
role_post='_FOR_TARGET'
|
||||
;;
|
||||
*)
|
||||
echo "cc-wrapper: used as improper sort of dependency" >2;
|
||||
return 1
|
||||
;;
|
||||
esac
|
||||
|
||||
envHooks+=(bintoolsWrapper_addLDVars)
|
||||
addEnvHooks "$targetOffset" bintoolsWrapper_addLDVars
|
||||
|
||||
# shellcheck disable=SC2157
|
||||
if [ -n "@bintools_bin@" ]; then
|
||||
@ -65,3 +85,4 @@ done
|
||||
|
||||
# No local scope in sourced file
|
||||
unset -v role_pre role_post cmd upper_case
|
||||
set +u
|
||||
|
@ -201,7 +201,8 @@ stdenv.mkDerivation {
|
||||
ln -s $ccPath/${targetPrefix}ghdl $out/bin/${targetPrefix}ghdl
|
||||
'';
|
||||
|
||||
propagatedBuildInputs = [ bintools ] ++ extraPackages;
|
||||
propagatedBuildInputs = [ bintools ];
|
||||
depsTargetTargetPropagated = extraPackages;
|
||||
|
||||
setupHook = ./setup-hook.sh;
|
||||
|
||||
|
@ -54,19 +54,26 @@
|
||||
# For more details, read the individual files where the mechanisms used to
|
||||
# accomplish this will be individually documented.
|
||||
|
||||
set -u
|
||||
|
||||
# Skip setup hook if we're neither a build-time dep, nor, temporarily, doing a
|
||||
# native compile.
|
||||
#
|
||||
# TODO(@Ericson2314): No native exception
|
||||
[[ -z ${crossConfig-} ]] || (( "$hostOffset" < 0 )) || return 0
|
||||
|
||||
# It's fine that any other cc-wrapper will redefine this. Bash functions close
|
||||
# over no state, and there's no @-substitutions within, so any redefined
|
||||
# function is guaranteed to be exactly the same.
|
||||
ccWrapper_addCVars () {
|
||||
# The `depOffset` describes how the platforms of the dependencies are slid
|
||||
# relative to the depending package. It is brought into scope of the
|
||||
# environment hook defined as the role of the dependency being applied.
|
||||
case $depOffset in
|
||||
# The `depHostOffset` describes how the host platform of the dependencies
|
||||
# are slid relative to the depending package. It is brought into scope of
|
||||
# the environment hook defined as the role of the dependency being applied.
|
||||
case $depHostOffset in
|
||||
-1) local role='BUILD_' ;;
|
||||
0) local role='' ;;
|
||||
1) local role='TARGET_' ;;
|
||||
*) echo "cc-wrapper: Error: Cannot be used with $depOffset-offset deps, " >2;
|
||||
*) echo "cc-wrapper: Error: Cannot be used with $depHostOffset-offset deps" >2;
|
||||
return 1 ;;
|
||||
esac
|
||||
|
||||
@ -87,20 +94,31 @@ ccWrapper_addCVars () {
|
||||
#
|
||||
# We also need to worry about what role is being added on *this* invocation of
|
||||
# setup-hook, which `role` tracks.
|
||||
if [ -n "${crossConfig:-}" ]; then
|
||||
export NIX_CC_WRAPPER_@infixSalt@_TARGET_BUILD=1
|
||||
role_pre='BUILD_'
|
||||
role_post='_FOR_BUILD'
|
||||
else
|
||||
export NIX_CC_WRAPPER_@infixSalt@_TARGET_HOST=1
|
||||
role_pre=''
|
||||
role_post=''
|
||||
fi
|
||||
case $targetOffset in
|
||||
-1)
|
||||
export NIX_CC_WRAPPER_@infixSalt@_TARGET_BUILD=1
|
||||
role_pre='BUILD_'
|
||||
role_post='_FOR_BUILD'
|
||||
;;
|
||||
0)
|
||||
export NIX_CC_WRAPPER_@infixSalt@_TARGET_HOST=1
|
||||
role_pre=''
|
||||
role_post=''
|
||||
;;
|
||||
1)
|
||||
export NIX_CC_WRAPPER_@infixSalt@_TARGET_TARGET=1
|
||||
role_pre='TARGET_'
|
||||
role_post='_FOR_TARGET'
|
||||
;;
|
||||
*)
|
||||
echo "cc-wrapper: used as improper sort of dependency" >2;
|
||||
return 1
|
||||
;;
|
||||
esac
|
||||
|
||||
# Eventually the exact sort of env-hook we create will depend on the role. This
|
||||
# is because based on what relative platform we are targeting, we use different
|
||||
# dependencies.
|
||||
envHooks+=(ccWrapper_addCVars)
|
||||
# We use the `targetOffset` to choose the right env hook to accumulate the right
|
||||
# sort of deps (those with that offset).
|
||||
addEnvHooks "$targetOffset" ccWrapper_addCVars
|
||||
|
||||
# Note 1: these come *after* $out in the PATH (see setup.sh).
|
||||
# Note 2: phase separation makes this look useless to shellcheck.
|
||||
@ -131,3 +149,4 @@ export CXX${role_post}=@named_cxx@
|
||||
|
||||
# No local scope in sourced file
|
||||
unset -v role_pre role_post
|
||||
set +u
|
||||
|
@ -4,4 +4,8 @@ addEmacsVars () {
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks+=(addEmacsVars)
|
||||
# If this is for a wrapper derivation, emacs and the dependencies are all
|
||||
# run-time dependencies. If this is for precompiling packages into bytecode,
|
||||
# emacs is a compile-time dependency of the package.
|
||||
addEnvHooks "$targetOffset" addEmacsVars
|
||||
addEnvHooks "$targetOffset" addEmacsVars
|
||||
|
@ -1,4 +1,4 @@
|
||||
addCVars () {
|
||||
gccWrapperOld_addCVars () {
|
||||
if test -d $1/include; then
|
||||
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -isystem $1/include"
|
||||
fi
|
||||
@ -12,7 +12,7 @@ addCVars () {
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks=(${envHooks[@]} addCVars)
|
||||
envBuildBuildHooks+=(gccWrapperOld_addCVars)
|
||||
|
||||
# Note: these come *after* $out in the PATH (see setup.sh).
|
||||
|
||||
|
@ -18,5 +18,5 @@ if [ -z "$libxmlHookDone" ]; then
|
||||
# xmllint and xsltproc from looking in /etc/xml/catalog.
|
||||
export XML_CATALOG_FILES
|
||||
if [ -z "$XML_CATALOG_FILES" ]; then XML_CATALOG_FILES=" "; fi
|
||||
envHooks+=(addXMLCatalogs)
|
||||
addEnvHooks "$hostOffset" addXMLCatalogs
|
||||
fi
|
||||
|
@ -10,4 +10,4 @@ addPkgToClassPath () {
|
||||
done
|
||||
}
|
||||
|
||||
envHooks+=(addPkgToClassPath)
|
||||
addEnvHooks "$targetOffset" addPkgToClassPath
|
||||
|
@ -2,4 +2,4 @@ setupDebugInfoDirs () {
|
||||
addToSearchPath NIX_DEBUG_INFO_DIRS $1/lib/debug
|
||||
}
|
||||
|
||||
envHooks+=(setupDebugInfoDirs)
|
||||
addEnvHooks "$targetOffset" setupDebugInfoDirs
|
||||
|
@ -3,24 +3,45 @@
|
||||
fixupOutputHooks+=(_doStrip)
|
||||
|
||||
_doStrip() {
|
||||
if [ -z "$dontStrip" ]; then
|
||||
# We don't bother to strip build platform code because it shouldn't make it
|
||||
# to $out anyways---if it does, that's a bigger problem that a lack of
|
||||
# stripping will help catch.
|
||||
local -ra flags=(dontStripHost dontStripTarget)
|
||||
local -ra stripCmds=(STRIP TARGET_STRIP)
|
||||
|
||||
# Optimization
|
||||
if [[ "$STRIP" == "$TARGET_STRIP" ]]; then
|
||||
dontStripTarget+=1
|
||||
fi
|
||||
|
||||
local i
|
||||
for i in ${!stripCmds[@]}; do
|
||||
local -n flag="${flags[$i]}"
|
||||
local -n stripCmd="${stripCmds[$i]}"
|
||||
|
||||
# `dontStrip` disables them all
|
||||
if [[ "$dontStrip" || "$flag" ]] || ! type -f "$stripCmd" 2>/dev/null
|
||||
then continue; fi
|
||||
|
||||
stripDebugList=${stripDebugList:-lib lib32 lib64 libexec bin sbin}
|
||||
if [ -n "$stripDebugList" ]; then
|
||||
stripDirs "$stripDebugList" "${stripDebugFlags:--S}"
|
||||
stripDirs "$stripCmd" "$stripDebugList" "${stripDebugFlags:--S}"
|
||||
fi
|
||||
|
||||
stripAllList=${stripAllList:-}
|
||||
if [ -n "$stripAllList" ]; then
|
||||
stripDirs "$stripAllList" "${stripAllFlags:--s}"
|
||||
stripDirs "$stripCmd" "$stripAllList" "${stripAllFlags:--s}"
|
||||
fi
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
stripDirs() {
|
||||
local dirs="$1"
|
||||
local stripFlags="$2"
|
||||
local cmd="$1"
|
||||
local dirs="$2"
|
||||
local stripFlags="$3"
|
||||
local dirsNew=
|
||||
|
||||
local d
|
||||
for d in ${dirs}; do
|
||||
if [ -d "$prefix/$d" ]; then
|
||||
dirsNew="${dirsNew} $prefix/$d "
|
||||
@ -29,8 +50,8 @@ stripDirs() {
|
||||
dirs=${dirsNew}
|
||||
|
||||
if [ -n "${dirs}" ]; then
|
||||
header "stripping (with flags $stripFlags) in$dirs"
|
||||
find $dirs -type f -print0 | xargs -0 ${xargsFlags:--r} $STRIP $commonStripFlags $stripFlags 2>/dev/null || true
|
||||
header "stripping (with command $cmd and flags $stripFlags) in$dirs"
|
||||
find $dirs -type f -print0 | xargs -0 ${xargsFlags:--r} $cmd $commonStripFlags $stripFlags 2>/dev/null || true
|
||||
stopNest
|
||||
fi
|
||||
}
|
||||
|
@ -6,7 +6,7 @@ find_gio_modules() {
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks+=(find_gio_modules)
|
||||
addEnvHooks "$targetOffset" find_gio_modules
|
||||
|
||||
# Note: $gappsWrapperArgs still gets defined even if $dontWrapGApps is set.
|
||||
wrapGAppsHook() {
|
||||
|
@ -8,7 +8,8 @@ hicolorIconThemeHook() {
|
||||
|
||||
}
|
||||
|
||||
envHooks+=(hicolorIconThemeHook)
|
||||
# I think this is meant to be a runtime dep
|
||||
addEnvHooks "$hostOffset" hicolorIconThemeHook
|
||||
|
||||
# Remove icon cache
|
||||
hicolorPreFixupPhase() {
|
||||
|
@ -1,12 +1,12 @@
|
||||
{ stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
|
||||
, intltool, gjs, gdk_pixbuf, librsvg }:
|
||||
, intltool, gobjectIntrospection, gjs, gdk_pixbuf, librsvg }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
inherit (import ./src.nix fetchurl) name src;
|
||||
|
||||
nativeBuildInputs = [ pkgconfig ];
|
||||
nativeBuildInputs = [ pkgconfig wrapGAppsHook intltool ];
|
||||
buildInputs = [
|
||||
gtk3 wrapGAppsHook intltool gjs gdk_pixbuf
|
||||
gtk3 gjs gdk_pixbuf gobjectIntrospection
|
||||
librsvg gnome3.gsettings_desktop_schemas gnome3.defaultIconTheme
|
||||
];
|
||||
|
||||
|
@ -1,10 +1,10 @@
|
||||
{ fetchurl, stdenv, gettext, pkgconfig, itstool, libxml2, libjpeg, gnome3
|
||||
, shared_mime_info, wrapGAppsHook, librsvg, libexif }:
|
||||
, shared_mime_info, wrapGAppsHook, librsvg, libexif, gobjectIntrospection }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
inherit (import ./src.nix fetchurl) name src;
|
||||
|
||||
nativeBuildInputs = [ pkgconfig gettext itstool wrapGAppsHook ];
|
||||
nativeBuildInputs = [ pkgconfig gettext itstool wrapGAppsHook gobjectIntrospection ];
|
||||
|
||||
buildInputs = with gnome3;
|
||||
[ libxml2 libjpeg gtk glib libpeas librsvg
|
||||
|
@ -1,5 +1,5 @@
|
||||
{ stdenv, fetchurl, pkgconfig, dbus_glib, gnome3 ? null, glib, libxml2
|
||||
, intltool, polkit, orbit, withGtk ? false }:
|
||||
, intltool, polkit, orbit, python, withGtk ? false }:
|
||||
|
||||
assert withGtk -> (gnome3 != null);
|
||||
|
||||
@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "0k3q9nh53yhc9qxf1zaicz4sk8p3kzq4ndjdsgpaa2db0ccbj4hr";
|
||||
};
|
||||
|
||||
buildInputs = [ libxml2 polkit orbit ] ++ stdenv.lib.optional withGtk gnome3.gtk;
|
||||
buildInputs = [ libxml2 polkit orbit python ] ++ stdenv.lib.optional withGtk gnome3.gtk;
|
||||
propagatedBuildInputs = [ glib dbus_glib ];
|
||||
nativeBuildInputs = [ pkgconfig intltool ];
|
||||
|
||||
|
@ -1,10 +1,10 @@
|
||||
{ stdenv, fetchurl, gnome3, meson, ninja, pkgconfig, gtk3, intltool, glib
|
||||
, udev, itstool, libxml2, wrapGAppsHook, libnotify, libcanberra_gtk3 }:
|
||||
, udev, itstool, libxml2, wrapGAppsHook, libnotify, libcanberra_gtk3, gobjectIntrospection }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
inherit (import ./src.nix fetchurl) name src;
|
||||
|
||||
nativeBuildInputs = [ meson ninja intltool itstool pkgconfig libxml2 wrapGAppsHook ];
|
||||
nativeBuildInputs = [ meson ninja intltool itstool pkgconfig libxml2 wrapGAppsHook gobjectIntrospection ];
|
||||
buildInputs = [ glib gtk3 udev libnotify libcanberra_gtk3
|
||||
gnome3.defaultIconTheme gnome3.gsettings_desktop_schemas ];
|
||||
|
||||
|
@ -4,4 +4,4 @@ make_grilo_find_plugins() {
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks+=(make_grilo_find_plugins)
|
||||
addEnvHooks "$hostOffset" make_grilo_find_plugins
|
||||
|
@ -1,7 +1,9 @@
|
||||
{ stdenv, fetchurl, pkgconfig, atk, cairo, glib, gtk3, pango
|
||||
, libxml2, perl, intltool, gettext, gnome3, dbus, xvfb_run, shared_mime_info }:
|
||||
, libxml2, perl, intltool, gettext, gnome3, gobjectIntrospection, dbus, xvfb_run, shared_mime_info }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
let
|
||||
checkInputs = [ xvfb_run dbus ];
|
||||
in stdenv.mkDerivation rec {
|
||||
inherit (import ./src.nix fetchurl) name src;
|
||||
|
||||
propagatedBuildInputs = [
|
||||
@ -13,10 +15,10 @@ stdenv.mkDerivation rec {
|
||||
|
||||
outputs = [ "out" "dev" ];
|
||||
|
||||
nativeBuildInputs = [ pkgconfig intltool gettext perl ]
|
||||
++ checkInputs;
|
||||
nativeBuildInputs = [ pkgconfig intltool gettext perl gobjectIntrospection ]
|
||||
++ stdenv.lib.optionals doCheck checkInputs;
|
||||
|
||||
buildInputs = [ atk cairo glib pango libxml2 ];
|
||||
checkInputs = stdenv.lib.optionals doCheck [ xvfb_run dbus ];
|
||||
|
||||
preBuild = ''
|
||||
substituteInPlace gtksourceview/gtksourceview-utils.c --replace "@NIX_SHARE_PATH@" "$out/share"
|
||||
|
@ -1,7 +1,7 @@
|
||||
{ stdenv, intltool, fetchurl, pkgconfig, gtk3
|
||||
, glib, desktop_file_utils, bash, appdata-tools
|
||||
, wrapGAppsHook, gnome3, itstool, libxml2
|
||||
, callPackage, unzip }:
|
||||
, callPackage, unzip, gobjectIntrospection }:
|
||||
|
||||
# TODO: icons and theme still does not work
|
||||
# use packaged gnome3.adwaita-icon-theme
|
||||
@ -15,11 +15,12 @@ stdenv.mkDerivation rec {
|
||||
|
||||
preConfigure = "patchShebangs gucharmap/gen-guch-unicode-tables.pl";
|
||||
|
||||
nativeBuildInputs = [ pkgconfig wrapGAppsHook unzip ];
|
||||
nativeBuildInputs = [
|
||||
pkgconfig wrapGAppsHook unzip intltool itstool appdata-tools
|
||||
gnome3.yelp_tools libxml2 desktop_file_utils gobjectIntrospection
|
||||
];
|
||||
|
||||
buildInputs = [ gtk3 intltool itstool glib appdata-tools
|
||||
gnome3.yelp_tools libxml2 desktop_file_utils
|
||||
gnome3.gsettings_desktop_schemas ];
|
||||
buildInputs = [ gtk3 glib gnome3.gsettings_desktop_schemas ];
|
||||
|
||||
unicode-data = callPackage ./unicode-data.nix {};
|
||||
|
||||
|
@ -8,7 +8,11 @@ stdenv.mkDerivation rec {
|
||||
configureFlags = [ "--enable-python3" ];
|
||||
|
||||
nativeBuildInputs = [ pkgconfig ];
|
||||
buildInputs = [ intltool glib gtk3 gnome3.defaultIconTheme ncurses python3Packages.python python3Packages.pygobject3 gobjectIntrospection ];
|
||||
buildInputs = [ intltool glib gtk3 gnome3.defaultIconTheme ncurses python3Packages.python python3Packages.pygobject3 ];
|
||||
propagatedBuildInputs = [
|
||||
# Required by libpeas-1.0.pc
|
||||
gobjectIntrospection
|
||||
];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "A GObject-based plugins engine";
|
||||
|
@ -1,13 +1,17 @@
|
||||
{ stdenv, fetchurl, meson, ninja, pkgconfig, gettext, itstool, wrapGAppsHook
|
||||
, cairo, gdk_pixbuf, colord, glib, gtk, gusb, packagekit, libwebp
|
||||
, libxml2, sane-backends, vala, gnome3 }:
|
||||
, libxml2, sane-backends, vala, gnome3, gobjectIntrospection }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
inherit (import ./src.nix fetchurl) name src;
|
||||
|
||||
buildInputs = [ cairo gdk_pixbuf colord glib gnome3.defaultIconTheme gusb
|
||||
gtk libwebp packagekit sane-backends vala ];
|
||||
nativeBuildInputs = [ meson ninja gettext itstool pkgconfig wrapGAppsHook libxml2 ];
|
||||
nativeBuildInputs = [
|
||||
meson ninja gettext itstool pkgconfig wrapGAppsHook libxml2
|
||||
# For setup hook
|
||||
gobjectIntrospection
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
patchShebangs data/meson_compile_gschema.py
|
||||
|
@ -1,11 +1,11 @@
|
||||
{ stdenv, fetchurl, pkgconfig, glib, gtk3, enchant, isocodes, vala }:
|
||||
{ stdenv, fetchurl, pkgconfig, glib, gtk3, enchant, isocodes, vala, gobjectIntrospection }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
inherit (import ./src.nix fetchurl) name src;
|
||||
|
||||
propagatedBuildInputs = [ enchant ]; # required for pkgconfig
|
||||
|
||||
nativeBuildInputs = [ pkgconfig vala ];
|
||||
nativeBuildInputs = [ pkgconfig vala gobjectIntrospection ];
|
||||
buildInputs = [ glib gtk3 isocodes ];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
|
@ -74,4 +74,4 @@ addEnvVars() {
|
||||
addToSearchPath NIX_GNUSTEP_SYSTEM_DOC_INFO "$tmp"
|
||||
fi
|
||||
}
|
||||
envHooks=(${envHooks[@]} addEnvVars)
|
||||
addEnvHooks "$targetOffset" addEnvVars
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, perl, cmake, vala_0_38, pkgconfig, glib, gtk3, granite, gnome3, libnotify, gettext, makeWrapper }:
|
||||
{ stdenv, fetchurl, perl, cmake, vala_0_38, pkgconfig, glib, gtk3, granite, gnome3, libnotify, gettext, makeWrapper, gobjectIntrospection }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
majorVersion = "0.4";
|
||||
@ -20,7 +20,11 @@ stdenv.mkDerivation rec {
|
||||
done
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [ perl cmake vala_0_38 pkgconfig makeWrapper ];
|
||||
nativeBuildInputs = [
|
||||
perl cmake vala_0_38 pkgconfig makeWrapper
|
||||
# For setup hook
|
||||
gobjectIntrospection
|
||||
];
|
||||
buildInputs = with gnome3; [
|
||||
glib gtk3 granite libnotify gettext vte_290 libgee
|
||||
gsettings_desktop_schemas defaultIconTheme
|
||||
|
@ -4,4 +4,4 @@ addChickenRepositoryPath() {
|
||||
export CHICKEN_INCLUDE_PATH="$1/share;$CHICKEN_INCLUDE_PATH"
|
||||
}
|
||||
|
||||
envHooks=(${envHooks[@]} addChickenRepositoryPath)
|
||||
addEnvHooks "$targetOffset" addChickenRepositoryPath
|
||||
|
@ -229,11 +229,22 @@ stdenv.mkDerivation ({
|
||||
inherit noSysDirs profiledCompiler staticCompiler langJava
|
||||
libcCross crossMingw;
|
||||
|
||||
depsBuildBuild = [ buildPackages.stdenv.cc ];
|
||||
nativeBuildInputs = [ texinfo which gettext ]
|
||||
++ optional (perl != null) perl;
|
||||
|
||||
buildInputs = [ gmp mpfr libmpc libelf ]
|
||||
++ (optional (ppl != null) ppl)
|
||||
# For building runtime libs
|
||||
depsBuildTarget =
|
||||
if hostPlatform == buildPlatform then [
|
||||
targetPackages.stdenv.cc.bintools # newly-built gcc will be used
|
||||
] else assert targetPlatform == hostPlatform; [ # build != host == target
|
||||
stdenv.cc
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
gmp mpfr libmpc libelf
|
||||
targetPackages.stdenv.cc.bintools # For linking code at run-time
|
||||
] ++ (optional (ppl != null) ppl)
|
||||
++ (optional (cloogppl != null) cloogppl)
|
||||
++ (optional (zlib != null) zlib)
|
||||
++ (optional langJava boehmgc)
|
||||
@ -245,11 +256,7 @@ stdenv.mkDerivation ({
|
||||
;
|
||||
|
||||
# TODO(@Ericson2314): Always pass "--target" and always prefix.
|
||||
configurePlatforms =
|
||||
# TODO(@Ericson2314): Figure out what's going wrong with Arm
|
||||
if hostPlatform == targetPlatform && targetPlatform.isArm
|
||||
then []
|
||||
else [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
configurePlatforms = [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
|
||||
configureFlags =
|
||||
# Basic dependencies
|
||||
@ -314,56 +321,9 @@ stdenv.mkDerivation ({
|
||||
|
||||
/* For cross-built gcc (build != host == target) */
|
||||
crossAttrs = {
|
||||
AR_FOR_BUILD = "ar";
|
||||
AS_FOR_BUILD = "as";
|
||||
LD_FOR_BUILD = "ld";
|
||||
NM_FOR_BUILD = "nm";
|
||||
OBJCOPY_FOR_BUILD = "objcopy";
|
||||
OBJDUMP_FOR_BUILD = "objdump";
|
||||
RANLIB_FOR_BUILD = "ranlib";
|
||||
SIZE_FOR_BUILD = "size";
|
||||
STRINGS_FOR_BUILD = "strings";
|
||||
STRIP_FOR_BUILD = "strip";
|
||||
CC_FOR_BUILD = "gcc";
|
||||
CXX_FOR_BUILD = "g++";
|
||||
|
||||
AR = "${targetPlatform.config}-ar";
|
||||
AS = "${targetPlatform.config}-as";
|
||||
LD = "${targetPlatform.config}-ld";
|
||||
NM = "${targetPlatform.config}-nm";
|
||||
OBJCOPY = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP = "${targetPlatform.config}-objdump";
|
||||
RANLIB = "${targetPlatform.config}-ranlib";
|
||||
SIZE = "${targetPlatform.config}-size";
|
||||
STRINGS = "${targetPlatform.config}-strings";
|
||||
STRIP = "${targetPlatform.config}-strip";
|
||||
CC = "${targetPlatform.config}-gcc";
|
||||
CXX = "${targetPlatform.config}-g++";
|
||||
|
||||
AR_FOR_TARGET = "${targetPlatform.config}-ar";
|
||||
AS_FOR_TARGET = "${targetPlatform.config}-as";
|
||||
LD_FOR_TARGET = "${targetPlatform.config}-ld";
|
||||
NM_FOR_TARGET = "${targetPlatform.config}-nm";
|
||||
OBJCOPY_FOR_TARGET = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP_FOR_TARGET = "${targetPlatform.config}-objdump";
|
||||
RANLIB_FOR_TARGET = "${targetPlatform.config}-ranlib";
|
||||
SIZE_FOR_TARGET = "${targetPlatform.config}-size";
|
||||
STRINGS_FOR_TARGET = "${targetPlatform.config}-strings";
|
||||
STRIP_FOR_TARGET = "${targetPlatform.config}-strip";
|
||||
CC_FOR_TARGET = "${targetPlatform.config}-gcc";
|
||||
CXX_FOR_TARGET = "${targetPlatform.config}-g++";
|
||||
|
||||
dontStrip = true;
|
||||
};
|
||||
|
||||
NIX_BUILD_BINTOOLS = buildPackages.stdenv.cc.bintools;
|
||||
NIX_BUILD_CC = buildPackages.stdenv.cc;
|
||||
|
||||
# Needed for the cross compilation to work
|
||||
AR = "ar";
|
||||
LD = "ld";
|
||||
CC = "gcc";
|
||||
|
||||
# Setting $CPATH and $LIBRARY_PATH to make sure both `gcc' and `xgcc' find the
|
||||
# library headers and binaries, regarless of the language being compiled.
|
||||
#
|
||||
|
@ -267,6 +267,7 @@ stdenv.mkDerivation ({
|
||||
inherit noSysDirs staticCompiler langJava
|
||||
libcCross crossMingw;
|
||||
|
||||
depsBuildBuild = [ buildPackages.stdenv.cc ];
|
||||
nativeBuildInputs = [ texinfo which gettext ]
|
||||
++ (optional (perl != null) perl)
|
||||
++ (optional javaAwtGtk pkgconfig);
|
||||
@ -297,11 +298,7 @@ stdenv.mkDerivation ({
|
||||
dontDisableStatic = true;
|
||||
|
||||
# TODO(@Ericson2314): Always pass "--target" and always prefix.
|
||||
configurePlatforms =
|
||||
# TODO(@Ericson2314): Figure out what's going wrong with Arm
|
||||
if hostPlatform == targetPlatform && targetPlatform.isArm
|
||||
then []
|
||||
else [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
configurePlatforms = [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
|
||||
configureFlags =
|
||||
# Basic dependencies
|
||||
@ -397,57 +394,12 @@ stdenv.mkDerivation ({
|
||||
|
||||
/* For cross-built gcc (build != host == target) */
|
||||
crossAttrs = {
|
||||
AR_FOR_BUILD = "ar";
|
||||
AS_FOR_BUILD = "as";
|
||||
LD_FOR_BUILD = "ld";
|
||||
NM_FOR_BUILD = "nm";
|
||||
OBJCOPY_FOR_BUILD = "objcopy";
|
||||
OBJDUMP_FOR_BUILD = "objdump";
|
||||
RANLIB_FOR_BUILD = "ranlib";
|
||||
SIZE_FOR_BUILD = "size";
|
||||
STRINGS_FOR_BUILD = "strings";
|
||||
STRIP_FOR_BUILD = "strip";
|
||||
CC_FOR_BUILD = "gcc";
|
||||
CXX_FOR_BUILD = "g++";
|
||||
|
||||
AR = "${targetPlatform.config}-ar";
|
||||
AS = "${targetPlatform.config}-as";
|
||||
LD = "${targetPlatform.config}-ld";
|
||||
NM = "${targetPlatform.config}-nm";
|
||||
OBJCOPY = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP = "${targetPlatform.config}-objdump";
|
||||
RANLIB = "${targetPlatform.config}-ranlib";
|
||||
SIZE = "${targetPlatform.config}-size";
|
||||
STRINGS = "${targetPlatform.config}-strings";
|
||||
STRIP = "${targetPlatform.config}-strip";
|
||||
CC = "${targetPlatform.config}-gcc";
|
||||
CXX = "${targetPlatform.config}-g++";
|
||||
|
||||
AR_FOR_TARGET = "${targetPlatform.config}-ar";
|
||||
AS_FOR_TARGET = "${targetPlatform.config}-as";
|
||||
LD_FOR_TARGET = "${targetPlatform.config}-ld";
|
||||
NM_FOR_TARGET = "${targetPlatform.config}-nm";
|
||||
OBJCOPY_FOR_TARGET = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP_FOR_TARGET = "${targetPlatform.config}-objdump";
|
||||
RANLIB_FOR_TARGET = "${targetPlatform.config}-ranlib";
|
||||
SIZE_FOR_TARGET = "${targetPlatform.config}-size";
|
||||
STRINGS_FOR_TARGET = "${targetPlatform.config}-strings";
|
||||
STRIP_FOR_TARGET = "${targetPlatform.config}-strip";
|
||||
CC_FOR_TARGET = "${targetPlatform.config}-gcc";
|
||||
CXX_FOR_TARGET = "${targetPlatform.config}-g++";
|
||||
|
||||
dontStrip = true;
|
||||
buildFlags = "";
|
||||
};
|
||||
|
||||
NIX_BUILD_BINTOOLS = buildPackages.stdenv.cc.bintools;
|
||||
NIX_BUILD_CC = buildPackages.stdenv.cc;
|
||||
|
||||
# Needed for the cross compilation to work
|
||||
AR = "ar";
|
||||
LD = "ld";
|
||||
# http://gcc.gnu.org/install/specific.html#x86-64-x-solaris210
|
||||
CC = if stdenv.system == "x86_64-solaris" then "gcc -m64" else "gcc";
|
||||
${if hostPlatform.system == "x86_64-solaris" then "CC" else null} = "gcc -m64";
|
||||
|
||||
# Setting $CPATH and $LIBRARY_PATH to make sure both `gcc' and `xgcc' find the
|
||||
# library headers and binaries, regarless of the language being compiled.
|
||||
|
@ -262,12 +262,23 @@ stdenv.mkDerivation ({
|
||||
inherit noSysDirs staticCompiler langJava
|
||||
libcCross crossMingw;
|
||||
|
||||
depsBuildBuild = [ buildPackages.stdenv.cc ];
|
||||
nativeBuildInputs = [ texinfo which gettext ]
|
||||
++ (optional (perl != null) perl)
|
||||
++ (optional javaAwtGtk pkgconfig);
|
||||
|
||||
buildInputs = [ gmp mpfr libmpc libelf ]
|
||||
++ (optional (cloog != null) cloog)
|
||||
# For building runtime libs
|
||||
depsBuildTarget =
|
||||
if hostPlatform == buildPlatform then [
|
||||
targetPackages.stdenv.cc.bintools # newly-built gcc will be used
|
||||
] else assert targetPlatform == hostPlatform; [ # build != host == target
|
||||
stdenv.cc
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
gmp mpfr libmpc libelf
|
||||
targetPackages.stdenv.cc.bintools # For linking code at run-time
|
||||
] ++ (optional (cloog != null) cloog)
|
||||
++ (optional (isl != null) isl)
|
||||
++ (optional (zlib != null) zlib)
|
||||
++ (optionals langJava [ boehmgc zip unzip ])
|
||||
@ -296,11 +307,7 @@ stdenv.mkDerivation ({
|
||||
dontDisableStatic = true;
|
||||
|
||||
# TODO(@Ericson2314): Always pass "--target" and always prefix.
|
||||
configurePlatforms =
|
||||
# TODO(@Ericson2314): Figure out what's going wrong with Arm
|
||||
if hostPlatform == targetPlatform && targetPlatform.isArm
|
||||
then []
|
||||
else [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
configurePlatforms = [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
|
||||
configureFlags =
|
||||
# Basic dependencies
|
||||
@ -395,57 +402,12 @@ stdenv.mkDerivation ({
|
||||
|
||||
/* For cross-built gcc (build != host == target) */
|
||||
crossAttrs = {
|
||||
AR_FOR_BUILD = "ar";
|
||||
AS_FOR_BUILD = "as";
|
||||
LD_FOR_BUILD = "ld";
|
||||
NM_FOR_BUILD = "nm";
|
||||
OBJCOPY_FOR_BUILD = "objcopy";
|
||||
OBJDUMP_FOR_BUILD = "objdump";
|
||||
RANLIB_FOR_BUILD = "ranlib";
|
||||
SIZE_FOR_BUILD = "size";
|
||||
STRINGS_FOR_BUILD = "strings";
|
||||
STRIP_FOR_BUILD = "strip";
|
||||
CC_FOR_BUILD = "gcc";
|
||||
CXX_FOR_BUILD = "g++";
|
||||
|
||||
AR = "${targetPlatform.config}-ar";
|
||||
AS = "${targetPlatform.config}-as";
|
||||
LD = "${targetPlatform.config}-ld";
|
||||
NM = "${targetPlatform.config}-nm";
|
||||
OBJCOPY = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP = "${targetPlatform.config}-objdump";
|
||||
RANLIB = "${targetPlatform.config}-ranlib";
|
||||
SIZE = "${targetPlatform.config}-size";
|
||||
STRINGS = "${targetPlatform.config}-strings";
|
||||
STRIP = "${targetPlatform.config}-strip";
|
||||
CC = "${targetPlatform.config}-gcc";
|
||||
CXX = "${targetPlatform.config}-g++";
|
||||
|
||||
AR_FOR_TARGET = "${targetPlatform.config}-ar";
|
||||
AS_FOR_TARGET = "${targetPlatform.config}-as";
|
||||
LD_FOR_TARGET = "${targetPlatform.config}-ld";
|
||||
NM_FOR_TARGET = "${targetPlatform.config}-nm";
|
||||
OBJCOPY_FOR_TARGET = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP_FOR_TARGET = "${targetPlatform.config}-objdump";
|
||||
RANLIB_FOR_TARGET = "${targetPlatform.config}-ranlib";
|
||||
SIZE_FOR_TARGET = "${targetPlatform.config}-size";
|
||||
STRINGS_FOR_TARGET = "${targetPlatform.config}-strings";
|
||||
STRIP_FOR_TARGET = "${targetPlatform.config}-strip";
|
||||
CC_FOR_TARGET = "${targetPlatform.config}-gcc";
|
||||
CXX_FOR_TARGET = "${targetPlatform.config}-g++";
|
||||
|
||||
dontStrip = true;
|
||||
buildFlags = "";
|
||||
};
|
||||
|
||||
NIX_BUILD_BINTOOLS = buildPackages.stdenv.cc.bintools;
|
||||
NIX_BUILD_CC = buildPackages.stdenv.cc;
|
||||
|
||||
# Needed for the cross compilation to work
|
||||
AR = "ar";
|
||||
LD = "ld";
|
||||
# http://gcc.gnu.org/install/specific.html#x86-64-x-solaris210
|
||||
CC = if stdenv.system == "x86_64-solaris" then "gcc -m64" else "gcc";
|
||||
${if hostPlatform.system == "x86_64-solaris" then "CC" else null} = "gcc -m64";
|
||||
|
||||
# Setting $CPATH and $LIBRARY_PATH to make sure both `gcc' and `xgcc' find the
|
||||
# library headers and binaries, regarless of the language being compiled.
|
||||
|
@ -49,9 +49,6 @@ assert libelf != null -> zlib != null;
|
||||
# Make sure we get GNU sed.
|
||||
assert hostPlatform.isDarwin -> gnused != null;
|
||||
|
||||
# Need c++filt on darwin
|
||||
assert hostPlatform.isDarwin -> targetPackages.stdenv.cc.bintools or null != null;
|
||||
|
||||
# The go frontend is written in c++
|
||||
assert langGo -> langCC;
|
||||
|
||||
@ -277,17 +274,27 @@ stdenv.mkDerivation ({
|
||||
inherit noSysDirs staticCompiler langJava
|
||||
libcCross crossMingw;
|
||||
|
||||
depsBuildBuild = [ buildPackages.stdenv.cc ];
|
||||
nativeBuildInputs = [ texinfo which gettext ]
|
||||
++ (optional (perl != null) perl)
|
||||
++ (optional javaAwtGtk pkgconfig);
|
||||
|
||||
buildInputs = [ gmp mpfr libmpc libelf ]
|
||||
++ (optional (isl != null) isl)
|
||||
# For building runtime libs
|
||||
depsBuildTarget =
|
||||
if hostPlatform == buildPlatform then [
|
||||
targetPackages.stdenv.cc.bintools # newly-built gcc will be used
|
||||
] else assert targetPlatform == hostPlatform; [ # build != host == target
|
||||
stdenv.cc
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
gmp mpfr libmpc libelf
|
||||
targetPackages.stdenv.cc.bintools # For linking code at run-time
|
||||
] ++ (optional (isl != null) isl)
|
||||
++ (optional (zlib != null) zlib)
|
||||
++ (optionals langJava [ boehmgc zip unzip ])
|
||||
++ (optionals javaAwtGtk ([ gtk2 libart_lgpl ] ++ xlibs))
|
||||
++ (optionals (targetPlatform != hostPlatform) [targetPackages.stdenv.cc.bintools])
|
||||
++ (optionals (buildPlatform != hostPlatform) [buildPackages.stdenv.cc])
|
||||
++ (optionals langAda [gnatboot])
|
||||
++ (optionals langVhdl [gnat])
|
||||
|
||||
@ -309,11 +316,7 @@ stdenv.mkDerivation ({
|
||||
dontDisableStatic = true;
|
||||
|
||||
# TODO(@Ericson2314): Always pass "--target" and always prefix.
|
||||
configurePlatforms =
|
||||
# TODO(@Ericson2314): Figure out what's going wrong with Arm
|
||||
if hostPlatform == targetPlatform && targetPlatform.isArm
|
||||
then []
|
||||
else [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
configurePlatforms = [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
|
||||
configureFlags =
|
||||
# Basic dependencies
|
||||
@ -404,57 +407,12 @@ stdenv.mkDerivation ({
|
||||
|
||||
/* For cross-built gcc (build != host == target) */
|
||||
crossAttrs = {
|
||||
AR_FOR_BUILD = "ar";
|
||||
AS_FOR_BUILD = "as";
|
||||
LD_FOR_BUILD = "ld";
|
||||
NM_FOR_BUILD = "nm";
|
||||
OBJCOPY_FOR_BUILD = "objcopy";
|
||||
OBJDUMP_FOR_BUILD = "objdump";
|
||||
RANLIB_FOR_BUILD = "ranlib";
|
||||
SIZE_FOR_BUILD = "size";
|
||||
STRINGS_FOR_BUILD = "strings";
|
||||
STRIP_FOR_BUILD = "strip";
|
||||
CC_FOR_BUILD = "gcc";
|
||||
CXX_FOR_BUILD = "g++";
|
||||
|
||||
AR = "${targetPlatform.config}-ar";
|
||||
AS = "${targetPlatform.config}-as";
|
||||
LD = "${targetPlatform.config}-ld";
|
||||
NM = "${targetPlatform.config}-nm";
|
||||
OBJCOPY = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP = "${targetPlatform.config}-objdump";
|
||||
RANLIB = "${targetPlatform.config}-ranlib";
|
||||
SIZE = "${targetPlatform.config}-size";
|
||||
STRINGS = "${targetPlatform.config}-strings";
|
||||
STRIP = "${targetPlatform.config}-strip";
|
||||
CC = "${targetPlatform.config}-gcc";
|
||||
CXX = "${targetPlatform.config}-g++";
|
||||
|
||||
AR_FOR_TARGET = "${targetPlatform.config}-ar";
|
||||
AS_FOR_TARGET = "${targetPlatform.config}-as";
|
||||
LD_FOR_TARGET = "${targetPlatform.config}-ld";
|
||||
NM_FOR_TARGET = "${targetPlatform.config}-nm";
|
||||
OBJCOPY_FOR_TARGET = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP_FOR_TARGET = "${targetPlatform.config}-objdump";
|
||||
RANLIB_FOR_TARGET = "${targetPlatform.config}-ranlib";
|
||||
SIZE_FOR_TARGET = "${targetPlatform.config}-size";
|
||||
STRINGS_FOR_TARGET = "${targetPlatform.config}-strings";
|
||||
STRIP_FOR_TARGET = "${targetPlatform.config}-strip";
|
||||
CC_FOR_TARGET = "${targetPlatform.config}-gcc";
|
||||
CXX_FOR_TARGET = "${targetPlatform.config}-g++";
|
||||
|
||||
dontStrip = true;
|
||||
buildFlags = "";
|
||||
};
|
||||
|
||||
NIX_BUILD_BINTOOLS = buildPackages.stdenv.cc.bintools;
|
||||
NIX_BUILD_CC = buildPackages.stdenv.cc;
|
||||
|
||||
# Needed for the cross compilation to work
|
||||
AR = "ar";
|
||||
LD = "ld";
|
||||
# http://gcc.gnu.org/install/specific.html#x86-64-x-solaris210
|
||||
CC = if stdenv.system == "x86_64-solaris" then "gcc -m64" else "gcc";
|
||||
${if hostPlatform.system == "x86_64-solaris" then "CC" else null} = "gcc -m64";
|
||||
|
||||
# Setting $CPATH and $LIBRARY_PATH to make sure both `gcc' and `xgcc' find the
|
||||
# library headers and binaries, regarless of the language being compiled.
|
||||
|
@ -49,9 +49,6 @@ assert libelf != null -> zlib != null;
|
||||
# Make sure we get GNU sed.
|
||||
assert hostPlatform.isDarwin -> gnused != null;
|
||||
|
||||
# Need c++filt on darwin
|
||||
assert hostPlatform.isDarwin -> targetPackages.stdenv.cc.bintools or null != null;
|
||||
|
||||
# The go frontend is written in c++
|
||||
assert langGo -> langCC;
|
||||
|
||||
@ -276,12 +273,23 @@ stdenv.mkDerivation ({
|
||||
inherit noSysDirs staticCompiler langJava
|
||||
libcCross crossMingw;
|
||||
|
||||
depsBuildBuild = [ buildPackages.stdenv.cc ];
|
||||
nativeBuildInputs = [ texinfo which gettext ]
|
||||
++ (optional (perl != null) perl)
|
||||
++ (optional javaAwtGtk pkgconfig);
|
||||
|
||||
buildInputs = [ gmp mpfr libmpc libelf ]
|
||||
++ (optional (isl != null) isl)
|
||||
# For building runtime libs
|
||||
depsBuildTarget =
|
||||
if hostPlatform == buildPlatform then [
|
||||
targetPackages.stdenv.cc.bintools # newly-built gcc will be used
|
||||
] else assert targetPlatform == hostPlatform; [ # build != host == target
|
||||
stdenv.cc
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
gmp mpfr libmpc libelf
|
||||
targetPackages.stdenv.cc.bintools # For linking code at run-time
|
||||
] ++ (optional (isl != null) isl)
|
||||
++ (optional (zlib != null) zlib)
|
||||
++ (optionals langJava [ boehmgc zip unzip ])
|
||||
++ (optionals javaAwtGtk ([ gtk2 libart_lgpl ] ++ xlibs))
|
||||
@ -311,11 +319,7 @@ stdenv.mkDerivation ({
|
||||
dontDisableStatic = true;
|
||||
|
||||
# TODO(@Ericson2314): Always pass "--target" and always prefix.
|
||||
configurePlatforms =
|
||||
# TODO(@Ericson2314): Figure out what's going wrong with Arm
|
||||
if hostPlatform == targetPlatform && targetPlatform.isArm
|
||||
then []
|
||||
else [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
configurePlatforms = [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
|
||||
configureFlags =
|
||||
# Basic dependencies
|
||||
@ -405,57 +409,12 @@ stdenv.mkDerivation ({
|
||||
|
||||
/* For cross-built gcc (build != host == target) */
|
||||
crossAttrs = {
|
||||
AR_FOR_BUILD = "ar";
|
||||
AS_FOR_BUILD = "as";
|
||||
LD_FOR_BUILD = "ld";
|
||||
NM_FOR_BUILD = "nm";
|
||||
OBJCOPY_FOR_BUILD = "objcopy";
|
||||
OBJDUMP_FOR_BUILD = "objdump";
|
||||
RANLIB_FOR_BUILD = "ranlib";
|
||||
SIZE_FOR_BUILD = "size";
|
||||
STRINGS_FOR_BUILD = "strings";
|
||||
STRIP_FOR_BUILD = "strip";
|
||||
CC_FOR_BUILD = "gcc";
|
||||
CXX_FOR_BUILD = "g++";
|
||||
|
||||
AR = "${targetPlatform.config}-ar";
|
||||
AS = "${targetPlatform.config}-as";
|
||||
LD = "${targetPlatform.config}-ld";
|
||||
NM = "${targetPlatform.config}-nm";
|
||||
OBJCOPY = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP = "${targetPlatform.config}-objdump";
|
||||
RANLIB = "${targetPlatform.config}-ranlib";
|
||||
SIZE = "${targetPlatform.config}-size";
|
||||
STRINGS = "${targetPlatform.config}-strings";
|
||||
STRIP = "${targetPlatform.config}-strip";
|
||||
CC = "${targetPlatform.config}-gcc";
|
||||
CXX = "${targetPlatform.config}-g++";
|
||||
|
||||
AR_FOR_TARGET = "${targetPlatform.config}-ar";
|
||||
AS_FOR_TARGET = "${targetPlatform.config}-as";
|
||||
LD_FOR_TARGET = "${targetPlatform.config}-ld";
|
||||
NM_FOR_TARGET = "${targetPlatform.config}-nm";
|
||||
OBJCOPY_FOR_TARGET = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP_FOR_TARGET = "${targetPlatform.config}-objdump";
|
||||
RANLIB_FOR_TARGET = "${targetPlatform.config}-ranlib";
|
||||
SIZE_FOR_TARGET = "${targetPlatform.config}-size";
|
||||
STRINGS_FOR_TARGET = "${targetPlatform.config}-strings";
|
||||
STRIP_FOR_TARGET = "${targetPlatform.config}-strip";
|
||||
CC_FOR_TARGET = "${targetPlatform.config}-gcc";
|
||||
CXX_FOR_TARGET = "${targetPlatform.config}-g++";
|
||||
|
||||
dontStrip = true;
|
||||
buildFlags = "";
|
||||
};
|
||||
|
||||
NIX_BUILD_BINTOOLS = buildPackages.stdenv.cc.bintools;
|
||||
NIX_BUILD_CC = buildPackages.stdenv.cc;
|
||||
|
||||
# Needed for the cross compilation to work
|
||||
AR = "ar";
|
||||
LD = "ld";
|
||||
# http://gcc.gnu.org/install/specific.html#x86-64-x-solaris210
|
||||
CC = if stdenv.system == "x86_64-solaris" then "gcc -m64" else "gcc";
|
||||
${if hostPlatform.system == "x86_64-solaris" then "CC" else null} = "gcc -m64";
|
||||
|
||||
# Setting $CPATH and $LIBRARY_PATH to make sure both `gcc' and `xgcc' find the
|
||||
# library headers and binaries, regarless of the language being compiled.
|
||||
|
@ -50,9 +50,6 @@ assert libelf != null -> zlib != null;
|
||||
# Make sure we get GNU sed.
|
||||
assert hostPlatform.isDarwin -> gnused != null;
|
||||
|
||||
# Need c++filt on darwin
|
||||
assert hostPlatform.isDarwin -> targetPackages.stdenv.cc.bintools or null != null;
|
||||
|
||||
# The go frontend is written in c++
|
||||
assert langGo -> langCC;
|
||||
|
||||
@ -273,12 +270,23 @@ stdenv.mkDerivation ({
|
||||
inherit noSysDirs staticCompiler langJava
|
||||
libcCross crossMingw;
|
||||
|
||||
depsBuildBuild = [ buildPackages.stdenv.cc ];
|
||||
nativeBuildInputs = [ texinfo which gettext ]
|
||||
++ (optional (perl != null) perl)
|
||||
++ (optional javaAwtGtk pkgconfig);
|
||||
|
||||
buildInputs = [ gmp mpfr libmpc libelf flex ]
|
||||
++ (optional (isl != null) isl)
|
||||
# For building runtime libs
|
||||
depsBuildTarget =
|
||||
if hostPlatform == buildPlatform then [
|
||||
targetPackages.stdenv.cc.bintools # newly-built gcc will be used
|
||||
] else assert targetPlatform == hostPlatform; [ # build != host == target
|
||||
stdenv.cc
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
gmp mpfr libmpc libelf flex
|
||||
targetPackages.stdenv.cc.bintools # For linking code at run-time
|
||||
] ++ (optional (isl != null) isl)
|
||||
++ (optional (zlib != null) zlib)
|
||||
++ (optionals langJava [ boehmgc zip unzip ])
|
||||
++ (optionals javaAwtGtk ([ gtk2 libart_lgpl ] ++ xlibs))
|
||||
@ -304,11 +312,7 @@ stdenv.mkDerivation ({
|
||||
dontDisableStatic = true;
|
||||
|
||||
# TODO(@Ericson2314): Always pass "--target" and always prefix.
|
||||
configurePlatforms =
|
||||
# TODO(@Ericson2314): Figure out what's going wrong with Arm
|
||||
if hostPlatform == targetPlatform && targetPlatform.isArm
|
||||
then []
|
||||
else [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
configurePlatforms = [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
|
||||
configureFlags =
|
||||
# Basic dependencies
|
||||
@ -399,57 +403,12 @@ stdenv.mkDerivation ({
|
||||
|
||||
/* For cross-built gcc (build != host == target) */
|
||||
crossAttrs = {
|
||||
AR_FOR_BUILD = "ar";
|
||||
AS_FOR_BUILD = "as";
|
||||
LD_FOR_BUILD = "ld";
|
||||
NM_FOR_BUILD = "nm";
|
||||
OBJCOPY_FOR_BUILD = "objcopy";
|
||||
OBJDUMP_FOR_BUILD = "objdump";
|
||||
RANLIB_FOR_BUILD = "ranlib";
|
||||
SIZE_FOR_BUILD = "size";
|
||||
STRINGS_FOR_BUILD = "strings";
|
||||
STRIP_FOR_BUILD = "strip";
|
||||
CC_FOR_BUILD = "gcc";
|
||||
CXX_FOR_BUILD = "g++";
|
||||
|
||||
AR = "${targetPlatform.config}-ar";
|
||||
AS = "${targetPlatform.config}-as";
|
||||
LD = "${targetPlatform.config}-ld";
|
||||
NM = "${targetPlatform.config}-nm";
|
||||
OBJCOPY = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP = "${targetPlatform.config}-objdump";
|
||||
RANLIB = "${targetPlatform.config}-ranlib";
|
||||
SIZE = "${targetPlatform.config}-size";
|
||||
STRINGS = "${targetPlatform.config}-strings";
|
||||
STRIP = "${targetPlatform.config}-strip";
|
||||
CC = "${targetPlatform.config}-gcc";
|
||||
CXX = "${targetPlatform.config}-g++";
|
||||
|
||||
AR_FOR_TARGET = "${targetPlatform.config}-ar";
|
||||
AS_FOR_TARGET = "${targetPlatform.config}-as";
|
||||
LD_FOR_TARGET = "${targetPlatform.config}-ld";
|
||||
NM_FOR_TARGET = "${targetPlatform.config}-nm";
|
||||
OBJCOPY_FOR_TARGET = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP_FOR_TARGET = "${targetPlatform.config}-objdump";
|
||||
RANLIB_FOR_TARGET = "${targetPlatform.config}-ranlib";
|
||||
SIZE_FOR_TARGET = "${targetPlatform.config}-size";
|
||||
STRINGS_FOR_TARGET = "${targetPlatform.config}-strings";
|
||||
STRIP_FOR_TARGET = "${targetPlatform.config}-strip";
|
||||
CC_FOR_TARGET = "${targetPlatform.config}-gcc";
|
||||
CXX_FOR_TARGET = "${targetPlatform.config}-g++";
|
||||
|
||||
dontStrip = true;
|
||||
buildFlags = "";
|
||||
};
|
||||
|
||||
NIX_BUILD_BINTOOLS = buildPackages.stdenv.cc.bintools;
|
||||
NIX_BUILD_CC = buildPackages.stdenv.cc;
|
||||
|
||||
# Needed for the cross compilation to work
|
||||
AR = "ar";
|
||||
LD = "ld";
|
||||
# http://gcc.gnu.org/install/specific.html#x86-64-x-solaris210
|
||||
CC = if stdenv.system == "x86_64-solaris" then "gcc -m64" else "gcc";
|
||||
${if hostPlatform.system == "x86_64-solaris" then "CC" else null} = "gcc -m64";
|
||||
|
||||
# Setting $CPATH and $LIBRARY_PATH to make sure both `gcc' and `xgcc' find the
|
||||
# library headers and binaries, regarless of the language being compiled.
|
||||
|
@ -50,9 +50,6 @@ assert libelf != null -> zlib != null;
|
||||
# Make sure we get GNU sed.
|
||||
assert hostPlatform.isDarwin -> gnused != null;
|
||||
|
||||
# Need c++filt on darwin
|
||||
assert hostPlatform.isDarwin -> targetPackages.stdenv.cc.bintools or null != null;
|
||||
|
||||
# The go frontend is written in c++
|
||||
assert langGo -> langCC;
|
||||
|
||||
@ -260,12 +257,23 @@ stdenv.mkDerivation ({
|
||||
inherit noSysDirs staticCompiler langJava
|
||||
libcCross crossMingw;
|
||||
|
||||
depsBuildBuild = [ buildPackages.stdenv.cc ];
|
||||
nativeBuildInputs = [ texinfo which gettext ]
|
||||
++ (optional (perl != null) perl)
|
||||
++ (optional javaAwtGtk pkgconfig);
|
||||
|
||||
buildInputs = [ gmp mpfr libmpc libelf flex ]
|
||||
++ (optional (isl != null) isl)
|
||||
# For building runtime libs
|
||||
depsBuildTarget =
|
||||
if hostPlatform == buildPlatform then [
|
||||
targetPackages.stdenv.cc.bintools # newly-built gcc will be used
|
||||
] else assert targetPlatform == hostPlatform; [ # build != host == target
|
||||
stdenv.cc
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
gmp mpfr libmpc libelf flex
|
||||
targetPackages.stdenv.cc.bintools # For linking code at run-time
|
||||
] ++ (optional (isl != null) isl)
|
||||
++ (optional (zlib != null) zlib)
|
||||
++ (optionals langJava [ boehmgc zip unzip ])
|
||||
++ (optionals javaAwtGtk ([ gtk2 libart_lgpl ] ++ xlibs))
|
||||
@ -291,11 +299,7 @@ stdenv.mkDerivation ({
|
||||
dontDisableStatic = true;
|
||||
|
||||
# TODO(@Ericson2314): Always pass "--target" and always prefix.
|
||||
configurePlatforms =
|
||||
# TODO(@Ericson2314): Figure out what's going wrong with Arm
|
||||
if hostPlatform == targetPlatform && targetPlatform.isArm
|
||||
then []
|
||||
else [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
configurePlatforms = [ "build" "host" ] ++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
|
||||
configureFlags =
|
||||
# Basic dependencies
|
||||
@ -386,57 +390,12 @@ stdenv.mkDerivation ({
|
||||
|
||||
/* For cross-built gcc (build != host == target) */
|
||||
crossAttrs = {
|
||||
AR_FOR_BUILD = "ar";
|
||||
AS_FOR_BUILD = "as";
|
||||
LD_FOR_BUILD = "ld";
|
||||
NM_FOR_BUILD = "nm";
|
||||
OBJCOPY_FOR_BUILD = "objcopy";
|
||||
OBJDUMP_FOR_BUILD = "objdump";
|
||||
RANLIB_FOR_BUILD = "ranlib";
|
||||
SIZE_FOR_BUILD = "size";
|
||||
STRINGS_FOR_BUILD = "strings";
|
||||
STRIP_FOR_BUILD = "strip";
|
||||
CC_FOR_BUILD = "gcc";
|
||||
CXX_FOR_BUILD = "g++";
|
||||
|
||||
AR = "${targetPlatform.config}-ar";
|
||||
AS = "${targetPlatform.config}-as";
|
||||
LD = "${targetPlatform.config}-ld";
|
||||
NM = "${targetPlatform.config}-nm";
|
||||
OBJCOPY = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP = "${targetPlatform.config}-objdump";
|
||||
RANLIB = "${targetPlatform.config}-ranlib";
|
||||
SIZE = "${targetPlatform.config}-size";
|
||||
STRINGS = "${targetPlatform.config}-strings";
|
||||
STRIP = "${targetPlatform.config}-strip";
|
||||
CC = "${targetPlatform.config}-gcc";
|
||||
CXX = "${targetPlatform.config}-g++";
|
||||
|
||||
AR_FOR_TARGET = "${targetPlatform.config}-ar";
|
||||
AS_FOR_TARGET = "${targetPlatform.config}-as";
|
||||
LD_FOR_TARGET = "${targetPlatform.config}-ld";
|
||||
NM_FOR_TARGET = "${targetPlatform.config}-nm";
|
||||
OBJCOPY_FOR_TARGET = "${targetPlatform.config}-objcopy";
|
||||
OBJDUMP_FOR_TARGET = "${targetPlatform.config}-objdump";
|
||||
RANLIB_FOR_TARGET = "${targetPlatform.config}-ranlib";
|
||||
SIZE_FOR_TARGET = "${targetPlatform.config}-size";
|
||||
STRINGS_FOR_TARGET = "${targetPlatform.config}-strings";
|
||||
STRIP_FOR_TARGET = "${targetPlatform.config}-strip";
|
||||
CC_FOR_TARGET = "${targetPlatform.config}-gcc";
|
||||
CXX_FOR_TARGET = "${targetPlatform.config}-g++";
|
||||
|
||||
dontStrip = true;
|
||||
buildFlags = "";
|
||||
};
|
||||
|
||||
NIX_BUILD_BINTOOLS = buildPackages.stdenv.cc.bintools;
|
||||
NIX_BUILD_CC = buildPackages.stdenv.cc;
|
||||
|
||||
# Needed for the cross compilation to work
|
||||
AR = "ar";
|
||||
LD = "ld";
|
||||
# http://gcc.gnu.org/install/specific.html#x86-64-x-solaris210
|
||||
CC = if stdenv.system == "x86_64-solaris" then "gcc -m64" else "gcc";
|
||||
${if hostPlatform.system == "x86_64-solaris" then "CC" else null} = "gcc -m64";
|
||||
|
||||
# Setting $CPATH and $LIBRARY_PATH to make sure both `gcc' and `xgcc' find the
|
||||
# library headers and binaries, regarless of the language being compiled.
|
||||
|
@ -1,6 +1,6 @@
|
||||
{ stdenv, fetchurl, fetchgit, gambit,
|
||||
coreutils, rsync, bash,
|
||||
openssl, zlib, sqlite, libxml2, libyaml, libmysql, lmdb, leveldb }:
|
||||
openssl, zlib, sqlite, libxml2, libyaml, mysql, lmdb, leveldb }:
|
||||
|
||||
# TODO: distinct packages for gerbil-release and gerbil-devel
|
||||
|
||||
@ -17,9 +17,11 @@ stdenv.mkDerivation rec {
|
||||
buildInputs = [
|
||||
gambit
|
||||
coreutils rsync bash
|
||||
openssl zlib sqlite libxml2 libyaml libmysql lmdb leveldb
|
||||
openssl zlib sqlite libxml2 libyaml mysql.connector-c lmdb leveldb
|
||||
];
|
||||
|
||||
NIX_CFLAGS_COMPILE = [ "-I${mysql.connector-c}/include/mysql" "-L${mysql.connector-c}/lib/mysql" ];
|
||||
|
||||
postPatch = ''
|
||||
echo '(define (gerbil-version-string) "v${version}")' > src/gerbil/runtime/gx-version.scm
|
||||
|
||||
|
@ -2,4 +2,4 @@ addToGoPath() {
|
||||
addToSearchPath GOPATH $1/share/go
|
||||
}
|
||||
|
||||
envHooks=(${envHooks[@]} addToGoPath)
|
||||
addEnvHooks "$targetOffset" addToGoPath
|
||||
|
@ -4,4 +4,4 @@ addHaxeLibPath() {
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks+=(addHaxeLibPath)
|
||||
addEnvHooks "$targetOffset" addHaxeLibPath
|
||||
|
@ -2,7 +2,7 @@
|
||||
, pcre, libevent, gd, curl, libxml2, icu, flex, bison, openssl, zlib, php
|
||||
, expat, libcap, oniguruma, libdwarf, libmcrypt, tbb, gperftools, glog, libkrb5
|
||||
, bzip2, openldap, readline, libelf, uwimap, binutils, cyrus_sasl, pam, libpng
|
||||
, libxslt, freetype, gdb, git, perl, mariadb, gmp, libyaml, libedit
|
||||
, libxslt, freetype, gdb, git, perl, mysql, gmp, libyaml, libedit
|
||||
, libvpx, imagemagick, fribidi, gperf, which, ocamlPackages
|
||||
}:
|
||||
|
||||
@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
|
||||
};
|
||||
|
||||
buildInputs =
|
||||
[ cmake pkgconfig boost libunwind mariadb.client libmemcached pcre gdb git perl
|
||||
[ cmake pkgconfig boost libunwind mysql.connector-c libmemcached pcre gdb git perl
|
||||
libevent gd curl libxml2 icu flex bison openssl zlib php expat libcap
|
||||
oniguruma libdwarf libmcrypt tbb gperftools bzip2 openldap readline
|
||||
libelf uwimap binutils cyrus_sasl pam glog libpng libxslt libkrb5
|
||||
|
@ -44,15 +44,11 @@ let
|
||||
stdenv = stdenv.override (drv: {
|
||||
allowedRequisites = null;
|
||||
cc = self.clang;
|
||||
# Don't include the libc++ and libc++abi from the original stdenv.
|
||||
extraBuildInputs = stdenv.lib.optional stdenv.isDarwin darwin.CF;
|
||||
});
|
||||
|
||||
libcxxStdenv = stdenv.override (drv: {
|
||||
allowedRequisites = null;
|
||||
cc = self.libcxxClang;
|
||||
# Don't include the libc++ and libc++abi from the original stdenv.
|
||||
extraBuildInputs = stdenv.lib.optional stdenv.isDarwin darwin.CF;
|
||||
});
|
||||
|
||||
lldb = callPackage ./lldb.nix {};
|
||||
|
@ -41,15 +41,11 @@ let
|
||||
stdenv = stdenv.override (drv: {
|
||||
allowedRequisites = null;
|
||||
cc = self.clang;
|
||||
# Don't include the libc++ and libc++abi from the original stdenv.
|
||||
extraBuildInputs = stdenv.lib.optional stdenv.isDarwin darwin.CF;
|
||||
});
|
||||
|
||||
libcxxStdenv = stdenv.override (drv: {
|
||||
allowedRequisites = null;
|
||||
cc = self.libcxxClang;
|
||||
# Don't include the libc++ and libc++abi from the original stdenv.
|
||||
extraBuildInputs = stdenv.lib.optional stdenv.isDarwin darwin.CF;
|
||||
});
|
||||
|
||||
lldb = callPackage ./lldb.nix {};
|
||||
|
@ -41,15 +41,11 @@ let
|
||||
stdenv = stdenv.override (drv: {
|
||||
allowedRequisites = null;
|
||||
cc = self.clang;
|
||||
# Don't include the libc++ and libc++abi from the original stdenv.
|
||||
extraBuildInputs = stdenv.lib.optional stdenv.isDarwin darwin.CF;
|
||||
});
|
||||
|
||||
libcxxStdenv = stdenv.override (drv: {
|
||||
allowedRequisites = null;
|
||||
cc = self.libcxxClang;
|
||||
# Don't include the libc++ and libc++abi from the original stdenv.
|
||||
extraBuildInputs = stdenv.lib.optional stdenv.isDarwin darwin.CF;
|
||||
});
|
||||
|
||||
lldb = callPackage ./lldb.nix {};
|
||||
|
@ -56,15 +56,11 @@ let
|
||||
stdenv = stdenv.override (drv: {
|
||||
allowedRequisites = null;
|
||||
cc = self.clang;
|
||||
# Don't include the libc++ and libc++abi from the original stdenv.
|
||||
extraBuildInputs = stdenv.lib.optional stdenv.isDarwin darwin.CF;
|
||||
});
|
||||
|
||||
libcxxStdenv = stdenv.override (drv: {
|
||||
allowedRequisites = null;
|
||||
cc = self.libcxxClang;
|
||||
# Don't include the libc++ and libc++abi from the original stdenv.
|
||||
extraBuildInputs = stdenv.lib.optional stdenv.isDarwin darwin.CF;
|
||||
});
|
||||
|
||||
lld = callPackage ./lld.nix {};
|
||||
|
@ -9,7 +9,7 @@ let
|
||||
name = "clang-${version}";
|
||||
|
||||
unpackPhase = ''
|
||||
unpackFile ${fetch "cfe" "0w09s8fn3lkn6i04nj0cisgp821r815fk5b5fjn97xrd371277q1"}
|
||||
unpackFile ${fetch "cfe" "1zyh4dggxd55lnfg73c8fybnkssqcaa6bq2h4bzimnnj1jdnqpqk"}
|
||||
mv cfe-${version}* clang
|
||||
sourceRoot=$PWD/clang
|
||||
unpackFile ${clang-tools-extra_src}
|
||||
|
@ -6,7 +6,7 @@
|
||||
let
|
||||
callPackage = newScope (self // { inherit stdenv cmake libxml2 python2 isl release_version version fetch; });
|
||||
|
||||
release_version = "5.0.0";
|
||||
release_version = "5.0.1";
|
||||
version = release_version; # differentiating these is important for rc's
|
||||
|
||||
fetch = name: sha256: fetchurl {
|
||||
@ -14,8 +14,8 @@ let
|
||||
inherit sha256;
|
||||
};
|
||||
|
||||
compiler-rt_src = fetch "compiler-rt" "1cy0y389zxn7mk8vffqvfirk9bbcbc8ziwc1nf1a8d118rk55bfm";
|
||||
clang-tools-extra_src = fetch "clang-tools-extra" "1ikkv6k8cfgpjqlm24iqz52i5nyafzsc4dyikzzyb9n4b6wpil47";
|
||||
compiler-rt_src = fetch "compiler-rt" "1nlmm0b3wpdwxkldqp1klzv3rpqf94q2a248xgqb7aapyhbi9paf";
|
||||
clang-tools-extra_src = fetch "clang-tools-extra" "09fjii7w43kvxvsxxs6gig9vz95vnvx1779rqd36h8kksvws3bcs";
|
||||
|
||||
# Add man output without introducing extra dependencies.
|
||||
overrideManOutput = drv:
|
||||
@ -56,15 +56,11 @@ let
|
||||
stdenv = stdenv.override (drv: {
|
||||
allowedRequisites = null;
|
||||
cc = self.clang;
|
||||
# Don't include the libc++ and libc++abi from the original stdenv.
|
||||
extraBuildInputs = stdenv.lib.optional stdenv.isDarwin darwin.CF;
|
||||
});
|
||||
|
||||
libcxxStdenv = stdenv.override (drv: {
|
||||
allowedRequisites = null;
|
||||
cc = self.libcxxClang;
|
||||
# Don't include the libc++ and libc++abi from the original stdenv.
|
||||
extraBuildInputs = stdenv.lib.optional stdenv.isDarwin darwin.CF;
|
||||
});
|
||||
|
||||
lld = callPackage ./lld.nix {};
|
||||
|
@ -3,7 +3,7 @@
|
||||
stdenv.mkDerivation rec {
|
||||
name = "libc++-${version}";
|
||||
|
||||
src = fetch "libcxx" "1cf953msb0vwgjjrapw06950dnsdb2ps305czkn0vvr1k8g9irga";
|
||||
src = fetch "libcxx" "003wwniwlikgh38cbqbcshc5gkiv3a2jkmbn6am9s46y5gfrk3zs";
|
||||
|
||||
postUnpack = ''
|
||||
unpackFile ${libcxxabi.src}
|
||||
|
@ -3,7 +3,7 @@
|
||||
stdenv.mkDerivation {
|
||||
name = "libc++abi-${version}";
|
||||
|
||||
src = fetch "libcxxabi" "04c9dfmrr8diih73x0wq99dk9xb99mg0bvsnbhx5q912xg3ihs8p";
|
||||
src = fetch "libcxxabi" "0m78yr4arlz2b9m96xcygk15m2pbz8i10snk78i3q7pjnwn1a9as";
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
buildInputs = stdenv.lib.optional (!stdenv.isDarwin && !stdenv.isFreeBSD) libunwind;
|
||||
|
@ -10,7 +10,7 @@
|
||||
stdenv.mkDerivation {
|
||||
name = "lld-${version}";
|
||||
|
||||
src = fetch "lld" "15rqsmfw0jlsri7hszbs8l0j7v1030cy9xvvdb245397llh7k6ir";
|
||||
src = fetch "lld" "15fq2zvkliyiw5qi7ig2r8bshgbz4kzvs5in16mhfkw20l06rcym";
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
buildInputs = [ llvm ];
|
||||
|
@ -17,7 +17,7 @@
|
||||
stdenv.mkDerivation {
|
||||
name = "lldb-${version}";
|
||||
|
||||
src = fetch "lldb" "0zcbav39srf6awv9znvzr7nqdrj704i8da3wdgc8362y20rcm860";
|
||||
src = fetch "lldb" "0sipv8k37ai44m7jcf6wsbm2q41dgk3sk9m3i6823jkmg7kckhdp";
|
||||
|
||||
postPatch = ''
|
||||
# Fix up various paths that assume llvm and clang are installed in the same place
|
||||
|
@ -22,7 +22,7 @@
|
||||
}:
|
||||
|
||||
let
|
||||
src = fetch "llvm" "1nin64vz21hyng6jr19knxipvggaqlkl2l9jpd5czbc4c2pcnpg3";
|
||||
src = fetch "llvm" "1c07i0b61j69m578lgjkyayg419sh7sn40xb3j112nr2q2gli9sz";
|
||||
|
||||
# Used when creating a version-suffixed symlink of libLLVM.dylib
|
||||
shortVersion = with stdenv.lib;
|
||||
|
@ -10,7 +10,7 @@
|
||||
stdenv.mkDerivation {
|
||||
name = "openmp-${version}";
|
||||
|
||||
src = fetch "openmp" "1igplg89bl6k6r9q88hnpcznq3g9lb79w7bix025lwp00ldhivy0";
|
||||
src = fetch "openmp" "0lr6r87xzg87w1q9rrh04nqpyr8c929dh4qy3csjiy7rsb6kbdmd";
|
||||
|
||||
nativeBuildInputs = [ cmake perl ];
|
||||
buildInputs = [ llvm ];
|
||||
|
@ -1,5 +1,5 @@
|
||||
{ stdenv, fetchurl, boehmgc, zlib, sqlite, pcre, cmake, pkgconfig
|
||||
, git, apacheHttpd, apr, aprutil, mariadb, mbedtls, openssl, pkgs, gtk2, libpthreadstubs
|
||||
, git, apacheHttpd, apr, aprutil, mysql, mbedtls, openssl, pkgs, gtk2, libpthreadstubs
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
|
||||
nativeBuildInputs = [ cmake pkgconfig git ];
|
||||
buildInputs =
|
||||
[ boehmgc zlib sqlite pcre apacheHttpd apr aprutil
|
||||
mariadb.client mbedtls openssl libpthreadstubs ]
|
||||
mysql.connector-c mbedtls openssl libpthreadstubs ]
|
||||
++ stdenv.lib.optional stdenv.isLinux gtk2
|
||||
++ stdenv.lib.optionals stdenv.isDarwin [ pkgs.darwin.apple_sdk.frameworks.Security
|
||||
pkgs.darwin.apple_sdk.frameworks.Carbon];
|
||||
|
@ -91,7 +91,7 @@ stdenv.mkDerivation rec {
|
||||
|
||||
# Specifying $SBCL_HOME is only truly needed with `purgeNixReferences = true`.
|
||||
setupHook = writeText "setupHook.sh" ''
|
||||
envHooks+=(_setSbclHome)
|
||||
addEnvHooks "$targetOffset" _setSbclHome
|
||||
_setSbclHome() {
|
||||
export SBCL_HOME='@out@/lib/sbcl/'
|
||||
}
|
||||
|
@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "17qh9mcmlhbv6r52yij8l9ik7j7x6x7c09lf6pznnbdh4sf8p5wb";
|
||||
};
|
||||
|
||||
buildInputs = [ openssl mlton mysql.client postgresql sqlite ];
|
||||
buildInputs = [ openssl mlton mysql.connector-c postgresql sqlite ];
|
||||
|
||||
prePatch = ''
|
||||
sed -e 's@/usr/bin/file@${file}/bin/file@g' -i configure
|
||||
@ -21,13 +21,13 @@ stdenv.mkDerivation rec {
|
||||
|
||||
preConfigure = ''
|
||||
export PGHEADER="${postgresql}/include/libpq-fe.h";
|
||||
export MSHEADER="${lib.getDev mysql.client}/include/mysql/mysql.h";
|
||||
export MSHEADER="${mysql.connector-c}/include/mysql/mysql.h";
|
||||
export SQHEADER="${sqlite.dev}/include/sqlite3.h";
|
||||
|
||||
export CC="${gcc}/bin/gcc";
|
||||
export CCARGS="-I$out/include \
|
||||
-L${openssl.out}/lib \
|
||||
-L${lib.getLib mysql.client}/lib \
|
||||
-L${mysql.connector-c}/lib \
|
||||
-L${postgresql.lib}/lib \
|
||||
-L${sqlite.out}/lib";
|
||||
'';
|
||||
|
@ -29,6 +29,12 @@ let
|
||||
|
||||
in rec {
|
||||
|
||||
vala_0_23 = generic {
|
||||
major = "0.23";
|
||||
minor = "3";
|
||||
sha256 = "101xjbc818g4849n9a80c2aai13zakj7mpnd7470xnkvz5jwqq96";
|
||||
};
|
||||
|
||||
vala_0_26 = generic {
|
||||
major = "0.26";
|
||||
minor = "2";
|
||||
@ -37,8 +43,8 @@ in rec {
|
||||
|
||||
vala_0_28 = generic {
|
||||
major = "0.28";
|
||||
minor = "0";
|
||||
sha256 = "0zwpzhkhfk3piya14m7p2hl2vaabahprphppfm46ci91z39kp7hd";
|
||||
minor = "1";
|
||||
sha256 = "0isg327w6rfqqdjja6a8pc3xcdkj7pqrkdhw48bsyxab2fkaw3hw";
|
||||
};
|
||||
|
||||
vala_0_32 = generic {
|
||||
@ -49,14 +55,20 @@ in rec {
|
||||
|
||||
vala_0_34 = generic {
|
||||
major = "0.34";
|
||||
minor = "1";
|
||||
sha256 = "16cjybjw100qps6jg0jdyjh8hndz8a876zmxpybnf30a8vygrk7m";
|
||||
minor = "13";
|
||||
sha256 = "0ahbnhgwhhjkndmbr1d039ws0g2bb324c60fk6wgx7py5wvmgcd2";
|
||||
};
|
||||
|
||||
vala_0_36 = generic {
|
||||
major = "0.36";
|
||||
minor = "8";
|
||||
sha256 = "1nz5a8kcb22ss9idb7k1higwpvghd617xwf40fi0a9ggws614lfz";
|
||||
};
|
||||
|
||||
vala_0_38 = generic {
|
||||
major = "0.38";
|
||||
minor = "1";
|
||||
sha256 = "112hl3lkcyakrk8c3qgw12gzn3nxjkvx7bn0jhl5f2m57d7k8d8h";
|
||||
minor = "4";
|
||||
sha256 = "1sg5gaq3jhgr9vzh2ypiw475167k150wmyglymr7wwqppmikmcrc";
|
||||
extraNativeBuildInputs = [ autoconf ] ++ stdenv.lib.optionals stdenv.isDarwin [ libtool expat ];
|
||||
extraBuildInputs = [ graphviz ];
|
||||
};
|
||||
|
@ -70,7 +70,7 @@ self: super: {
|
||||
|
||||
# Use the default version of mysql to build this package (which is actually mariadb).
|
||||
# test phase requires networking
|
||||
mysql = dontCheck (super.mysql.override { mysql = pkgs.mysql.lib; });
|
||||
mysql = dontCheck (super.mysql.override { mysql = pkgs.mysql.connector-c; });
|
||||
|
||||
# check requires mysql server
|
||||
mysql-simple = dontCheck super.mysql-simple;
|
||||
|
@ -53,7 +53,7 @@ self: super: builtins.intersectAttrs super {
|
||||
|
||||
# Use the default version of mysql to build this package (which is actually mariadb).
|
||||
# test phase requires networking
|
||||
mysql = dontCheck (super.mysql.override { mysql = pkgs.mysql.lib; });
|
||||
mysql = dontCheck (super.mysql.override { mysql = pkgs.mysql.connector-c; });
|
||||
|
||||
# CUDA needs help finding the SDK headers and libraries.
|
||||
cuda = overrideCabal super.cuda (drv: {
|
||||
|
@ -222,8 +222,8 @@ stdenv.mkDerivation ({
|
||||
setupCompileFlags="${concatStringsSep " " setupCompileFlags}"
|
||||
configureFlags="${concatStringsSep " " defaultConfigureFlags} $configureFlags"
|
||||
|
||||
# nativePkgs defined in stdenv/setup.hs
|
||||
for p in "''${nativePkgs[@]}"; do
|
||||
# host.*Pkgs defined in stdenv/setup.hs
|
||||
for p in "''${pkgsHostHost[@]}" "''${pkgsHostTarget[@]}"; do
|
||||
if [ -d "$p/lib/${ghc.name}/package.conf.d" ]; then
|
||||
cp -f "$p/lib/${ghc.name}/package.conf.d/"*.conf $packageConfDir/
|
||||
continue
|
||||
|
@ -18,7 +18,8 @@
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks+=(addIdrisLibs)
|
||||
# All run-time deps
|
||||
addEnvHooks 0 addIdrisLibs
|
||||
'';
|
||||
|
||||
buildPhase = ''
|
||||
|
@ -14,7 +14,7 @@
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks+=(installIdrisLib)
|
||||
envHostTargetHooks+=(installIdrisLib)
|
||||
'';
|
||||
|
||||
unpackPhase = ''
|
||||
|
@ -2,4 +2,4 @@ addErlLibPath() {
|
||||
addToSearchPath ERL_LIBS $1/lib/elixir/lib
|
||||
}
|
||||
|
||||
envHooks+=(addErlLibPath)
|
||||
addEnvHooks "$hostOffset" addErlLibPath
|
||||
|
@ -2,4 +2,4 @@ addErlangLibPath() {
|
||||
addToSearchPath ERL_LIBS $1/lib/erlang/lib
|
||||
}
|
||||
|
||||
envHooks+=(addErlangLibPath)
|
||||
addEnvHooks "$hostOffset" addErlangLibPath
|
||||
|
@ -10,4 +10,4 @@ addGuileLibPath () {
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks+=(addGuileLibPath)
|
||||
addEnvHooks "$hostOffset" addGuileLibPath
|
||||
|
@ -10,4 +10,4 @@ addGuileLibPath () {
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks+=(addGuileLibPath)
|
||||
addEnvHooks "$hostOffset" addGuileLibPath
|
||||
|
@ -5,4 +5,4 @@ addGuileLibPath () {
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks+=(addGuileLibPath)
|
||||
addEnvHooks "$hostOffset" addGuileLibPath
|
||||
|
@ -36,7 +36,7 @@ jruby = stdenv.mkDerivation rec {
|
||||
addToSearchPath GEM_PATH \$1/${passthru.gemPath}
|
||||
}
|
||||
|
||||
envHooks+=(addGemPath)
|
||||
addEnvHooks "$hostOffset" addGemPath
|
||||
EOF
|
||||
'';
|
||||
|
||||
|
@ -2,4 +2,4 @@ addPerlLibPath () {
|
||||
addToSearchPath PERL5LIB $1/lib/perl5/site_perl
|
||||
}
|
||||
|
||||
envHooks+=(addPerlLibPath)
|
||||
addEnvHooks "$hostOffset" addPerlLibPath
|
||||
|
@ -12,9 +12,8 @@ let
|
||||
{ version, sha256 }:
|
||||
|
||||
let php7 = lib.versionAtLeast version "7.0";
|
||||
mysqlHeaders = mysql.lib.dev or mysql;
|
||||
mysqlndSupport = config.php.mysqlnd or false;
|
||||
mysqlBuildInputs = lib.optional (!mysqlndSupport) mysqlHeaders;
|
||||
mysqlBuildInputs = lib.optional (!mysqlndSupport) mysql.connector-c;
|
||||
|
||||
in composableDerivation.composableDerivation {} (fixed: {
|
||||
|
||||
@ -121,7 +120,7 @@ let
|
||||
};
|
||||
|
||||
mysqli = {
|
||||
configureFlags = ["--with-mysqli=${if mysqlndSupport then "mysqlnd" else "${mysqlHeaders}/bin/mysql_config"}"];
|
||||
configureFlags = ["--with-mysqli=${if mysqlndSupport then "mysqlnd" else "${mysql.connector-c}/bin/mysql_config"}"];
|
||||
buildInputs = mysqlBuildInputs;
|
||||
};
|
||||
|
||||
@ -132,7 +131,7 @@ let
|
||||
};
|
||||
|
||||
pdo_mysql = {
|
||||
configureFlags = ["--with-pdo-mysql=${if mysqlndSupport then "mysqlnd" else mysqlHeaders}"];
|
||||
configureFlags = ["--with-pdo-mysql=${if mysqlndSupport then "mysqlnd" else mysql.connector-c}"];
|
||||
buildInputs = mysqlBuildInputs;
|
||||
};
|
||||
|
||||
|
@ -13,7 +13,10 @@
|
||||
|
||||
{ name ? "${attrs.pname}-${attrs.version}"
|
||||
|
||||
# Dependencies for building the package
|
||||
# Build-time dependencies for the package
|
||||
, nativeBuildInputs ? []
|
||||
|
||||
# Run-time dependencies for the package
|
||||
, buildInputs ? []
|
||||
|
||||
# Dependencies needed for running the checkPhase.
|
||||
@ -66,13 +69,15 @@ toPythonModule (python.stdenv.mkDerivation (builtins.removeAttrs attrs [
|
||||
|
||||
name = namePrefix + name;
|
||||
|
||||
buildInputs = ([ wrapPython (ensureNewerSourcesHook { year = "1980"; }) ]
|
||||
++ (lib.optional (lib.hasSuffix "zip" attrs.src.name or "") unzip)
|
||||
nativeBuildInputs = [ (ensureNewerSourcesHook { year = "1980"; }) ]
|
||||
++ nativeBuildInputs;
|
||||
|
||||
buildInputs = [ wrapPython ]
|
||||
++ lib.optional (lib.hasSuffix "zip" (attrs.src.name or "")) unzip
|
||||
++ lib.optionals doCheck checkInputs
|
||||
++ lib.optional catchConflicts setuptools # If we nog longer propagate setuptools
|
||||
++ lib.optional catchConflicts setuptools # If we no longer propagate setuptools
|
||||
++ buildInputs
|
||||
++ pythonPath
|
||||
);
|
||||
++ pythonPath;
|
||||
|
||||
# Propagate python and setuptools. We should stop propagating setuptools.
|
||||
propagatedBuildInputs = propagatedBuildInputs ++ [ python setuptools ];
|
||||
|
@ -12,10 +12,13 @@ toPythonPath() {
|
||||
echo $result
|
||||
}
|
||||
|
||||
envHooks+=(addPythonPath)
|
||||
addEnvHooks "$hostOffset" addPythonPath
|
||||
|
||||
# Determinism: The interpreter is patched to write null timestamps when compiling python files.
|
||||
# This way python doesn't try to update them when we freeze timestamps in nix store.
|
||||
export DETERMINISTIC_BUILD=1;
|
||||
# Determinism: We fix the hashes of str, bytes and datetime objects.
|
||||
export PYTHONHASHSEED=0;
|
||||
# Determinism. Whenever Python is included, it should not check user site-packages.
|
||||
# This option is only relevant when the sandbox is disabled.
|
||||
export PYTHONNOUSERSITE=1;
|
||||
|
@ -150,7 +150,7 @@ let
|
||||
addToSearchPath GEM_PATH \$1/${passthru.gemPath}
|
||||
}
|
||||
|
||||
envHooks+=(addGemPath)
|
||||
addEnvHooks "$hostOffset" addGemPath
|
||||
EOF
|
||||
'' + opString useRailsExpress ''
|
||||
rbConfig=$(find $out/lib/ruby -name rbconfig.rb)
|
||||
|
@ -4,8 +4,4 @@ addSDLPath () {
|
||||
fi
|
||||
}
|
||||
|
||||
if test -n "$crossConfig"; then
|
||||
crossEnvHooks+=(addSDLPath)
|
||||
else
|
||||
envHooks+=(addSDLPath)
|
||||
fi
|
||||
addEnvHooks "$hostOffset" addSDLPath
|
||||
|
@ -4,8 +4,4 @@ addSDL2Path () {
|
||||
fi
|
||||
}
|
||||
|
||||
if test -n "$crossConfig"; then
|
||||
crossEnvHooks+=(addSDL2Path)
|
||||
else
|
||||
envHooks+=(addSDL2Path)
|
||||
fi
|
||||
addEnvHooks "$hostOffset" addSDL2Path
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user