wok-4.x rev 8810

Got btrfs-progs to compile. Couldn't compile btrfs-convert though.
author Christopher Rogers <slaxemulator@gmail.com>
date Tue Feb 22 20:50:37 2011 +0000 (2011-02-22)
parents a78433086aa5
children 7665643f32d5
files btrfs-progs/receipt btrfs-progs/stuff/btrfs-progs-build-fixes.patch
line diff
     1.1 --- a/btrfs-progs/receipt	Wed Feb 23 02:20:47 2011 +0100
     1.2 +++ b/btrfs-progs/receipt	Tue Feb 22 20:50:37 2011 +0000
     1.3 @@ -16,7 +16,8 @@
     1.4  compile_rules()
     1.5  {
     1.6  	cd $src
     1.7 -	make all convert &&
     1.8 +	patch -Np1 -i $stuff/btrfs-progs-build-fixes.patch
     1.9 +	make all &&
    1.10  	make DESTDIR=$PWD/_pkg prefix=/usr install
    1.11  }
    1.12  
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/btrfs-progs/stuff/btrfs-progs-build-fixes.patch	Tue Feb 22 20:50:37 2011 +0000
     2.3 @@ -0,0 +1,32 @@
     2.4 +--- btrfs-progs-0.19/btrfsck.c	
     2.5 ++++ btrfs-progs-0.19/btrfsck.c	
     2.6 +@@ -21,6 +21,9 @@ 
     2.7 + #include <stdio.h>
     2.8 + #include <stdlib.h>
     2.9 + #include <fcntl.h>
    2.10 ++#include <sys/types.h>
    2.11 ++#include <sys/stat.h>
    2.12 ++#include <unistd.h>
    2.13 + #include "kerncompat.h"
    2.14 + #include "ctree.h"
    2.15 + #include "disk-io.h"
    2.16 +--- btrfs-progs-0.19/mkfs.c	
    2.17 ++++ btrfs-progs-0.19/mkfs.c	
    2.18 +@@ -341,7 +341,7 @@ int main(int ac, char **av)
    2.19 + 	u64 alloc_start = 0;
    2.20 + 	u64 metadata_profile = BTRFS_BLOCK_GROUP_RAID1 | BTRFS_BLOCK_GROUP_DUP;
    2.21 + 	u64 data_profile = BTRFS_BLOCK_GROUP_RAID0;
    2.22 +-	u32 leafsize = getpagesize();
    2.23 ++	u32 leafsize = sysconf(_SC_PAGESIZE);
    2.24 + 	u32 sectorsize = 4096;
    2.25 + 	u32 nodesize = leafsize;
    2.26 + 	u32 stripesize = 4096;
    2.27 +@@ -398,7 +398,7 @@ int main(int ac, char **av)
    2.28 + 				print_usage();
    2.29 + 		}
    2.30 + 	}
    2.31 +-	sectorsize = max(sectorsize, (u32)getpagesize());
    2.32 ++	sectorsize = max(sectorsize, (u32)sysconf(_SC_PAGESIZE));
    2.33 + 	if (leafsize < sectorsize || (leafsize & (sectorsize - 1))) {
    2.34 + 		fprintf(stderr, "Illegal leafsize %u\n", leafsize);
    2.35 + 		exit(1);