-
-
Notifications
You must be signed in to change notification settings - Fork 14k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- nixfmt-rfc-style - finalAttrs - strictDeps - hammer - no nested with - more meta attrs
- Loading branch information
1 parent
7b129f2
commit 5deaa11
Showing
1 changed file
with
52 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,46 +1,79 @@ | ||
{ lib, stdenv, fetchFromGitLab, makeWrapper, gcc, ncurses }: | ||
{ | ||
lib, | ||
fetchFromGitLab, | ||
makeWrapper, | ||
ncurses, | ||
stdenv, | ||
}: | ||
|
||
stdenv.mkDerivation rec { | ||
stdenv.mkDerivation (finalAttrs: { | ||
pname = "icmake"; | ||
version = "9.03.01"; | ||
|
||
src = fetchFromGitLab { | ||
sha256 = "05r0a69w0hv2qhjpb2bxd0lmp2vv5r2d4iggg6ly4miam0i318jy"; | ||
rev = version; | ||
repo = "icmake"; | ||
owner = "fbb-git"; | ||
repo = "icmake"; | ||
rev = finalAttrs.version; | ||
hash = "sha256-XqIwIqgqVuKpee9F0kQue4tbKWh9iXUlxGJDwJNRIBc="; | ||
}; | ||
|
||
nativeBuildInputs = [ makeWrapper ]; | ||
|
||
setSourceRoot = '' | ||
sourceRoot=$(echo */icmake) | ||
''; | ||
sourceRoot = "${finalAttrs.src.name}/icmake"; | ||
|
||
nativeBuildInputs = [ makeWrapper ]; | ||
buildInputs = [ gcc ]; | ||
strictDeps = true; | ||
|
||
preConfigure = '' | ||
postPatch = '' | ||
patchShebangs ./ | ||
substituteInPlace INSTALL.im --replace "usr/" "" | ||
substituteInPlace INSTALL.im \ | ||
--replace-fail "usr/" "" | ||
''; | ||
|
||
buildPhase = '' | ||
runHook preBuild | ||
./icm_prepare $out | ||
./icm_bootstrap x | ||
runHook postBuild | ||
''; | ||
|
||
installPhase = '' | ||
runHook preInstall | ||
./icm_install all / | ||
wrapProgram $out/bin/icmbuild \ | ||
--prefix PATH : ${ncurses}/bin | ||
--prefix PATH : ${lib.getBin ncurses}/bin | ||
runHook postInstall | ||
''; | ||
|
||
meta = with lib; { | ||
description = "Program maintenance (make) utility using a C-like grammar"; | ||
meta = { | ||
homepage = "https://fbb-git.gitlab.io/icmake/"; | ||
license = licenses.gpl3; | ||
maintainers = with maintainers; [ pSub ]; | ||
platforms = platforms.linux; | ||
description = "Program maintenance utility using a C-like grammar"; | ||
longDescription = '' | ||
Icmake can be used as an alternative to make(1). | ||
Icmake allows the programmer to use a program language (closely resembling | ||
the well-known C-programming language) to define the actions involved in | ||
(complex) program maintenance. For this, icmake offers various special | ||
operators as well as a set of support functions that have proven to be | ||
useful in program maintenance. | ||
Traditional make-utilities recompile sources once header files are | ||
modified. In the context of C++ program development this is often a bad | ||
idea, as adding a new member to a class does not normally require you to | ||
recompile the class's sources. To handle class dependencies in a more | ||
sensible way, icmake's CLASSES file may define dependencies among | ||
classes. By default, class-dependencies are not interpreted. | ||
''; | ||
license = lib.licenses.gpl3; | ||
mainProgram = "icmake"; | ||
maintainers = with lib.maintainers; [ | ||
pSub | ||
AndersonTorres | ||
]; | ||
platforms = lib.platforms.all; | ||
}; | ||
} | ||
}) |