Skip to content

Instantly share code, notes, and snippets.

@tokudan
Created August 30, 2017 21:30
Show Gist options
  • Save tokudan/a75959cf13d89853145972525b30dde3 to your computer and use it in GitHub Desktop.
Save tokudan/a75959cf13d89853145972525b30dde3 to your computer and use it in GitHub Desktop.
#!/usr/bin/env nix-shell
#!nix-shell 16.03.nix
#!nix-shell -I nixpkgs=https://github.com/NixOS/nixpkgs-channels/archive/nixos-16.03.tar.gz
{ pkgs ? import <nixpkgs> {} }:
(pkgs.buildFHSUserEnv {
name = "fffirmware-env";
multiPkgs = pkgs: (with pkgs;
[
bzip2
curl
file
gawk
gcc
getopt
git
gnumake
ncurses
openssh
openssl
patch
perl
pkgconfig
python
subversion
unzip
vim
wget
which
zlib
]);
}).env
#!/usr/bin/env nix-shell
#!nix-shell 17.03.nix
{ pkgs ? import <nixpkgs> {} }:
(pkgs.buildFHSUserEnv {
name = "fffirmware-env";
multiPkgs = pkgs: (with pkgs;
[
bzip2 bzip2.bin bzip2.dev bzip2.man
curl curl.bin curl.dev curl.devdoc curl.man
file
gawk gawk.man gawk.info
gcc6
getopt
git
gnumake gnumake.doc
ncurses5 ncurses5.dev ncurses5.man
openssh
openssl openssl.bin openssl.dev openssl.man
patch
perl perl.devdoc perl.man
pkgconfig
python
subversion subversion.dev subversion.man
unzip
vim
wget
which
zlib zlib.dev
]);
}).env
$ make GLUON_TARGET=ar71xx-generic
make[1] prepare-target
make[2] prepare-early make[3] feeds
make[4] prepare-tmpinfo make[3] gluon-tools make[4] tools/patch/install
make[5] -C tools/flock compile
make[5] -C tools/flock install
make[5] -C tools/tar compile
make[5] -C tools/tar install
make[5] -C tools/patch compile make[5] -C tools/patch install
make[4] tools/sed/install
make[5] -C tools/flock compile make[5] -C tools/flock install
make[5] -C tools/tar compile
make[5] -C tools/tar install
make[5] -C tools/patch compile
make[5] -C tools/patch install
make[5] -C tools/sed compile
make[5] -C tools/sed install
make[4] tools/cmake/install
make[5] -C tools/flock compile
make[5] -C tools/flock install
make[5] -C tools/tar compile
make[5] -C tools/tar install
make[5] -C tools/patch compile
make[5] -C tools/patch install
make[5] -C tools/cmake compile
make[5] -C tools/cmake install
make[4] package/lua/host/install package/usign/host/install
make[5] -C package/utils/lua host-install
make[5] -C package/system/usign host-install
make[2] config
make[2] config
make -C /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/openwrt -f /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/Makefile GLUON_TOOLS=0 QUILT= prepare-target: build failed. Please re-run make with V=s to see what's going on
make: *** [Makefile:68: prepare-target] Error 1
fffirmware-env-chrootenv:dfrank@freya:~/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x$ make GLUON_TARGET=ar71xx-generic V=s
make[1]: Entering directory '/home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/openwrt'
[ -s /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/gluon-opkg-key -a -s /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/gluon-opkg-key.pub ] || \
( mkdir -p $(dirname /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/gluon-opkg-key) && /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/openwrt/staging_dir/host/bin/usign -G -s /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/gluon-opkg-key -p /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/gluon-opkg-key.pub -c "Gluon opkg key" )
rm /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/ar71xx-generic/openwrt/tmp || true
rm: cannot remove '/home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/ar71xx-generic/openwrt/tmp': Is a directory
mkdir -p /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/ar71xx-generic/openwrt/tmp
for link in build_dir config Config.in dl include Makefile package rules.mk scripts staging_dir target toolchain tools; do \
ln -sf /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/openwrt/$link /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/ar71xx-generic/openwrt; \
done
PATH=/run/wrappers/bin:/usr/bin:/usr/sbin make -w -C /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/ar71xx-generic/openwrt -f /home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/Makefile config
make[2]: Entering directory '/home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/ar71xx-generic/openwrt'
make V=ss scripts/config/conf OPENWRT_BUILD= QUIET=0
make[3]: Entering directory '/home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/ar71xx-generic/openwrt'
make[4]: Entering directory '/home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/openwrt/scripts/config'
conf.c: In function 'check_stdin':
conf.c:77:3: error: format not a string literal and no format arguments [-Werror=format-security]
printf(_("aborted!\n\n"));
^~~~~~
conf.c:78:3: error: format not a string literal and no format arguments [-Werror=format-security]
printf(_("Console input/output is redirected. "));
^~~~~~
conf.c:79:3: error: format not a string literal and no format arguments [-Werror=format-security]
printf(_("Run 'make oldconfig' to update configuration.\n\n"));
^~~~~~
conf.c: In function 'conf_askvalue':
conf.c:89:3: error: format not a string literal and no format arguments [-Werror=format-security]
printf(_("(NEW) "));
^~~~~~
conf.c: In function 'conf_choice':
conf.c:290:5: error: format not a string literal and no format arguments [-Werror=format-security]
printf(_(" (NEW)"));
^~~~~~
conf.c: In function 'check_conf':
conf.c:438:6: error: format not a string literal and no format arguments [-Werror=format-security]
printf(_("*\n* Restart config...\n*\n"));
^~~~~~
conf.c: In function 'main':
conf.c:615:6: error: format not a string literal and no format arguments [-Werror=format-security]
_("\n*** The configuration requires explicit update.\n\n"));
^
conf.c:669:4: error: format not a string literal and no format arguments [-Werror=format-security]
fprintf(stderr, _("\n*** Error during writing of the configuration.\n\n"));
^~~~~~~
conf.c:673:4: error: format not a string literal and no format arguments [-Werror=format-security]
fprintf(stderr, _("\n*** Error during update of the configuration.\n\n"));
^~~~~~~
conf.c:684:4: error: format not a string literal and no format arguments [-Werror=format-security]
fprintf(stderr, _("\n*** Error during writing of the configuration.\n\n"));
^~~~~~~
cc1: some warnings being treated as errors
make[4]: *** [<builtin>: conf.o] Error 1
make[4]: Leaving directory '/home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/openwrt/scripts/config'
make[3]: *** [/home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/ar71xx-generic/openwrt/include/toplevel.mk:94: scripts/config/conf] Error 2
make[3]: Leaving directory '/home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/ar71xx-generic/openwrt'
make[2]: *** [/home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/Makefile:274: config] Error 2
make[2]: Leaving directory '/home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/build/ar71xx-generic/openwrt'
make[1]: *** [/home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/Makefile:296: prepare-target] Error 2
make[1]: Leaving directory '/home/dfrank/freifunk/freifunk.nix/gluon-v2016.2.x-ffhh-0.8.x/openwrt'
make: *** [Makefile:68: prepare-target] Error 2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment