Generate header file with biicode

87 views Asked by At

I'm trying to prepare onion (https://github.com/davidmoreno/onion) for biicode, but I need to generate a header file using some program I compile previously. I already have cmake doing it, but I do not succeed properly packaging onion for biicode.

The error right now is:

...oterm/oterm.c:44:20: fatal error: assets.h: No such file or directory

this header should be compiled with (edited for brevity):

../tools/opack/opack ../../examples/oterm/static -o ../../build/examples/oterm/oterm_data.c 

and the header is generated as a byproduct.

The current cmake rule is:

add_custom_command(
   OUTPUT oterm_data.c
   COMMAND ${OPACK} ${CMAKE_CURRENT_SOURCE_DIR}/static
              -o ${CMAKE_CURRENT_BINARY_DIR}/oterm_data.c
   DEPENDS ${OPACK} ${CMAKE_CURRENT_SOURCE_DIR}/static/*
   )

Another option would be to do not compile examples at all, but I prefer an answer that compiles everything properly.

The current code is at branch biicode at https://github.com/davidmoreno/onion

Thanks!

0

There are 0 answers