Merge pull request #10946 from abbradar/fhsenv-lib3264

fhs-env: symlink /usr/lib to libs for the main architecture
This commit is contained in:
Nikolay Amiantov 2015-11-11 03:38:02 +03:00
commit 8bfac556c8
2 changed files with 7 additions and 6 deletions

View file

@ -54,8 +54,8 @@ let
etcProfile = nixpkgs.writeText "profile" ''
export PS1='${name}-chrootenv:\u@\h:\w\$ '
export LOCALE_ARCHIVE='/usr/lib${if isMultiBuild then "64" else ""}/locale/locale-archive'
export LD_LIBRARY_PATH=/run/opengl-driver/lib:/run/opengl-driver-32/lib:/lib:/lib64
export LOCALE_ARCHIVE='/usr/lib/locale/locale-archive'
export LD_LIBRARY_PATH='/run/opengl-driver/lib:/run/opengl-driver-32/lib:/usr/lib:/usr/lib32'
export PATH='/usr/bin:/usr/sbin'
${profile}
'';
@ -129,7 +129,7 @@ let
setupLibDirs_multi = ''
mkdir -m0755 lib32
mkdir -m0755 lib64
ln -s lib32 lib
ln -s lib64 lib
# copy glibc stuff
cp -rsHf ${staticUsrProfileTarget}/lib/32/* lib32/ && chmod u+w -R lib32/
@ -149,6 +149,9 @@ let
# copy gcc libs
cp -rsHf ${chosenGcc.cc}/lib/* lib32/
cp -rsHf ${chosenGcc.cc}/lib64/* lib64/
# symlink 32-bit ld-linux.so
ln -s ${staticUsrProfileTarget}/lib/32/ld-linux.so.2 lib/
'';
setupLibDirs = if isTargetBuild then setupLibDirs_target

View file

@ -40,12 +40,10 @@ buildFHSUserEnv {
];
extraBuildCommands = ''
[ -d lib64 ] && mv lib64/steam lib
mkdir -p steamrt
ln -s ../lib64/steam-runtime steamrt/amd64
ln -s ../lib/steam-runtime steamrt/i386
ln -s ../lib32/steam-runtime steamrt/i386
'';
profile = ''