equal
deleted
inserted
replaced
306 For X86: |
306 For X86: |
307 <br> |
307 <br> |
308 <code><ul> |
308 <code><ul> |
309 gcc -O2 -fPIC -pthread -DLINUX -c <i>*.c</i> |
309 gcc -O2 -fPIC -pthread -DLINUX -c <i>*.c</i> |
310 <br> |
310 <br> |
311 gcc -z defs -static-libgcc -shared -mimpure-text -o <i>libXXX.so *.o</i> -lc |
311 gcc -z defs -static-libgcc -shared -o <i>libXXX.so *.o</i> -lc |
312 </code></ul> |
312 </code></ul> |
313 <br> |
313 <br> |
314 For AMD64: |
314 For AMD64: |
315 <br> |
315 <br> |
316 <code><ul> |
316 <code><ul> |
317 gcc -O2 -fPIC -pthread -DLINUX -D_LP64=1 -c <i>*.c</i> |
317 gcc -O2 -fPIC -pthread -DLINUX -D_LP64=1 -c <i>*.c</i> |
318 <br> |
318 <br> |
319 gcc -z defs -static-libgcc -shared -mimpure-text -o <i>libXXX.so *.o</i> -lc |
319 gcc -z defs -static-libgcc -shared -o <i>libXXX.so *.o</i> -lc |
320 </code></ul> |
320 </code></ul> |
321 <br> |
321 <br> |
322 </li> |
322 </li> |
323 |
323 |
324 <li> |
324 <li> |
337 <code>-xregs=no%frameptr</code> |
337 <code>-xregs=no%frameptr</code> |
338 option. |
338 option. |
339 </li> |
339 </li> |
340 |
340 |
341 <li> |
341 <li> |
342 Library: Use -static-libgcc -mimpure-text. |
342 Library: Use -static-libgcc. |
343 <br> |
343 <br> |
344 When building the shared library (-shared option), this option |
344 When building the shared library (-shared option), this option |
345 allows for maximum portability of the library between different |
345 allows for maximum portability of the library between different |
346 flavors of Linux. |
346 flavors of Linux. |
347 The problem we have seen with Linux is that we cannot depend |
347 The problem we have seen with Linux is that we cannot depend |