Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c25f4157 authored by Amerigo Wang's avatar Amerigo Wang Committed by Michal Marek
Browse files

scripts/namespace.pl: fix wrong source path



File::Find will do chdir automatically, so we need to get the absolute
patch with $File::Find::dir.

Reported-by: default avatarStephen Hemminger <shemminger@vyatta.com>
Signed-off-by: default avatarAmerigo Wang <amwang@redhat.com>
Cc: Michal Marek <mmarek@suse.cz>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarMichal Marek <mmarek@suse.cz>
parent 03ee0c42
Loading
Loading
Loading
Loading
+4 −4
Original line number Original line Diff line number Diff line
@@ -167,11 +167,11 @@ sub do_nm
		printf STDERR "$fullname is not an object file\n";
		printf STDERR "$fullname is not an object file\n";
		return;
		return;
	}
	}
	($source = $fullname) =~ s/\.o$//;
	($source = $basename) =~ s/\.o$//;
	if (-e "$objtree$source.c" || -e "$objtree$source.S") {
	if (-e "$source.c" || -e "$source.S") {
		$source = "$objtree$source";
		$source = "$objtree$File::Find::dir/$source";
	} else {
	} else {
		$source = "$srctree$source";
		$source = "$srctree$File::Find::dir/$source";
	}
	}
	if (! -e "$source.c" && ! -e "$source.S") {
	if (! -e "$source.c" && ! -e "$source.S") {
		# No obvious source, exclude the object if it is conglomerate
		# No obvious source, exclude the object if it is conglomerate