开发者

How to avoid conflict when creating 32 and 64 bits rpms

开发者 https://www.devze.com 2023-01-05 14:12 出处:网络
We have to compile binary RPMs for both architectures (i386 and x86_64) for centos. When we want to install both, we have conflicts on common files (like in /usr/include, /bin, ...)

We have to compile binary RPMs for both architectures (i386 and x86_64) for centos. When we want to install both, we have conflicts on common files (like in /usr/include, /bin, ...)

Is there 开发者_如何学C.spec creation rules that help avoiding these conflicts ?


I found a link (others sources seems to agree) :

  • 64-bit computing: Co-existing in a 32-bit world

As I understand it, the answer would be :

  • common files must be exactly the same in both packages ;
  • binaries must be renamed in, for example, <binary>-32 and <binary>-64 ;
  • libs should be placed in subdirectories in %{_libdir} (which resolves to /usr/lib on 32 bit and to /usr/lib64 on x86_64)
  • if libs are places in %{_libdir} subdirectory this needs to be added to file inside /etc/ld.so.conf.d/ to include these folders for linker
0

精彩评论

暂无评论...
验证码 换一张
取 消