build failing on Mac M1 for open ssl ( with killed: 9 error ) - yarnpkg

I am building an application written in OCaml using yarn and esy. The build process fails trying to build open ssl source code, each time at a random library ( like dsa etc ). For my colleagues using Intel chips, the app builds fine. I am using a mac with m1 chip.
Logs:
cc -I. -Iinclude -fPIC -arch arm64 -O3 -Wall -DL_ENDIAN -DOPENSSL_PIC -DOPENSSL_CPUID_OBJ -DOPENSSL_BN_ASM_MONT -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DKECCAK1600_ASM -DVPAES_ASM -DECP_NISTZ256_ASM -DPOLY1305_ASM -DOPENSSLDIR="\"~/.esy/3___________________________________________________/s/esy_openssl-93ba2454/ssl\"" -DENGINESDIR="\"~/.esy/3___________________________________________________/s/esy_openssl-93ba2454/lib/engines-1.1\"" -D_REENTRANT -DNDEBUG -MMD -MF crypto/ec/eck_prn.d.tmp -MT crypto/ec/eck_prn.o -c -o crypto/ec/eck_prn.o crypto/ec/eck_prn.c
cc -I. -Iinclude -fPIC -arch arm64 -O3 -Wall -DL_ENDIAN -DOPENSSL_PIC -DOPENSSL_CPUID_OBJ -DOPENSSL_BN_ASM_MONT -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DKECCAK1600_ASM -DVPAES_ASM -DECP_NISTZ256_ASM -DPOLY1305_ASM -DOPENSSLDIR="\"~/.esy/3___________________________________________________/s/esy_openssl-93ba2454/ssl\"" -DENGINESDIR="\"~/.esy/3___________________________________________________/s/esy_openssl-93ba2454/lib/engines-1.1\"" -D_REENTRANT -DNDEBUG -MMD -MF crypto/ec/ecp_mont.d.tmp -MT crypto/ec/ecp_mont.o -c -o crypto/ec/ecp_mont.o crypto/ec/ecp_mont.c
***make[1]: *** [crypto/ec/eck_prn.o] Killed: 9***
make[1]: *** Waiting for unfinished jobs....
make[1]: *** [crypto/ec/ecp_mont.o] Killed: 9
/bin/sh: line 1: 90780 Killed: 9 cmp crypto/ec/ecdsa_sign.d.tmp crypto/ec/ecdsa_sign.d > /dev/null 2> /dev/null
make: *** [all] Error 2
error: command failed: 'make' '-j4' (exited with 2)
esy-build-package: exiting with errors above...
building esy-openssl#archive:https://www.openssl.org/source/openssl-1.1.1l.tar.gz#sha256:0b7a3e5e59c34827fe0c3a74b7ec8baef302b98fa80088d7f9153aa16fa76bd1
I observed the activity monitor to see the memory usage and also looked at logs in Console.app. Could not find any substantial evidence. Rosetta is turned off.
I am guessing it is a memory issue, tried to see if upx helps - but the binaries are getting cleared from the esy directories.

Related

F2py errors with a MAC M2

I'm trying to use f2py on a MAC M2. My programs all run successfully on an Intel MAC. The first part of the process to produce C code from my Fortran source which seems to work but I get the following error when the C compilation attempts and fails
clang-14clang-14: : error: error: the clang compiler does not support '-march=core2'the clang compiler does not support '-march=core2'
Followed by this long string
error: Command "x86_64-apple-darwin13.4.0-clang -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /opt/homebrew/Caskroom/miniforge/base/envs/condaTest/include -arch arm64 -fPIC -O2 -isystem /opt/homebrew/Caskroom/miniforge/base/envs/condaTest/include -arch arm64 -march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -isystem /opt/homebrew/Caskroom/miniforge/base/include -D_FORTIFY_SOURCE=2 -isystem /opt/homebrew/Caskroom/miniforge/base/include -ftrapping-math -DNPY_DISABLE_OPTIMIZATION=1 -I/var/folders/np/393cjs953159dbj23mgqmlqr0000gn/T/tmpf0_vcv2d/src.macosx-11.0-arm64-3.9 -I/opt/homebrew/Caskroom/miniforge/base/envs/condaTest/lib/python3.9/site-packages/numpy/core/include -I/opt/homebrew/Caskroom/miniforge/base/envs/condaTest/include/python3.9 -c /var/folders/np/393cjs953159dbj23mgqmlqr0000gn/T/tmpf0_vcv2d/src.macosx-11.0-arm64-3.9/fib3module.c -o /var/folders/np/393cjs953159dbj23mgqmlqr0000gn/T/tmpf0_vcv2d/var/folders/np/393cjs953159dbj23mgqmlqr0000gn/T/tmpf0_vcv2d/src.macosx-11.0-arm64-3.9/fib3module.o -MMD -MF /var/folders/np/393cjs953159dbj23mgqmlqr0000gn/T/tmpf0_vcv2d/var/folders/np/393cjs953159dbj23mgqmlqr0000gn/T/tmpf0_vcv2d/src.macosx-11.0-arm64-3.9/fib3module.o.d" failed with exit status 1
I would be very grateful for any help with this.

OpenSSH Library not found (Issues with Conda perhaps?)

I am trying to install a package on my Mac. The installation always fails with the following error line : OpenSSL library was not found in your system. Now, if I type
openssl version -a
This is the output I get
built on: Mon Feb 10 17:07:46 2020 UTC
platform: darwin64-x86_64-cc
options: bn(64,64) rc4(16x,int) des(int) idea(int) blowfish(ptr)
compiler: x86_64-apple-darwin13.4.0-clang -D_FORTIFY_SOURCE=2 -mmacosx-version-min=10.9 -I/Users/kshitij/opt/anaconda3/include -march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -I/Users/kshitij/opt/anaconda3/include -fdebug-prefix-map=/opt/concourse/worker/volumes/live/9628f99a-6ef8-4f2c-49be-ff8c4ad85bd7/volume/openssl_1581354377010/work=/usr/local/src/conda/openssl-1.1.1d -fdebug-prefix-map=/Users/kshitij/opt/anaconda3=/usr/local/src/conda-prefix -fPIC -arch x86_64 -march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -I/Users/kshitij/opt/anaconda3/include -fdebug-prefix-map=/opt/concourse/worker/volumes/live/9628f99a-6ef8-4f2c-49be-ff8c4ad85bd7/volume/openssl_1581354377010/work=/usr/local/src/conda/openssl-1.1.1d -fdebug-prefix-map=/Users/kshitij/opt/anaconda3=/usr/local/src/conda-prefix -DL_ENDIAN -DOPENSSL_PIC -DOPENSSL_CPUID_OBJ -DOPENSSL_IA32_SSE2 -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_MONT5 -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DKECCAK1600_ASM -DRC4_ASM -DMD5_ASM -DVPAES_ASM -DGHASH_ASM -DECP_NISTZ256_ASM -DX25519_ASM -DPOLY1305_ASM -D_REENTRANT -DNDEBUG -D_FORTIFY_SOURCE=2 -mmacosx-version-min=10.9 -I/Users/kshitij/opt/anaconda3/include
OPENSSLDIR: "/Users/kshitij/opt/anaconda3/ssl"
ENGINESDIR: "/Users/kshitij/opt/anaconda3/lib/engines-1.1"
Seeding source: os-specific
I understand that anaconda might be bugging with me, so I have tried
conda deactivate
Now if I try the same thing I get :
LibreSSL 2.8.3
built on: date not available
platform: information not available
options: bn(64,64) rc4(16x,int) des(idx,cisc,16,int) blowfish(idx)
compiler: information not available
OPENSSLDIR: "/private/etc/ssl"
But if I now try installing the package, I still get the same error line. So I am very unsure what to do. Any suggestions?

linux kernel 4.4 build error: garbage following instruction

I am trying to build a custom linux kernel 4.4 running for AT91 with mostly default configuration that I set up from menuconfig. The build fails with the following error. The gcc version is 4.6.3 and the binutils version is 2.22. There is nothing obvious in main.c which is where the compilation is at the time of failure. Dont understand what to look for as I have run out of ideas.
arm-none-linux-gnueabi-gcc -Wp,-MD,init/.main.o.d -nostdinc -isystem /opt/arm-2009q1/bin/../lib/gcc/arm-none-linux-gnueabi/4.3.3/include -I./arch/arm/include -Iarch/arm/include/generated/uapi -Iarch/arm/include/generated -Iinclude -I./arch/arm/include/uapi -Iarch/arm/include/generated/uapi -I./include/uapi -Iinclude/generated/uapi -include ./include/linux/kconfig.h -D__KERNEL__ -mlittle-endian -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -fno-omit-frame-pointer -mapcs -mno-sched-prolog -mabi=apcs-gnu -mno-thumb-interwork -marm -D__LINUX_ARM_ARCH__=7 -march=armv7-a -msoft-float -Uarm -fno-delete-null-pointer-checks -O2 -fno-stack-protector -fno-omit-frame-pointer -fno-optimize-sibling-calls -gdwarf-2 -pg -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -Werror=implicit-int -Werror=strict-prototypes -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(main)" -D"KBUILD_MODNAME=KBUILD_STR(main)" -c -o init/.tmp_main.o init/main.c
/tmp/ccbj4Zgm.s: Assembler messages:
/tmp/ccbj4Zgm.s:852: Error: garbage following instruction -- `dmb ishst'
/tmp/ccbj4Zgm.s:874: Error: garbage following instruction -- `dmb ishst'
/tmp/ccbj4Zgm.s:909: Error: garbage following instruction -- `dmb ish'
/tmp/ccbj4Zgm.s:921: Error: garbage following instruction -- `dsb ishst'
make[2]: *** [init/main.o] Error 1
make[1]: *** [init] Error 2

Building Blender 2.6x on Mac OS 10.8: 3DconnexionClient/ConnexionClientAPI.h'

I am trying to play around with the sources of blender and try to follow the tutorial on http://wiki.blender.org/index.php/Dev:2.5/Doc/Building_Blender/Mac
I am using the CMake+Xcode method which works up to the step where it says "select install" as target and hit the run button. After 3-4 minutes I get this error:
CompileC /Users/Jan/blender-build/cmake/intern/ghost/Blender.build/Debug/bf_intern_ghost.build/Objects-normal/x86_64/GHOST_NDOFManagerCocoa.o intern/ghost/intern/GHOST_NDOFManagerCocoa.mm normal x86_64 objective-c++ com.apple.compilers.llvm.clang.1_0.compiler
cd /Users/Jan/blender-build/blender
setenv LANG en_US.US-ASCII
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x objective-c++ -arch x86_64 -fmessage-length=0 -Wno-trigraphs -fpascal-strings -O0 -Wno-missing-field-initializers -Wno-missing-prototypes -Wno-return-type -Wno-implicit-atomic-properties -Wno-receiver-is-weak -Wno-non-virtual-dtor -Wno-overloaded-virtual -Wno-exit-time-destructors -Wformat -Wno-missing-braces -Wparentheses -Wswitch -Wno-unused-function -Wno-unused-label -Wno-unused-parameter -Wno-unused-variable -Wunused-value -Wno-empty-body -Wno-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wno-shorten-64-to-32 -Wno-newline-eof -Wno-selector -Wno-strict-selector-match -Wno-undeclared-selector -Wno-deprecated-implementations -Wno-arc-abi -Wno-c++11-extensions "-DCMAKE_INTDIR=\"Debug\"" -D__SSE__ -D__MMX__ -D__SSE2__ -D__LITTLE_ENDIAN__ -DOPJ_STATIC -DWITH_INPUT_NDOF -DDEBUG -D_DEBUG -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk -fasm-blocks -Wprotocol -Wdeprecated-declarations -Winvalid-offsetof -mmacosx-version-min=10.5 -g -Wno-sign-conversion "-DIBOutlet=__attribute__((iboutlet))" "-DIBOutletCollection(ClassName)=__attribute__((iboutletcollection(ClassName)))" "-DIBAction=void)__attribute__((ibaction)" -I/Users/Jan/blender-build/cmake/lib/Debug/include -I/Users/Jan/blender-build/blender/intern/ghost -I/Users/Jan/blender-build/blender/intern/string -I/Users/Jan/blender-build/blender/source/blender/imbuf -I/Users/Jan/blender-build/blender/source/blender/makesdna -I/Users/Jan/blender-build/blender/extern/glew/include -I/Users/Jan/blender-build/cmake/intern/ghost/Blender.build/Debug/bf_intern_ghost.build/DerivedSources/x86_64 -I/Users/Jan/blender-build/cmake/intern/ghost/Blender.build/Debug/bf_intern_ghost.build/DerivedSources -Wmost -Wno-four-char-constants -Wno-unknown-pragmas -F/Users/Jan/blender-build/cmake/lib/Debug -msse2 -msse -pipe -funsigned-char -DGHOST_COCOA -DUSE_QTKIT -Wall -Wno-invalid-offsetof -Wno-sign-compare -Wuninitialized -Winit-self -Wmissing-include-dirs -Wno-div-by-zero -fno-strict-aliasing -MMD -MT dependencies -MF /Users/Jan/blender-build/cmake/intern/ghost/Blender.build/Debug/bf_intern_ghost.build/Objects-normal/x86_64/GHOST_NDOFManagerCocoa.d --serialize-diagnostics /Users/Jan/blender-build/cmake/intern/ghost/Blender.build/Debug/bf_intern_ghost.build/Objects-normal/x86_64/GHOST_NDOFManagerCocoa.dia -c /Users/Jan/blender-build/blender/intern/ghost/intern/GHOST_NDOFManagerCocoa.mm -o /Users/Jan/blender-build/cmake/intern/ghost/Blender.build/Debug/bf_intern_ghost.build/Objects-normal/x86_64/GHOST_NDOFManagerCocoa.o
/Users/Jan/blender-build/blender/intern/ghost/intern/GHOST_NDOFManagerCocoa.mm:30:11: fatal error: '3DconnexionClient/ConnexionClientAPI.h' file not found
#include <3DconnexionClient/ConnexionClientAPI.h>
^
1 error generated.
As I own a SpaceNavigator, the drivers are installed and they are definitely found under /Library/Frameworks/3DconnexionClient.framework and also the searched header file is available.
I also tried to add the header+library search paths but that doesn't work either.
Any help on that?
Thank you!

Xcode 4.3 : Clang LLVM 1.0 Error

I would like to use SDL in a project, so I create a Cocoa Project and I add all Framework needed, but XCode tells me this :
ProcessPCH /Users/aurelien/Library/Developer/Xcode/DerivedData/projetCS2-gdnozsjskcozmxcvmlmmpsmmkcvk/Build/Intermediates/PrecompiledHeaders/projetCS2-Prefix-auneaovyjutgotajcmkllwxdblci/projetCS2-Prefix.pch.pth projetCS2/projetCS2-Prefix.pch normal i386 objective-c com.apple.compilers.llvm.clang.1_0.compiler
cd /Users/aurelien/Documents/Programmation/projetC-S2/projetCS2
setenv LANG en_US.US-ASCII
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x objective-c-header -arch i386 -fmessage-length=0 -std=gnu99 -fobjc-arc -Wno-trigraphs -fpascal-strings -O0 -Wno-missing-field-initializers -Wno-missing-prototypes -Wreturn-type -Wno-implicit-atomic-properties -Wformat -Wno-missing-braces -Wparentheses -Wswitch -Wno-unused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wuninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-sign-compare -Wshorten-64-to-32 -Wpointer-sign -Wno-newline-eof -Wno-selector -Wno-strict-selector-match -Wno-undeclared-selector -Wno-deprecated-implementations -DDEBUG=1 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk -fasm-blocks -Wprotocol -Wdeprecated-declarations -mmacosx-version-min=10.7 -g -Wno-conversion -Wno-sign-conversion "-DIBOutlet=__attribute__((iboutlet))" "-DIBOutletCollection(ClassName)=__attribute__((iboutletcollection(ClassName)))" "-DIBAction=void)__attribute__((ibaction)" -I/Users/aurelien/Library/Developer/Xcode/DerivedData/projetCS2-gdnozsjskcozmxcvmlmmpsmmkcvk/Build/Intermediates/projetCS2.build/Debug/projetCS2.build/projetCS2.hmap -I/Users/aurelien/Library/Developer/Xcode/DerivedData/projetCS2-gdnozsjskcozmxcvmlmmpsmmkcvk/Build/Products/Debug/include -I/Library/Frameworks/SDL.framework/Headers -I/Library/Frameworks/SDL_image.framework/Headers -I/Library/Frameworks/SDL_ttf.framework/Headers -I/Users/aurelien/Library/Developer/Xcode/DerivedData/projetCS2-gdnozsjskcozmxcvmlmmpsmmkcvk/Build/Intermediates/projetCS2.build/Debug/projetCS2.build/DerivedSources/i386 -I/Users/aurelien/Library/Developer/Xcode/DerivedData/projetCS2-gdnozsjskcozmxcvmlmmpsmmkcvk/Build/Intermediates/projetCS2.build/Debug/projetCS2.build/DerivedSources -F/Users/aurelien/Library/Developer/Xcode/DerivedData/projetCS2-gdnozsjskcozmxcvmlmmpsmmkcvk/Build/Products/Debug -F/Library/Frameworks --serialize-diagnostics /Users/aurelien/Library/Developer/Xcode/DerivedData/projetCS2-gdnozsjskcozmxcvmlmmpsmmkcvk/Build/Intermediates/PrecompiledHeaders/projetCS2-Prefix-auneaovyjutgotajcmkllwxdblci/projetCS2-Prefix.pch.dia -c /Users/aurelien/Documents/Programmation/projetC-S2/projetCS2/projetCS2/projetCS2-Prefix.pch -o /Users/aurelien/Library/Developer/Xcode/DerivedData/projetCS2-gdnozsjskcozmxcvmlmmpsmmkcvk/Build/Intermediates/PrecompiledHeaders/projetCS2-Prefix-auneaovyjutgotajcmkllwxdblci/projetCS2-Prefix.pch.pth -MMD -MT dependencies -MF /Users/aurelien/Library/Developer/Xcode/DerivedData/projetCS2-gdnozsjskcozmxcvmlmmpsmmkcvk/Build/Intermediates/PrecompiledHeaders/projetCS2-Prefix-auneaovyjutgotajcmkllwxdblci/projetCS2-Prefix.pch.d
error: -fobjc-arc is not supported with fragile abi
Command /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang failed with exit code 1
The error says you are using ARC (automatic reference counting) on your project, and that it's not supported using the fragile ABI (simulator).
You are surely building your app for 32-bits.
ARC is 64-bits only.
Try to update your projects settings, and build for 64-bits instead of 32 or universal.

Resources