mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-08 14:03:29 +00:00
571c71e6f7
We are migrating packages that meet below requirements: 1. using `callPackage` 2. called path is a directory 3. overriding set is empty (`{ }`) 4. not containing path expressions other than relative path (to makenixpkgs-vet happy) 5. not referenced by nix files outside of the directory, other than`pkgs/top-level/all-packages.nix` 6. not referencing nix files outside of the directory 7. not referencing `default.nix` (since it's changed to `package.nix`) 8. `outPath` doesn't change after migration The tool is here: https://github.com/Aleksanaa/by-name-migrate.
49 lines
1.3 KiB
Nix
49 lines
1.3 KiB
Nix
{ fetchurl, lib, stdenv, pkg-config, autoreconfHook, gettext, glib, buildPackages }:
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "gts";
|
|
version = "0.7.6";
|
|
|
|
outputs = [ "bin" "dev" "out" ];
|
|
|
|
src = fetchurl {
|
|
url = "mirror://sourceforge/gts/${pname}-${version}.tar.gz";
|
|
sha256 = "07mqx09jxh8cv9753y2d2jsv7wp8vjmrd7zcfpbrddz3wc9kx705";
|
|
};
|
|
|
|
nativeBuildInputs = [
|
|
pkg-config
|
|
autoreconfHook
|
|
glib # required to satisfy AM_PATH_GLIB_2_0
|
|
];
|
|
buildInputs = [ gettext ];
|
|
propagatedBuildInputs = [ glib ];
|
|
|
|
doCheck = false; # fails with "permission denied"
|
|
|
|
preBuild = lib.optionalString (stdenv.hostPlatform != stdenv.buildPlatform) ''
|
|
pushd src
|
|
make CC=${buildPackages.stdenv.cc}/bin/cc predicates_init
|
|
mv predicates_init predicates_init_build
|
|
make clean
|
|
popd
|
|
|
|
substituteInPlace src/Makefile --replace "./predicates_init" "./predicates_init_build"
|
|
'';
|
|
|
|
meta = {
|
|
homepage = "https://gts.sourceforge.net/";
|
|
license = lib.licenses.lgpl2Plus;
|
|
description = "GNU Triangulated Surface Library";
|
|
|
|
longDescription = ''
|
|
Library intended to provide a set of useful functions to deal with
|
|
3D surfaces meshed with interconnected triangles.
|
|
'';
|
|
|
|
maintainers = [ ];
|
|
platforms = lib.platforms.linux ++ lib.platforms.darwin;
|
|
};
|
|
}
|