Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
ff59fea8
Commit
ff59fea8
authored
Apr 06, 2013
by
Ian Lynagh
Browse files
When making a DLL, print the number of symbols that are in it
parent
9b3d4cdd
Changes
1
Hide whitespace changes
Inline
Side-by-side
rules/build-package-way.mk
View file @
ff59fea8
...
...
@@ -158,6 +158,7 @@ define build-dll
-no-auto-link-packages
\
-o
$6
# Now check that the DLL doesn't have too many symbols. See trac #5987.
echo -n "Number of symbols in $6
:
"; $(OBJDUMP) -p $6 | sed -n "1
,
/^.Ordinal
\/
Name Pointer/ D; p; /^$$/ q" | tail -n +2 | wc -l
case
`
$(OBJDUMP)
-p
$6
|
sed
-n
"1,/^.Ordinal
\/
Name Pointer/ D; p; /^
$$
/ q"
|
grep
"
\[
*0
\]
"
|
wc
-l
`
in
1
)
echo
DLL
$6
OK
;;
0
)
echo
No symbols
in
DLL
$6
;
exit
1
;;
[
0-9]
*
)
echo
Too many symbols
in
DLL
$6
;
$(OBJDUMP)
-p
$6
|
sed
-n
"1,/^.Ordinal
\/
Name Pointer/ D; p; /^
$$
/ q"
|
tail
;
exit
1
;;
*
)
echo
bad DLL
$6
;
exit
1
;;
esac
endef
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment