I'm trying to use WSL to cross-compile a c++ program for armhf on a Windows PC.
I've was able to do it on a Debian image some years ago, and now i need to do it again on a new PC. Since the powershell command wsl.exe --install automagically installed Ubuntu Jammy, i'm fine at keeping it.
I've learned that armhf binaries are on the "ports" repository, so i added these lines to a /etc/apt/sources.list.d/armrep.list file:
Code:
deb [ arch=armhf ] http://ports.ubuntu.com/ jammy main restricted universe multiverse
deb [ arch=armhf ] http://ports.ubuntu.com/ jammy-updates main restricted universe multiverse
deb [ arch=armhf ] http://ports.ubuntu.com/ jammy-security main restricted universe multiverse
deb [ arch=armhf ] http://ports.ubuntu.com/ jammy-backports main restricted universe multiverse
Then I add the armhf architecture (sudo dpkg --add-architecture armhf) but i get a many errors like these ones:
Code:
E: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/jammy/main/binary-armhf/Packages 404 Not Found [IP: 91.189.91.83 80]
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/jammy-security/main/binary-armhf/Packages 404 Not Found [IP: 91.189.91.82 80]
E: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/jammy-updates/main/binary-armhf/Packages 404 Not Found [IP: 91.189.91.83 80]
E: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/jammy-backports/main/binary-armhf/Packages 404 Not Found [IP: 91.189.91.83 80]
E: Some index files failed to download. They have been ignored, or old ones used instead.
Then, when i try to install the gtk3 libraries (sudo apt install libgtk-3-dev:armhf) i get a whole lot of unmet dependencies errors.
Could someone tell me what should i do to build for armhf using the Ubuntu Jammy image available from the Windows Store for WSL?
Bookmarks