Skip to contentSkip to conversation

Avoid need for GREP variable by avoiding GNUisms. The

Xen-changelog John Levon 2 participants 2 messages Oct 18, 2006 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

John Levon

author
#1 lore raw

Review

Quoted 2 lines · Keir Fraser
(quoted diff) +1 -1
-	$(NM) $(TARGET) | grep -v '\(compiled\)\|\(\.o$$\)\|\( [aUw] \)\|\(\.\.ng$$\)\|\(LASH[RL]DI\)' | sort > System.map
+	$(NM) -n $(TARGET) | grep -v '\(compiled\)\|\(\.o$$\)\|\( [aUw] \)\|\(\.\.ng$$\)\|\(LASH[RL]DI\)' > System.map

Sadly:

-n Sorts external symbols by name before they
are printed.

Review

Quoted 1 line
(quoted diff) +1 -0
+	`$(NM) -nr $(TARGET)-syms | head -n 1 | sed -e 's/^\([^ ]*\).*/0x\1/'`

and

-r Prepends the name of the object file or
archive to each output line.

regards,
john

#2 lore raw
Quoted 4 lines · John Levon

Sadly:

-n Sorts external symbols by name before they
are printed.

Sorts numerically with GNU nm.

Quoted 4 lines

and

-r Prepends the name of the object file or
archive to each output line.

Reverses the sort order with GNU nm.

You set NM=gnm, so you should be okay with the GNUisms.

-- Keir