tuupola / hagl

Hardware Agnostic Graphics Library for embedded

Home Page:https://www.appelsiini.net/tags/hagl/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

cmake doesn't work

orzel opened this issue · comments

I'm using linux. Running cmake from a fresh checkout fails with:

Unknown CMake command "idf_component_register".

According to google, that's something related to ESP, which is not my platform. I kinda assumed it was not bound to ESP ("hardware agnostic"). Did I miss something ? Or should it be fixed ?

While I'm at it. If i understand well, the MIPI "driver" is only for SPI displays. Is it planned to support parallel (8bit) displays ? Would it be difficult to add ?

This should have been fixed with #35. I do have a plan to write a HAL for parallel displays. I just do not have any at hand at the moment. Creating a new HAL (or actually should be called Platform Abstraction Layer) is not complicated. At minimum it should provide a put pixel function. Anything else is optional.

I should create a skeleton for this. In the meanwhile Raspberry Pi Pico HAL is probably easiest to read the source.

Hi. After updating (git pull), i confirm i dont have this error anymore. But cmake now outputs this, and then 'make' does nothing..

CMake Warning (dev) in CMakeLists.txt:
  No project() command is present.  The top-level CMakeLists.txt file must
  contain a literal, direct call to the project() command.  Add a line of
  code such as

    project(ProjectName)

  near the top of the file, but after cmake_minimum_required().

  CMake is pretending there is a "project(Project)" command on the first
  line.
This warning is for project developers.  Use -Wno-dev to suppress it.

CMake Warning (dev) in CMakeLists.txt:
  No cmake_minimum_required command is present.  A line of code such as

    cmake_minimum_required(VERSION 3.22)

  should be added at the top of the file.  The version specified may be lower
  if you wish to support older CMake versions for this project.  For more
  information run "cmake --help-policy CMP0000".
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Configuring done
-- Generating done
-- Build files have been written to: /home/orzel/clones/hagl

How does your your projects CMakeLists.txt look like? Does it have the missing commands cmake complains about?

Here is a couple of examples of those files. How they should look for you depends on the SDK or framework you are using so YMMV.

https://github.com/tuupola/k210_gfx/blob/master/CMakeLists.txt
https://github.com/tuupola/pico_gfx/blob/master/CMakeLists.txt

I was just using the CMakeLists.txt from this project. I now understand it can only be included from another one.

Yeah, I have not even though yet about how to compile only this library alone with cmake. I have only compiled it as a part of a bigger project.