TFLite Path Prefix Issue

Trying to build tflite with cmake, as an installable package. With folder containing:
-tflite_build
-tensorflow_src (repo)

Running from tflite_build:
cmake ../tensorflow_src/tensorflow/lite -DTFLITE_ENABLE_INSTALL=ON

I get the following error:

-- Configuring done
CMake Error in CMakeLists.txt:
  Target "tensorflow-lite" INTERFACE_INCLUDE_DIRECTORIES property contains
  path:

    "/home/makuch/repos/tflite_build/gemmlowp"

  which is prefixed in the build directory.


CMake Error: install(EXPORT "tensorflow-liteTargets" ...) includes target "tensorflow-lite" which requires target "absl_flags" that is not in any export set.
CMake Error: install(EXPORT "tensorflow-liteTargets" ...) includes target "tensorflow-lite" which requires target "absl_hash" that is not in any export set.
CMake Error: install(EXPORT "tensorflow-liteTargets" ...) includes target "tensorflow-lite" which requires target "absl_status" that is not in any export set.
CMake Error: install(EXPORT "tensorflow-liteTargets" ...) includes target "tensorflow-lite" which requires target "absl_strings" that is not in any export set.
CMake Error: install(EXPORT "tensorflow-liteTargets" ...) includes target "tensorflow-lite" which requires target "absl_synchronization" that is not in any export set.
CMake Error: install(EXPORT "tensorflow-liteTargets" ...) includes target "tensorflow-lite" which requires target "absl_variant" that is not in any export set.
CMake Error: install(EXPORT "tensorflow-liteTargets" ...) includes target "tensorflow-lite" which requires target "ruy" that is not in any export set.
CMake Error: install(EXPORT "tensorflow-liteTargets" ...) includes target "tensorflow-lite" which requires target "pthreadpool" that is not in any export set.
CMake Error: install(EXPORT "tensorflow-liteTargets" ...) includes target "tensorflow-lite" which requires target "XNNPACK" that is not in any export set.
-- Generating done
CMake Generate step failed.  Build files cannot be regenerated correctly.

I’ve tried moving the folder, but unsure how I could change where tf puts this folder during build (gemmlwop).

Thanks!

Hi @Alex_Makuch, For example if you create cmake build directory named as tflite_build once you execute the build command the file will be generated in the tflite_build directory. Thank You.