On 2013-01-23 09:01, Matteo Bernardini wrote:
Hi J,

I tried to adapt the line to take in account Eric's advices

SLKCFLAGS=${SLKCFLAGS:--O2}
LIBDIRSUFFIX=""
[ "$(uname -m)" = "x86_64" ] && [ ! "$(echo $PATH | grep
^/usr/bin/32)" ] && SLKCFLAGS="$SLKCFLAGS -fPIC" LIBDIRSUFFIX="64"
 [ "$ARCH" = "i486" ] || [ "$ARCH" = "native" ] &&
SLKCFLAGS="$SLKCFLAGS -march=$ARCH"
[ "$ARCH" = "i486" ] || [ "$ARCH" = "i686" ] && SLKCFLAGS="$SLKCFLAGS
-mtune=i686"

Matteo

oh, I like this idea a lot - a huge usability win to not have to edit the .SlackBuild for such cases. of course, since SBo's official stance is "no support for multilib", I guess there's not much chance of this being acceptable... but it would be nice. also, probably want grep -q :)

On 2013-01-23 21:16, Kyle Guinn wrote:
On 1/23/13, xgiz...@slackbuilds.org <xgiz...@slackbuilds.org> wrote:

This topic has me curious.  Can anyone explain to me why we add -fPIC
for x86_64, or why we don't add it to the others?

-Kyle

the over-simplified answer is that it makes dynamic linking on x86_64 possible, and that on x86 dynamic linking Just Works. if you'd like a more technical understanding, there are plenty of these available online, just google for something like "fpic x86_64" or "fpic amd64" or such.
_______________________________________________
SlackBuilds-users mailing list
SlackBuilds-users@slackbuilds.org
http://lists.slackbuilds.org/mailman/listinfo/slackbuilds-users
Archives - http://lists.slackbuilds.org/pipermail/slackbuilds-users/
FAQ - http://slackbuilds.org/faq/

Reply via email to