change deriveConstants to use nm in a POSIX way (fixes #8781)
change deriveConstants to use nm in a POSIX way (fixes #8781)

The patch provided by Christian Maeder <Christian.Maeder@dfki.de>

Signed-off-by: Karel Gardas <b9ef54afb00a9e07d4c9b4e17d9660dba0ba4cf0@centrum.cz>
Signed-off-by: Austin Seipp <7ea35d812706d9213868749011af1ed4fa2f6aa0@well-typed.com>
(cherry picked from commit 045b28033a33a48d31951240a8cb35f2b78345dc)

lukexi/ghc-7.8-arm64,lukexi/ghc-7.8-arm64,hferreiro/replay,hferreiro/replay,hferreiro/replay,lukexi/ghc-7.8-arm64,lukexi/ghc-7.8-arm64,hferreiro/replay,hferreiro/replay,hferreiro/replay,hferreiro/replay,lukexi/ghc-7.8-arm64