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

Improved Windows support in Makefile #99

Merged
merged 7 commits into from
Jan 24, 2025
Merged

Improved Windows support in Makefile #99

merged 7 commits into from
Jan 24, 2025

Conversation

nateinaction
Copy link
Member

@nateinaction nateinaction commented Jan 19, 2025

This PR ensures Makefile compatibility with a native Windows workflow. This PR also creates new development guides on how to get started working in the repo for MacOS, Linux, and Windows users.

Tested all make commands on Windows, Mac and Linux machines.

@nateinaction nateinaction changed the title DRAFT Improved Windows support in Makefile Improved Windows support in Makefile Jan 19, 2025
@nateinaction nateinaction marked this pull request as ready for review January 19, 2025 21:23
@nateinaction nateinaction mentioned this pull request Jan 19, 2025
@Alandlt15
Copy link
Contributor

@nateinaction I don't know why I keep getting this error after running make install BOARD_MOUNT_POINT=/d/

image

I did do this:
mkdir /mnt/d
sudo mount -t drvfs D: /mnt/d

and had to use sudo on the first line. After that I ran this:
make install BOARD_MOUNT_POINT=/mnt/d/

But I keep on getting the same error. I ran make clean, and then make with the adafruit line back in requirements but It did not like that so I had to remove it and run make like that.

After I attach the board in PowerShell to WSL, and run 'findmnt' it doesn't show anything starting with '|-media' so that's a little weird on my end.

Unsure on how to proceed after this.

@nateinaction
Copy link
Member Author

@Alandlt15 It looks like you're missing zip. sudo apt install zip.

Hmm not sure on findmnt. Will have to see it in the lab or on video.

@Alandlt15
Copy link
Contributor

Disregard my last comment.

This time, I did the entire process through git bash and 'make install BOARD_MOUNT_POINT=/d/' worked perfectly.

  1. git cloned the repo into 'Desktop' in my windows disk.
  2. I did not have python installed so I installed; ran 'python' to verify its installed
  3. cd into the repo, switched to 'windows-make', ran make and got the various commands I could run
  4. ran 'make install BOARD_MOUNT_POINT=/d/' with no issues; all files were loaded into the board

@JamesDCowley
Copy link
Contributor

JamesDCowley commented Jan 22, 2025

I'm encountering an error when I run make build.

Creating virtual environment...
ERROR: Could not install packages due to an OSError: [WinError 5] Access is denied: 'C:\\Users\\jcowl\\AppData\\Local\\Temp\\pip-uninstall-qjfaz1v5\\pip.exe'
Check the permissions.

make: *** [Makefile:23: venv] Error 1

Deleting @$(ACTIVATE_VENV) pip install --upgrade pip --quiet was enough to fix the error for me, and both make build and make install BOARD_MOUNT_POINT=/d/ worked for me on native Windows.

EDIT: I was successfully able to run all make commands on the Linux machine in the lab without any modifications.

@nateinaction
Copy link
Member Author

This guide is confirmed working on 3 windows machines but not working with 1 windows setup. This is a good start I will work on supporting a docker-based workflow in the near future so we might resolve some of the "works on my machine issues." Merging for now.

@nateinaction nateinaction merged commit ee39406 into main Jan 24, 2025
3 checks passed
@nateinaction nateinaction deleted the windows-make branch January 24, 2025 04:30
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

Successfully merging this pull request may close these issues.

3 participants