anchor.diff:  
           # Copy the populated /boot into the SD image
           (cd boot; mcopy -bpsvm -i ../bootpart.img ./* ::)
  -        dd conv=notrunc if=bootpart.img of=$out seek=$START count=$SECTORS
  +        dd conv=notrunc if=bootpart.img of=$img seek=$START count=$SECTORS
         '';
       };
   
  
positive.code: in
  {
    options.sdImage = {
      storePaths = mkOption {
        type = with types; listOf package;
        example = literalExample "[ pkgs.stdenv ]";
  
negative.code:         EOF
  
          # Copy the rootfs into the SD image
          eval $(partx $img -o START,SECTORS --nr 2 --pairs)
          dd conv=notrunc if=${rootfsImage} of=$img seek=$START count=$SECTORS
  
          # Create a FAT32 /boot partition of suitable size into bootpart.img
          eval $(partx $img -o START,SECTORS --nr 1 --pairs)
          truncate -s $((SECTORS * 512)) bootpart.img
          faketime "1970-01-01 00:00:00" mkfs.vfat -i 0x2178694e -n NIXOS_BOOT bootpart.img
  
  