.. Copyright 1988-2022 Free Software Foundation, Inc. This is part of the GCC manual. For copying conditions, see the copyright.rst file. .. program:: Solaris 2 .. index:: Solaris 2 options .. _solaris-2-options: Solaris 2 Options ^^^^^^^^^^^^^^^^^ These :samp:`-m` options are supported on Solaris 2: .. option:: -mclear-hwcap :option:`-mclear-hwcap` tells the compiler to remove the hardware capabilities generated by the Solaris assembler. This is only necessary when object files use ISA extensions not supported by the current machine, but check at runtime whether or not to use them. .. option:: -mimpure-text :option:`-mimpure-text`, used in addition to :option:`-shared`, tells the compiler to not pass :option:`-z text` to the linker when linking a shared object. Using this option, you can link position-dependent code into a shared object. :option:`-mimpure-text` suppresses the 'relocations remain against allocatable but non-writable sections' linker error message. However, the necessary relocations trigger copy-on-write, and the shared object is not actually shared across processes. Instead of using :option:`-mimpure-text`, you should compile all source code with :option:`-fpic` or :option:`-fPIC`. These switches are supported in addition to the above on Solaris 2: .. option:: -pthreads This is a synonym for :option:`-pthread`.