diff mbox series

[07/10] libxfs-diff: try harder to find the kernel equivalent libxfs files

Message ID 156151665396.2286979.8848777429156280703.stgit@magnolia (mailing list archive)
State Superseded
Headers show
Series xfsprogs-5.1: fix various problems | expand

Commit Message

Darrick J. Wong June 26, 2019, 2:37 a.m. UTC
From: Darrick J. Wong <darrick.wong@oracle.com>

Now that we're syncing userspace libxfs/ files with kernel fs/xfs/
files, teach the diff tool to try fs/xfs/xfs_foo.c if
fs/xfs/libxfs/xfs_foo.c doesn't exist.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
 tools/libxfs-diff |    1 +
 1 file changed, 1 insertion(+)
diff mbox series


diff --git a/tools/libxfs-diff b/tools/libxfs-diff
index fa57c004..c18ad487 100755
--- a/tools/libxfs-diff
+++ b/tools/libxfs-diff
@@ -22,5 +22,6 @@  dir="$(readlink -m "${dir}/..")"
 for i in libxfs/xfs*.[ch]; do
+	test -f "${kfile}" || kfile="$(echo "${kfile}" | sed -e 's|libxfs/||g')"
 	diff -Naurpw --label "$i" <(sed -e '/#include/d' "$i") --label "${kfile}" <(sed -e '/#include/d' "${kfile}")