2015-02-08 06:53:52 +00:00
|
|
|
{ stdenv, appleDerivation, version }:
|
|
|
|
|
|
|
|
appleDerivation {
|
|
|
|
# Will override the name until we provide all of adv_cmds
|
|
|
|
buildPhase = ''
|
2015-06-18 04:52:27 +01:00
|
|
|
pushd ps
|
2015-02-08 06:53:52 +00:00
|
|
|
cc -Os -Wall -I. -c -o fmt.o fmt.c
|
|
|
|
cc -Os -Wall -I. -c -o keyword.o keyword.c
|
|
|
|
cc -Os -Wall -I. -c -o nlist.o nlist.c
|
|
|
|
cc -Os -Wall -I. -c -o print.o print.c
|
|
|
|
cc -Os -Wall -I. -c -o ps.o ps.c
|
|
|
|
cc -Os -Wall -I. -c -o tasks.o tasks.c
|
|
|
|
cc -o ps fmt.o keyword.o nlist.o print.o ps.o tasks.o
|
2015-06-18 04:52:27 +01:00
|
|
|
popd
|
|
|
|
|
|
|
|
pushd locale
|
|
|
|
c++ -o locale locale.cc
|
|
|
|
popd
|
2015-02-08 06:53:52 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin $out/share/man/man1
|
|
|
|
|
2015-06-18 04:52:27 +01:00
|
|
|
cp ps/ps $out/bin/ps
|
|
|
|
cp ps/ps.1 $out/share/man/man1
|
|
|
|
cp locale/locale $out/bin/locale
|
|
|
|
cp locale/locale.1 $out/share/man/man1
|
2015-02-08 06:53:52 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
platforms = stdenv.lib.platforms.darwin;
|
|
|
|
maintainers = with stdenv.lib.maintainers; [ gridaphobe ];
|
|
|
|
};
|
|
|
|
}
|