bsd: `BSD_PATH` rename to `COMPONENT_PATH`

@alyssais and I agreed this is clearer.

+14 -14
+11 -11
pkgs/os-specific/bsd/netbsd/default.nix
··· 94 }.${stdenv'.hostPlatform.parsed.cpu.name} 95 or stdenv'.hostPlatform.parsed.cpu.name; 96 97 - BSD_PATH = attrs.path; 98 99 makeFlags = defaultMakeFlags; 100 ··· 126 postPatch = lib.optionalString (!stdenv'.hostPlatform.isNetBSD) '' 127 set +e 128 grep -Zlr "^__RCSID 129 - ^__BEGIN_DECLS" $BSD_PATH | xargs -0r grep -FLZ nbtool_config.h | 130 xargs -0tr sed -i '0,/^#/s//#include <nbtool_config.h>\n\0/' 131 set -e 132 '' + attrs.postPatch or ""; ··· 146 skipIncludesPhase = true; 147 148 postPatch = '' 149 - patchShebangs $BSD_PATH/configure 150 ${self.make.postPatch} 151 ''; 152 ··· 707 SHLIBINSTALLDIR = "$(out)/lib"; 708 makeFlags = defaultMakeFlags ++ [ "LIBDO.terminfo=${self.libterminfo}/lib" ]; 709 postPatch = '' 710 - sed -i '1i #undef bool_t' $BSD_PATH/el.h 711 - substituteInPlace $BSD_PATH/config.h \ 712 --replace "#define HAVE_STRUCT_DIRENT_D_NAMLEN 1" "" 713 - substituteInPlace $BSD_PATH/readline/Makefile --replace /usr/include "$out/include" 714 ''; 715 NIX_CFLAGS_COMPILE = [ 716 "-D__noinline=" ··· 730 buildInputs = with self; compatIfNeeded; 731 SHLIBINSTALLDIR = "$(out)/lib"; 732 postPatch = '' 733 - substituteInPlace $BSD_PATH/term.c --replace /usr/share $out/share 734 - substituteInPlace $BSD_PATH/setupterm.c \ 735 --replace '#include <curses.h>' 'void use_env(bool);' 736 ''; 737 postBuild = '' ··· 759 MKDOC = "no"; # missing vfontedpr 760 makeFlags = defaultMakeFlags ++ [ "LIBDO.terminfo=${self.libterminfo}/lib" ]; 761 postPatch = lib.optionalString (!stdenv.isDarwin) '' 762 - substituteInPlace $BSD_PATH/printw.c \ 763 --replace "funopen(win, NULL, __winwrite, NULL, NULL)" NULL \ 764 --replace "__strong_alias(vwprintw, vw_printw)" 'extern int vwprintw(WINDOW*, const char*, va_list) __attribute__ ((alias ("vw_printw")));' 765 - substituteInPlace $BSD_PATH/scanw.c \ 766 --replace "__strong_alias(vwscanw, vw_scanw)" 'extern int vwscanw(WINDOW*, const char*, va_list) __attribute__ ((alias ("vw_scanw")));' 767 ''; 768 }; ··· 987 # man0 generates a man.pdf using ps2pdf, but doesn't install it later, 988 # so we can avoid the dependency on ghostscript 989 postPatch = '' 990 - substituteInPlace $BSD_PATH/man0/Makefile --replace "ps2pdf" "echo noop " 991 ''; 992 makeFlags = defaultMakeFlags ++ [ 993 "FILESDIR=$(out)/share"
··· 94 }.${stdenv'.hostPlatform.parsed.cpu.name} 95 or stdenv'.hostPlatform.parsed.cpu.name; 96 97 + COMPONENT_PATH = attrs.path; 98 99 makeFlags = defaultMakeFlags; 100 ··· 126 postPatch = lib.optionalString (!stdenv'.hostPlatform.isNetBSD) '' 127 set +e 128 grep -Zlr "^__RCSID 129 + ^__BEGIN_DECLS" $COMPONENT_PATH | xargs -0r grep -FLZ nbtool_config.h | 130 xargs -0tr sed -i '0,/^#/s//#include <nbtool_config.h>\n\0/' 131 set -e 132 '' + attrs.postPatch or ""; ··· 146 skipIncludesPhase = true; 147 148 postPatch = '' 149 + patchShebangs $COMPONENT_PATH/configure 150 ${self.make.postPatch} 151 ''; 152 ··· 707 SHLIBINSTALLDIR = "$(out)/lib"; 708 makeFlags = defaultMakeFlags ++ [ "LIBDO.terminfo=${self.libterminfo}/lib" ]; 709 postPatch = '' 710 + sed -i '1i #undef bool_t' $COMPONENT_PATH/el.h 711 + substituteInPlace $COMPONENT_PATH/config.h \ 712 --replace "#define HAVE_STRUCT_DIRENT_D_NAMLEN 1" "" 713 + substituteInPlace $COMPONENT_PATH/readline/Makefile --replace /usr/include "$out/include" 714 ''; 715 NIX_CFLAGS_COMPILE = [ 716 "-D__noinline=" ··· 730 buildInputs = with self; compatIfNeeded; 731 SHLIBINSTALLDIR = "$(out)/lib"; 732 postPatch = '' 733 + substituteInPlace $COMPONENT_PATH/term.c --replace /usr/share $out/share 734 + substituteInPlace $COMPONENT_PATH/setupterm.c \ 735 --replace '#include <curses.h>' 'void use_env(bool);' 736 ''; 737 postBuild = '' ··· 759 MKDOC = "no"; # missing vfontedpr 760 makeFlags = defaultMakeFlags ++ [ "LIBDO.terminfo=${self.libterminfo}/lib" ]; 761 postPatch = lib.optionalString (!stdenv.isDarwin) '' 762 + substituteInPlace $COMPONENT_PATH/printw.c \ 763 --replace "funopen(win, NULL, __winwrite, NULL, NULL)" NULL \ 764 --replace "__strong_alias(vwprintw, vw_printw)" 'extern int vwprintw(WINDOW*, const char*, va_list) __attribute__ ((alias ("vw_printw")));' 765 + substituteInPlace $COMPONENT_PATH/scanw.c \ 766 --replace "__strong_alias(vwscanw, vw_scanw)" 'extern int vwscanw(WINDOW*, const char*, va_list) __attribute__ ((alias ("vw_scanw")));' 767 ''; 768 }; ··· 987 # man0 generates a man.pdf using ps2pdf, but doesn't install it later, 988 # so we can avoid the dependency on ghostscript 989 postPatch = '' 990 + substituteInPlace $COMPONENT_PATH/man0/Makefile --replace "ps2pdf" "echo noop " 991 ''; 992 makeFlags = defaultMakeFlags ++ [ 993 "FILESDIR=$(out)/share"
+3 -3
pkgs/os-specific/bsd/setup-hook.sh
··· 66 } 67 68 cdBSDPath() { 69 - if [ -d "$BSD_PATH" ] 70 - then sourceRoot=$sourceRoot/$BSD_PATH 71 - cd $BSD_PATH 72 fi 73 } 74
··· 66 } 67 68 cdBSDPath() { 69 + if [ -d "$COMPONENT_PATH" ] 70 + then sourceRoot=$sourceRoot/$COMPONENT_PATH 71 + cd $COMPONENT_PATH 72 fi 73 } 74