Azure / iot-identity-service

Source of the Azure IoT Identity Service and related services.
MIT License
37 stars 46 forks source link

fatal: not a git repository: /root/iot-identity-service/.git/modules/third-party/libtpms #550

Closed Ming-Y-ANG closed 1 year ago

Ming-Y-ANG commented 1 year ago

The following problems occurred when I used debian10 docker image to cross-compile arm32v7:

image This is my compile script:

image

Did I miss something?

arsing commented 1 year ago

You didn't clone submodules.

Ming-Y-ANG commented 1 year ago

I have previously used the following command to update the sub-repository, but it seems to have no effect:

image

arsing commented 1 year ago

Make sure your root repository or any of the submodules don't have untracked changes. Worst case make a new clone with git clone --recursive so that submodules are cloned from the start.

Ming-Y-ANG commented 1 year ago

I found that my sub-repository is in detached state. What should I do now or switch to another branch?

image

Ming-Y-ANG commented 1 year ago

I found that the problem was caused by docker directory mapping. The project path was mapped to /src in docker, but when the sub-repository was cloned, git saved the absolute path information of the host. Mapping the project source code path to the same path in the container can solve the problem:

image image Also need to modify ci/package.sh