Skip to content

Generate iOS framework error #37

@hugoliv

Description

@hugoliv

Hello,

No way to generate the Framework using ./genereate_ios_framework script on my Mac. Following is the shell output. Do you have an idea ?

`generating torch
-- The C compiler identification is AppleClang 9.0.0.9000039
-- The CXX compiler identification is AppleClang 9.0.0.9000039
-- Check for working C compiler: /usr/bin/xcrun
-- Check for working C compiler: /usr/bin/xcrun -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/xcrun
-- Check for working CXX compiler: /usr/bin/xcrun -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Performing Test C_HAS_WALL
-- Performing Test C_HAS_WALL - Success
-- Performing Test C_HAS_NO_UNUSED_FUNCTION
-- Performing Test C_HAS_NO_UNUSED_FUNCTION - Success
-- Performing Test C_HAS_FEXCEPTIONS
-- Performing Test C_HAS_FEXCEPTIONS - Success
-- Performing Test CXX_HAS_WALL
-- Performing Test CXX_HAS_WALL - Success
-- Performing Test CXX_HAS_NO_UNUSED_FUNCTION
-- Performing Test CXX_HAS_NO_UNUSED_FUNCTION - Success
-- Could not find hardware support for NEON on this machine.
-- No OMAP3 processor on this on this machine.
-- No OMAP4 processor on this on this machine.
-- Looking for _longjmp
-- Looking for _longjmp - found
-- Looking for sigaction
-- Looking for sigaction - found
-- Looking for isatty
-- Looking for isatty - found
-- Looking for mkstemp
-- Looking for mkstemp - found
-- Looking for popen
-- Looking for popen - found
-- Looking for sin in m
-- Looking for sin in m - found
-- Looking for dlopen
-- Looking for dlopen - found
CMake Warning (dev) at exe/CMakeLists.txt:18 (GET_TARGET_PROPERTY):
Policy CMP0045 is not set: Error on non-existent target in
get_target_property. Run "cmake --help-policy CMP0045" for policy details.
Use the cmake_policy command to set the policy and suppress this warning.

get_target_property() called with non-existent target "OUTPUT_NAME".
This warning is for project developers. Use -Wno-dev to suppress it.

-- Looking for mmap
-- Looking for mmap - found
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of void*
-- Check size of void* - done
-- Checking for [mkl_intel - mkl_intel_thread - mkl_core - iomp5 - pthread - m]
-- Library mkl_intel: not found
-- Checking for [mkl_intel - mkl_intel_thread - mkl_core - guide - pthread - m]
-- Library mkl_intel: not found
-- Checking for [mkl_intel - mkl_intel_thread - mkl_core - pthread - m]
-- Library mkl_intel: not found
-- Checking for [mkl_intel - mkl_sequential - mkl_core - m]
-- Library mkl_intel: not found
-- Checking for [mkl_intel - mkl_sequential - mkl_core - m]
-- Library mkl_intel: not found
-- Checking for [mkl_intel - mkl_sequential - mkl_core - m]
-- Library mkl_intel: not found
-- Checking for [mkl_intel - mkl_intel_thread - mkl_core - iomp5 - pthread - m]
-- Library mkl_intel: not found
-- Checking for [mkl_intel - mkl_intel_thread - mkl_core - guide - pthread - m]
-- Library mkl_intel: not found
-- Checking for [mkl_intel - mkl_intel_thread - mkl_core - pthread - m]
-- Library mkl_intel: not found
-- Checking for [mkl - guide - pthread - m]
-- Library mkl: not found
-- MKL library not found
-- Checking for [openblas - gfortran]
-- Library openblas: BLAS_openblas_LIBRARY-NOTFOUND
-- Checking for [openblas - gfortran - pthread]
-- Library openblas: BLAS_openblas_LIBRARY-NOTFOUND
-- Checking for [goto2 - gfortran]
-- Library goto2: BLAS_goto2_LIBRARY-NOTFOUND
-- Checking for [goto2 - gfortran - pthread]
-- Library goto2: BLAS_goto2_LIBRARY-NOTFOUND
-- Checking for [acml - gfortran]
-- Library acml: BLAS_acml_LIBRARY-NOTFOUND
-- Checking for [Accelerate]
-- Library Accelerate: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS11.2.sdk/System/Library/Frameworks/Accelerate.framework
-- Looking for sgemm_
-- Looking for sgemm_ - found
-- Performing Test BLAS_F2C_DOUBLE_WORKS
-- Performing Test BLAS_F2C_DOUBLE_WORKS - Failed
-- Performing Test BLAS_F2C_FLOAT_WORKS
-- Performing Test BLAS_F2C_FLOAT_WORKS - Failed
-- Found a library with BLAS API (accelerate).
-- Looking for cheev_
-- Looking for cheev_ - found
-- Found a library with LAPACK API. (accelerate)
-- Performing Test C_HAS_inline
-- Performing Test C_HAS_inline - Failed
-- Performing Test C_HAS___inline__
-- Performing Test C_HAS___inline__ - Failed
-- Performing Test C_HAS___inline
-- Performing Test C_HAS___inline - Failed
-- C inline seems not supported
CMake Warning (dev) at lib/TH/CMakeLists.txt:129 (GET_TARGET_PROPERTY):
Policy CMP0026 is not set: Disallow use of the LOCATION target property.
Run "cmake --help-policy CMP0026" for policy details. Use the cmake_policy
command to set the policy and suppress this warning.

The LOCATION property should not be read from target "TH". Use the target
name directly with add_custom_command, or use the generator expression
$<TARGET_FILE>, as appropriate.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) at lib/luaT/CMakeLists.txt:20 (GET_TARGET_PROPERTY):
Policy CMP0026 is not set: Disallow use of the LOCATION target property.
Run "cmake --help-policy CMP0026" for policy details. Use the cmake_policy
command to set the policy and suppress this warning.

The LOCATION property should not be read from target "luaT". Use the
target name directly with add_custom_command, or use the generator
expression $<TARGET_FILE>, as appropriate.

This warning is for project developers. Use -Wno-dev to suppress it.

WARNING: Could not find JPEG libraries, JPEG wrapper will not be installed
WARNING: Could not find PNG libraries, PNG wrapper will not be installed
-- Could NOT find OpenMP_C (missing: OpenMP_C_FLAGS OpenMP_C_LIB_NAMES)
-- Could NOT find OpenMP_CXX (missing: OpenMP_CXX_FLAGS OpenMP_CXX_LIB_NAMES)
-- Could NOT find OpenMP (missing: OpenMP_C_FOUND OpenMP_CXX_FOUND)
-- Configuring done
-- Generating done
-- Build files have been written to: /Users/Olivier/Downloads/torch-ios-ios/build
Scanning dependencies of target liblua-static
[ 1%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lapi.c.o
[ 2%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lcode.c.o
[ 4%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/ldebug.c.o
[ 5%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/ldo.c.o
[ 6%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/ldump.c.o
[ 8%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lfunc.c.o
[ 9%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lgc.c.o
[ 10%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/llex.c.o
[ 12%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lmem.c.o
[ 13%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lobject.c.o
[ 14%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lopcodes.c.o
[ 16%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lparser.c.o
[ 17%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lstate.c.o
[ 18%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lstring.c.o
[ 20%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/ltable.c.o
[ 21%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/ltm.c.o
[ 22%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lundump.c.o
[ 24%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lvm.c.o
[ 25%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lzio.c.o
[ 27%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lauxlib.c.o
[ 28%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lbaselib.c.o
[ 29%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/ldblib.c.o
[ 31%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/liolib.c.o
[ 32%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/lmathlib.c.o
[ 33%] Building C object exe/lua/CMakeFiles/liblua-static.dir/src/loslib.c.o
/Downloads/torch-ios-ios/exe/lua/src/loslib.c:39:22: error: 'system' is unavailable: not available on iOS
lua_pushinteger(L, system(luaL_optstring(L, 1, NULL)));
^
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS11.2.sdk/usr/include/stdlib.h:195:6: note: 'system' has been explicitly
marked unavailable here
int system(const char *) __DARWIN_ALIAS_C(system);
^
1 error generated.
make[2]: *** [exe/lua/CMakeFiles/liblua-static.dir/src/loslib.c.o] Error 1
make[1]: *** [exe/lua/CMakeFiles/liblua-static.dir/all] Error 2
make: *** [all] Error 2`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions