I've attempted to enable compiling with -fembed-bitcode applied via a patch (this is the first time I've played with patch files so I could be doing it wrong) that I've attempted to create. (https://gist.github.com/wtsnz/a7db502a6c8e713e93cf)
My thinking was to create a patch that changes the /MobileVLCKit/ImportedSources/vlc/extras/package/ios/build.sh script in order to add the -fembed-bitcode flag to the "CFLAGS" argument.
The patch gets applied successfully, and building commences.
It's successful for the armv7 and armv7s, and checking with "otool -l libvlc.a | grep bitcode" I get binaries that contain bitcode!
but when compiling for arm64 (or aarch64 as it's displayed in the command line) (which is the Apple TV + newer iPhones) building fails "error: implicit declaration of function 'vlc_CPU_ARM_NEON' is invalid in C99"
Code: Select all
In file included from /Users/will/projects/VLCKit/MobileVLCKit/ImportedSources/vlc/modules/audio_filter/channel_mixer/simple.c:262:
/Users/will/projects/VLCKit/MobileVLCKit/ImportedSources/vlc/modules/audio_filter/channel_mixer/simple_neon.h:50:1: error: implicit declaration of function 'vlc_CPU_ARM_NEON' is invalid in C99
[-Werror,-Wimplicit-function-declaration]
NEON_WRAPPER(7_x,2_0)
^
/Users/will/projects/VLCKit/MobileVLCKit/ImportedSources/vlc/modules/audio_filter/channel_mixer/simple_neon.h:47:16: note: expanded from macro 'NEON_WRAPPER'
return vlc_CPU_ARM_NEON() ? DoWork_##in##_to_##out##_neon : DoWork_##in##_to_##out; \
^
1 error generated.
make[4]: *** [audio_filter/channel_mixer/libsimple_channel_mixer_plugin_la-simple.lo] Error 1
make[4]: *** Waiting for unfinished jobs....
make[3]: *** [all-recursive] Error 1
make[2]: *** [all] Error 2
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2