Closed yblainm closed 1 year ago
I git cloned the various dependencies' sources by googling (for lvgl I needed to checkout releases/v7
). Running /opt/build.sh
now passes the above errors, but fails at the following:
138 | lv_disp_set_direction(lv_disp_get_default(), 1);
| ^~~~~~~~~~~~~~~~~~~~~
| lv_disp_set_rotation
(and other such errors) followed by
gmake[2]: *** [src/CMakeFiles/pinetime-mcuboot-app.dir/build.make:1546: src/CMakeFiles/pinetime-mcuboot-app.dir/displayapp/LittleVgl.cpp.o] Error 1
gmake[2]: *** Waiting for unfinished jobs....
/sources/src/components/heartrate/Ppg.cpp: In member function 'int Pinetime::Controllers::Ppg::ProcessHeartRate(bool)':
/sources/src/components/heartrate/Ppg.cpp:203:3: error: 'ArduinoFFT' was not declared in this scope; did you mean 'arduinoFFT'?
203 | ArduinoFFT<float> FFT = ArduinoFFT<float>(vReal.data(), vImag.data(), dataLength, sampleFreq);
| ^~~~~~~~~~
| arduinoFFT
/sources/src/components/heartrate/Ppg.cpp:203:14: error: expected primary-expression before 'float'
203 | ArduinoFFT<float> FFT = ArduinoFFT<float>(vReal.data(), vImag.data(), dataLength, sampleFreq);
| ^~~~~
/sources/src/components/heartrate/Ppg.cpp:204:3: error: 'FFT' was not declared in this scope
204 | FFT.compute(FFTDirection::Forward);
| ^~~
/sources/src/components/heartrate/Ppg.cpp:206:18: error: expected class-name before '(' token
206 | FFT.~ArduinoFFT();
| ^
gmake[2]: *** [src/CMakeFiles/pinetime-mcuboot-app.dir/build.make:1644: src/CMakeFiles/pinetime-mcuboot-app.dir/components/heartrate/Ppg.cpp.o] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:329: src/CMakeFiles/pinetime-mcuboot-app.dir/all] Error 2
gmake: *** [Makefile:91: all] Error 2
I assume this is due to me providing the wrong versions of the dependencies.
Make sure to just clone the repo with submodules, or initialize them afterwards. It's inadvisable to start and manually find all the dependencies.
To be clear, I should clone the repository using git clone --recurse-submodules
, right? That appears to have been the problem.
Apologies for my ignorance. For future reference, is there anywhere I would look to know that in advance? I suppose there is a .gitmodules, after all.
It mentions running git submodule update --init
in doc/buildAndProgram.md
, perhaps that should also be added to the Docker build instructions?
Verification
What happened?
I tried to follow the instructions at https://github.com/InfiniTimeOrg/InfiniTime/blob/main/doc/buildWithDocker.md (whether I build the image myself or not) but it fails because it can't find various libs/... files
What should happen instead?
No response
Reproduction steps
docker build -t infinitime-build ./docker
docker run --rm -it -v ${PWD}:/sources --user $(id -u):$(id -g) infinitime-build /opt/build.sh pinetime-app
I also tried
((HEAD detached at 1.13.0))$ docker run --rm -it -v ${PWD}:/sources --user $(id -u):$(id -g) infinitime/infinitime-build
and got the sameMore details?
Here's what I ran and the output I got. To highlight:
I note that when I run the image with bash and look in
/sources/src/libs/lvgl/
, it's empty. I'm not sure if there's a dependency that I need to provide outside or if the Dockerfile is missing something.Version
1.13.0
Companion app
No response