Fix CreatePatch.py to use ss_bsdiff in the common/bin 23/310223/1
authorSangYoun Kwak <sy.kwak@samsung.com>
Tue, 23 Apr 2024 02:36:51 +0000 (11:36 +0900)
committerSangYoun Kwak <sy.kwak@samsung.com>
Wed, 24 Apr 2024 06:59:16 +0000 (15:59 +0900)
commitadf8bd09a92e358c33058de91a294a2678613248
tree76d71373fdd56c477ccac2861b75338a185b084a
parent652c9a8e4c96fb93d006574aba8c23ad34c9f93b
Fix CreatePatch.py to use ss_bsdiff in the common/bin

In the python script CreatePatch.py, ss_bsdiff is checked whether it is
exist in the /usr/local/bin/ss_bsdiff or not.
If not exist, then it checks if it exists under "../../common/bin".
Script makes new path using statement below:
 > os.path.join("../../common/bin", "/usr/local/bin/ss_bsdiff")
But the return value of the function above is not
 > "../../common/bin/usr/local/bin/ss_bsdiff"
but
 > "/usr/local/bin/ss_bsdiff"
so the script is just checking about "/usr/local/bin/ss_bsdiff" twice.

To fix it, a variable DIFF_UTIL_NAME is added to store the name of the
diff util and check if it exist under "../../common/bin" if
/usr/local/bin/ss_bsdiff is not exist.

Change-Id: I138b54b7dc77a47130435e9034f594b99afa35aa
Signed-off-by: SangYoun Kwak <sy.kwak@samsung.com>
mk_delta/common/bin/CreatePatch.py