mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-18 02:05:51 +03:00
soil: fix dead url, enable on darwin
This commit is contained in:
parent
cb9fab88c3
commit
981c8bb5e2
@ -1,28 +1,45 @@
|
||||
{ stdenv, fetchurl, unzip, mesa, libX11, libGL }:
|
||||
{ stdenv, lib
|
||||
, Carbon
|
||||
, fetchzip
|
||||
, libGL
|
||||
, libX11
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "soil";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://www.lonesock.net/files/soil.zip";
|
||||
sha256 = "00gpwp9dldzhsdhksjvmbhsd2ialraqbv6v6dpikdmpncj6mnc52";
|
||||
src = fetchzip {
|
||||
url = "https://web.archive.org/web/20200104042737id_/http://www.lonesock.net/files/soil.zip";
|
||||
sha256 = "1c05nwbnfdgwaz8ywn7kg2xrcvrcbpdyhcfkkiiwk69zvil0pbgd";
|
||||
};
|
||||
|
||||
buildInputs = [ unzip mesa libGL libX11 ];
|
||||
buildInputs = if stdenv.hostPlatform.isDarwin then [
|
||||
Carbon
|
||||
] else [
|
||||
libGL
|
||||
libX11
|
||||
];
|
||||
|
||||
sourceRoot = "Simple OpenGL Image Library/projects/makefile";
|
||||
preBuild = "mkdir obj";
|
||||
preInstall = "mkdir -p $out/lib $out/include";
|
||||
makeFlags = [ "LOCAL=$(out)" ];
|
||||
buildPhase = ''
|
||||
cd src
|
||||
$CC $NIX_CFLAGS_COMPILE -c *.c
|
||||
$AR rcs libSOIL.a *.o
|
||||
'';
|
||||
installPhase = ''
|
||||
mkdir -p $out/lib $out/include/SOIL
|
||||
cp libSOIL.a $out/lib/
|
||||
cp SOIL.h $out/include/SOIL/
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Simple OpenGL Image Library";
|
||||
meta = with lib; {
|
||||
description = "Simple OpenGL Image Library";
|
||||
longDescription = ''
|
||||
SOIL is a tiny C library used primarily for uploading textures
|
||||
into OpenGL.
|
||||
'';
|
||||
homepage = "https://www.lonesock.net/soil.html";
|
||||
license = stdenv.lib.licenses.publicDomain;
|
||||
platforms = stdenv.lib.platforms.linux;
|
||||
homepage = "https://www.lonesock.net/soil.html";
|
||||
license = licenses.publicDomain;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ r-burns ];
|
||||
};
|
||||
}
|
||||
|
@ -15704,7 +15704,9 @@ in
|
||||
|
||||
sofia_sip = callPackage ../development/libraries/sofia-sip { };
|
||||
|
||||
soil = callPackage ../development/libraries/soil { };
|
||||
soil = callPackage ../development/libraries/soil {
|
||||
inherit (darwin.apple_sdk.frameworks) Carbon;
|
||||
};
|
||||
|
||||
sonic = callPackage ../development/libraries/sonic { };
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user