Opened 3 years ago
Closed 3 years ago
#64127 closed defect (fixed)
rust: scalpel.dylib is not built with the right cflags / -arch flags
Reported by: | ryandesign (Ryan Carsten Schmidt) | Owned by: | g5pw (Aljaž Srebrnič) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.7.1 |
Keywords: | Cc: | catap (Kirill A. Korinsky), herbygillot (Herby Gillot), mascguy (Christopher Nielsen) | |
Port: | rust |
Description
The rust portfile creates a helper dylib using this command:
system "${configure.cc} -dynamiclib -exported_symbols_list ${export_list_file} -o ${scalpel_dylib} ${prefix}/lib/libcxx/libc++.a"
I don't see MacPorts cflags in there, including -arch
flags, so this will prevent a universal build from being possible.
Granted, this block only takes effect on older systems, and the port already indicates that it only supports arm64 and x86_64, so on older x86_64 systems there is no opportunity to build universal anyway. Yet, it is still proper procedure to specify the correct -arch
flags and cflags with every compilation. Who knows, maybe one day we can return i386 support to the portfile to fix the librsvg headache; at that time at the latest building this lib for the right archs will be important.
Change History (5)
comment:1 Changed 3 years ago by catap (Kirill A. Korinsky)
comment:2 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)
An x86_64/i386 universal build of rust used to be possible before rust was updated to a version that dropped i386 support.
If you're not interested in the universal aspect, then consider the user who wishes to configure a MacPorts installation for cross compilation by changing build_arch
in macports.conf. MacPorts allows this, but what this portfile does doesn't accommodate that.
comment:3 Changed 3 years ago by catap (Kirill A. Korinsky)
Ryan, I'm interesting and trying to make universal port at M1.
I just would like to point that it doesn't work right now.
I'll add suggested flags.
comment:4 Changed 3 years ago by mascguy (Christopher Nielsen)
Cc: | mascguy added |
---|
comment:5 Changed 3 years ago by catap (Kirill A. Korinsky)
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Ryan, this library is used on old system to fill missed symbols to allow run precompiled rust to build the rust.
To be honest: rust has a lot of issues and I doubt that universal build for it is possible at all.