Not an answer to your flags issue per-se, but this might help with
soname and possibly shed some light on your flag issue.
https://www.logikalsolutions.com/wordpress/information-technology/soversion/
If not, sorry for the distraction.
soname has to do with package creation, not compiling.
On 7/21/26 5:11 AM, Anton Shterenlikht via Discussion list for the GNU
libtool shared library maintenance tool wrote:
I've been hit with this issues multiple times before, see e.g.
https://lists.gnu.org/archive/html/libtool/2024-07/msg00002.html
I'm now trying an upcoming AMD "new flang" compiler from here:
https://repo.radeon.com/rocm/misc/flang
using libtool 2.6.2
The resulting "libtool" file has empty "wl=":
# A language specific compiler.
CC="ftn"
# Is the compiler the GNU compiler?
with_gcc=no
# Compiler flag to turn off builtin functions.
no_builtin_flag=""
# Additional compiler flags for building library objects.
pic_flag=""
# How to pass a linker flag through the compiler.
wl=""
which results in:
flang-23: error: unknown argument: '-soname'
I'm not sure why this happens.
Looking at aclocal/libtool.m4, "*flang*" should be correct.
It should catch compiler names such as armflang, amdflang, etc. or,
as in this case flang-23.
4972 *flang* | ftn | f18* | f95*)
4973 # Flang compiler.
4974 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4975 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4976 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4977 ;;
The immediate workaround, as before, is to simply fix
the resulting libtool script after configure has completed:
sed -i 's/^wl=""/wl="-Wl,"/g' libtool
but it would be good to understand what is causing libtool
to generate the libtool script with emtpy "wl=" in the first place.
Thank you
Anton
--
Roland Hughes, President
Logikal Solutions
(630) 205-1593 (cell)
(815) 949-5621
https://theminimumyouneedtoknow.com
https://twentyoftwo.com
https://infiniteexposure.net
https://lesedi.us/
https://johnsmith-book.com