Bug 5918 - git submodule init doesn't work on target
Summary: git submodule init doesn't work on target
Status: RESOLVED FIXED
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: core (show other bugs)
Version: 1.6
Hardware: All Multiple
: Medium normal
Target Milestone: 1.6
Assignee: Richard Purdie
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2014-03-06 07:25 UTC by Jonathan Liu
Modified: 2014-03-27 09:54 UTC (History)
3 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: No (bug/feature does not impact docs)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Liu 2014-03-06 07:25:25 UTC
Using poky master 8b64ef14408cd286abb414df998c0479d4017bb6. The git package was installed on target.

On the target:
# mkdir test
# cd test
# git init
Initialized empty Git repository in /home/root/test/.git/
# git submodule init
/usr/lib/git/git-core/git-submodule: line 159: /home/build/git/poky/build/tmp/sysroots/x86_64-linux/usr/bin/perl-native/perl: No such file or directory

The git-submodule script has a hardcoded path from the build host that needs to be fixed.
Comment 1 Jonathan Liu 2014-03-06 07:28:49 UTC
# grep -Hnr 'sysroots' /usr/lib/git/git-core
/usr/lib/git/git-core/git-am:305:                       /home/build/git/poky/build/tmp/sysroots/x86_64-linux/usr/bin/perl-native/perl -ne 'BEGIN { $subject = 0 }
/usr/lib/git/git-core/git-am:337:                       LANG=C LC_ALL=C /home/build/git/poky/build/tmp/sysroots/x86_64-linux/usr/bin/perl-native/perl -M'POSIX qw(strftime)' -ne 'BEGIN { $subject = 0 }
/usr/lib/git/git-core/git-submodule:159:        /home/build/git/poky/build/tmp/sysroots/x86_64-linux/usr/bin/perl-native/perl -e '
/usr/lib/git/git-core/git-request-pull:109:ref=$(git ls-remote "$url" | /home/build/git/poky/build/tmp/sysroots/x86_64-linux/usr/bin/perl-native/perl -e "$find_matching_ref" "$head" "$headrev" "$tag_name")
/usr/lib/git/git-core/git-instaweb:6:PERL='/home/build/git/poky/build/tmp/sysroots/x86_64-linux/usr/bin/perl-native/perl'
/usr/lib/git/git-core/git-instaweb:584:#!/home/build/git/poky/build/tmp/sysroots/x86_64-linux/usr/bin/perl-native/perl
Comment 2 Richard Purdie 2014-03-26 22:29:46 UTC
Patch out for review on the mailing list.