Zheng Bao (zheng.bao(a)amd.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/11474
-gerrit
commit 2c8f7b9aa6446093b9395dcc763c01a2a3643195
Author: zbao <fishbaozi(a)gmail.com>
Date: Tue Sep 1 07:45:41 2015 -0400
buildgcc: Check free disk and warn if its size is too small
We can only warn but can not stop building, because if the user
saves the temp file the last time, the space might be enough.
3G is an estimated size, which is required when I build i386-elf.
Change-Id: Iae988300937018f166ff626b75c3a16bfa757ad9
Signed-off-by: Zheng Bao <zheng.bao(a)amd.com>
Signed-off-by: Zheng Bao <fishbaozi(a)gmail.com>
---
util/crossgcc/buildgcc | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/util/crossgcc/buildgcc b/util/crossgcc/buildgcc
index 49e41e5..ec633ac 100755
--- a/util/crossgcc/buildgcc
+++ b/util/crossgcc/buildgcc
@@ -288,6 +288,11 @@ cleanup()
printf "${green}ok${NC}\n"
}
+freedisk() {
+ avail=$(LC_ALL=C eval df -k ./ | sed 1d | awk '{print $4}')
+ test $avail -lt 3145728 && printf "${red}WARNING: There might be not enough space.${NC}\n"
+}
+
myhelp()
{
printf "Usage: $0 [-V] [-c] [-p <platform>] [-d <target directory>] [-D <dest dir>] [-C] [-G] [-S]\n"
@@ -583,6 +588,8 @@ case "$PACKAGE" in
;;
esac
+freedisk
+
# Find all the required tools:
TAR=$(searchtool tar) || exit $?
Patrick Georgi (pgeorgi(a)google.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/11475
-gerrit
commit ee495d9976d8f2dc811e79222cd20851ec34d5bf
Author: Patrick Georgi <patrick(a)georgi-clan.de>
Date: Tue Sep 1 12:37:41 2015 +0200
cbfstool: guard _Static_assert
This isn't required for correct execution, and doesn't need to be tested
on every single compiler out there.
Since GCC < 4.5 has no idea about _Static_assert, hide it there. Our
build tests will make sure that the test is run before changes are
submitted to master.
Change-Id: I4141f4aa23b140d2d1017ca7b4dace5aa7db0c04
Signed-off-by: Patrick Georgi <patrick(a)georgi-clan.de>
---
util/cbfstool/cbfs.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/util/cbfstool/cbfs.h b/util/cbfstool/cbfs.h
index 44e3dcd..d1b97c5 100644
--- a/util/cbfstool/cbfs.h
+++ b/util/cbfstool/cbfs.h
@@ -88,7 +88,9 @@ struct cbfs_file {
char filename[];
} __PACKED;
+#if defined __GNUC__ && (__GNUC__ * 100 + __GNUC_MINOR__) >= 405
_Static_assert(sizeof(struct cbfs_file) == 24, "cbfs_file size mismatch");
+#endif
/* The common fields of extended cbfs file attributes.
Attributes are expected to start with tag/len, then append their
Zheng Bao (zheng.bao(a)amd.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/11474
-gerrit
commit ce9446d6e0f7377833d769e6cc16f7088749c7a6
Author: zbao <fishbaozi(a)gmail.com>
Date: Mon Aug 31 22:58:42 2015 -0400
buildgcc: Check free disk and warn if its size is too small
We can only warn and can not stop building, because if the user
saves the temp file the last time, the space might be enough.
3G is a estimated size, which is required when I build i386-elf.
Change-Id: Iae988300937018f166ff626b75c3a16bfa757ad9
Signed-off-by: Zheng Bao <zheng.bao(a)amd.com>
Signed-off-by: Zheng Bao <fishbaozi(a)gmail.com>
---
util/crossgcc/buildgcc | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/util/crossgcc/buildgcc b/util/crossgcc/buildgcc
index 49e41e5..d25febf 100755
--- a/util/crossgcc/buildgcc
+++ b/util/crossgcc/buildgcc
@@ -338,6 +338,11 @@ GNU General Public License for more details.
EOF
}
+freedisk() {
+ avail=$(LC_ALL=C eval df -k ./ | sed 1d | awk '{print $4}')
+ test $avail -lt 3145728 && printf "${red}WARNING: There is not enough space.${NC}\n"
+}
+
build_GMP() {
CC="$CC" CFLAGS="-Os" ../${GMP_DIR}/configure --disable-shared --enable-fat --prefix=$TARGETDIR $OPTIONS \
|| touch .failed
@@ -583,6 +588,8 @@ case "$PACKAGE" in
;;
esac
+freedisk
+
# Find all the required tools:
TAR=$(searchtool tar) || exit $?