In Your answer before, You adviced me to create the library through an xcode project or a Swift package..
I give you first here the info, how I have done it actually
To create the library , I did the following steps:
I have some -.c files that have to be compiled and linked to get the library.
for all that I use the Terminal :
1. I gave the -.c files in a folder /usr/local/f2c/libf2c
2. I modified the makefile on CC and CFLAGS to adjust for the Xcode settings
here some extracts of the makefile:
.SUFFIXES: .c .o
CC = "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc"
SHELL = /bin/sh
CFLAGS = -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS13.4.sdk
# compile, then strip unnecessary symbols
.c.o:
$(CC) -c -DSkip_f2c_Undefs $(CFLAGS) $*.c. # HERE the COMPILING starts
ld -r -x -o $*.*** $*.o
mv $*.*** $*.o
.....
all: f2c.h signal1.h sysdep1.h libf2c.a
........
libf2c.a: $(OFILES)
ar r libf2c.a $?
-ranlib libf2c.a
3. I call ' make ' in the terminal and then the sript is running
Result is a library called : libf2c.a
to check the library by : lipo -info libf2c.a
this library is architecture X86_64 and arm64, same as before, when I created it with previous MAC and Xcode versions
But even the library is now created by MAC OS 10.15.4 and Xcode 11.4, the error message is the same:
"Building for ios Simultor but the linked library 'libf2c.a' was build for mac OS + ios
If you want, then I can ship You all the c-files and the makefile, to that you can reproduce the creation of the library.
What shold be the solution to create a library running in Xcode 11.4 , both in Simulator and on device, same as before ?
You adviced to do it in a xcode project, but How can I do all the works inside a xcode project or from a swift package, when I have native C-code ? In my Xcode project, i just inserted the library and it was working. But no more in Xcode 11.4