Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nested submodule issue #105

Open
gdewald opened this issue Sep 13, 2024 · 0 comments
Open

Nested submodule issue #105

gdewald opened this issue Sep 13, 2024 · 0 comments

Comments

@gdewald
Copy link

gdewald commented Sep 13, 2024

I added the NodeMCU firmware repository as a submodule (inside a directory named firmware), and encountered the following issue when building using the Docker build image:

$ docker run --rm -ti -v `pwd`:/opt/nodemcu-firmware marcelstoer/nodemcu-build build
fatal: Not a git repository: ../.git/modules/firmware

The above issue goes away if I clone the firmware repository directly (not as a submodule).

Commands to reproduce:

mkdir myrepo && cd myrepo
git init .
git submodule add https://github.com/nodemcu/nodemcu-firmware.git firmware
git submodule update --recursive --init 
(cd firmware && docker run --rm -ti -v `pwd`:/opt/nodemcu-firmware marcelstoer/nodemcu-build build)

From a cursory look it seems the scripts rely on the firmware being located inside a valid git repository, which would not be the case when mounting the submodule folder directly (as the .git folder would be in the top level directory of the parent git repository).

The build also fails if you attempt using source code from a release, e.g. 3.0.0-release_20240225, but with the below message:

fatal: Not a git repository (or any parent up to mount point /opt/nodemcu-firmware)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant