aboutsummaryrefslogtreecommitdiffstats
path: root/package/system/fstools
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2017-05-04 16:04:21 +0200
committerRafał Miłecki <rafal@milecki.pl>2017-05-22 11:12:36 +0200
commit65a3dc277f3f436bbd7d57b3048e3b932258fcbf (patch)
treea023f3292b33357511fb786041d8ec8f3601ffb3 /package/system/fstools
parent5d48dc1146171520445c43ee894d9dfce09ae4e2 (diff)
downloadupstream-65a3dc277f3f436bbd7d57b3048e3b932258fcbf.tar.gz
upstream-65a3dc277f3f436bbd7d57b3048e3b932258fcbf.tar.bz2
upstream-65a3dc277f3f436bbd7d57b3048e3b932258fcbf.zip
fstools: update to the latest version
88d48d5 libfstools: silence mkfs.{ext4,f2fs} a19f2b3 build: disable the format-truncation warning error to fix gcc 7 build errors 633a8d0 libfstools: fix multiple volume_identify usages with the same volume c43ae11 fstools: use -Wno-format-truncation instead of -Wno-error=format-truncation Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'package/system/fstools')
-rw-r--r--package/system/fstools/Makefile6
1 files changed, 3 insertions, 3 deletions
diff --git a/package/system/fstools/Makefile b/package/system/fstools/Makefile
index 759ea65978..1cdf6cd153 100644
--- a/package/system/fstools/Makefile
+++ b/package/system/fstools/Makefile
@@ -12,9 +12,9 @@ PKG_RELEASE:=1
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL=$(LEDE_GIT)/project/fstools.git
-PKG_SOURCE_DATE:=2017-03-29
-PKG_SOURCE_VERSION:=20c16fc5fec00fdae547f083a822a7f1bd67d143
-PKG_MIRROR_HASH:=fc6402291119744843b8482d3f02d5e819b92afe52f261fa30ed8bd26f4a62f1
+PKG_SOURCE_DATE:=2017-05-09
+PKG_SOURCE_VERSION:=c43ae11e71abf607a1998800f8ced489ec5d1e88
+PKG_MIRROR_HASH:=f305bfc6f2aed6f13e59581969d9da7cdf76a823f7e1fe3f1dfdc221788374dd
CMAKE_INSTALL:=1
PKG_LICENSE:=GPL-2.0
ight: bold } /* Literal.Number.Bin */ .highlight .mf { color: #0000DD; font-weight: bold } /* Literal.Number.Float */ .highlight .mh { color: #0000DD; font-weight: bold } /* Literal.Number.Hex */ .highlight .mi { color: #0000DD; font-weight: bold } /* Literal.Number.Integer */ .highlight .mo { color: #0000DD; font-weight: bold } /* Literal.Number.Oct */ .highlight .sa { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Affix */ .highlight .sb { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Backtick */ .highlight .sc { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Char */ .highlight .dl { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Delimiter */ .highlight .sd { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Doc */ .highlight .s2 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Double */ .highlight .se { color: #0044dd; background-color: #fff0f0 } /* Literal.String.Escape */ .highlight .sh { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Heredoc */ .highlight .si { color: #3333bb; background-color: #fff0f0 } /* Literal.String.Interpol */ .highlight .sx { color: #22bb22; background-color: #f0fff0 } /* Literal.String.Other */ .highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */ .highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */
#!/usr/bin/env bash

DIR="$1"

if [ -d "$DIR" ]; then
	DIR="$(cd "$DIR"; pwd)"
else
	echo "Usage: $0 toolchain-dir"
	exit 1
fi

echo -n "Locating cpp ... "
for bin in bin usr/bin usr/local/bin; do
	for cmd in "$DIR/$bin/"*-cpp; do
		if [ -x "$cmd" ]; then
			echo "$cmd"
			CPP="$cmd"
			break
		fi
	done
done

if [ ! -x "$CPP" ]; then
	echo "Can't locate a cpp executable in '$DIR' !"
	exit 1
fi

patch_specs() {
	local found=0

	for lib in $(STAGING_DIR="$DIR" "$CPP" -x c -v /dev/null 2>&1 | sed -ne 's#:# #g; s#^LIBRARY_PATH=##p'); do
		if [ -d "$lib" ]; then
			grep -qs "STAGING_DIR" "$lib/specs" && rm -f "$lib/specs"
			if [ $found -lt 1 ]; then
				echo -n "Patching specs ... "
				STAGING_DIR="$DIR" "$CPP" -dumpspecs | awk '
					mode ~ "link" {
						sub("%{L.}", "%{L*} -L %:getenv(STAGING_DIR /usr/lib) -rpath-link %:getenv(STAGING_DIR /usr/lib)")
					}
					mode ~ "cpp" {
						$0 = $0 " -idirafter %:getenv(STAGING_DIR /usr/include)"
					}
					{
						print $0
						mode = ""
					}
					/^\*cpp:/ {
						mode = "cpp"
					}
					/^\*link.*:/ {
						mode = "link"
					}
				' > "$lib/specs"
				echo "ok"
				found=1
			fi
		fi
	done

	[ $found -gt 0 ]
	return $?
}


VERSION="$(STAGING_DIR="$DIR" "$CPP" --version | sed -ne 's/^.* (.*) //; s/ .*$//; 1p')"
VERSION="${VERSION:-unknown}"

case "${VERSION##* }" in
	2.*|3.*|4.0.*|4.1.*|4.2.*)
		echo "The compiler version does not support getenv() in spec files."
		echo -n "Wrapping binaries instead ... "

		if "${0%/*}/ext-toolchain.sh" --toolchain "$DIR" --wrap "${CPP%/*}"; then
			echo "ok"
			exit 0
		else
			echo "failed"
			exit $?
		fi
	;;
	*)
		if patch_specs; then
			echo "Toolchain successfully patched."
			exit 0
		else
			echo "Failed to locate library directory!"
			exit 1
		fi
	;;
esac