I am trying to run the WSL toolchain on my Windows PC and have configured my WSL to run an SSH server, installed cmake etc. I am able to connect to the WSL SSH but for some reason CLion is not detecting the WSL cmake.
Any idea how I can go about fixing this ?
The problem could be the zsh shell! Try the standard bash. Perhaps it helps.
Related
I have installed PyCharm CE 2019.3 on Linux Mint Tricia and when I start PyCharm, the inbuilt terminal starts with /usr/bin/sh when I type command which bash in it.
The default system interpreter in the PyCharm setting is also showing /usr/bin/python3.7 but I want to use /bin/python3.7. The terminal shell path in PyCharm setting is showing /bin/sh by default which looks correct and for cross check I changed it to /bin/bash but the terminal shell is not changing.
I don't want to use /usr/bin/bash and /usr/bin/python3 because I need to use pyinstaller which works well only with global Python3 interpreter. Thanks!
I tried different ways including different versions of PyCharm and Linux distros. The issue is occurring when I am installing PyCharm CE from software center in latest Ubuntu (19.04) and Linux Mint. The issue is not coming when I am installing the same in Ubuntu 18.04 but the best solution I have achieved is by installing the PyCharm CE using Jetbrains toolbox and the issue is not coming even in Linux Mint 19.3. Hope, it may help someone. Thanks!
I'm trying to set up a web development environment using a guide on Medium. The author says we need to install Git for both Windows and for Windows Subsystem for Linux. Git takes up a lot of space. Do we need to install it twice?
I have Visual Studio Code and Ubuntu (WSL). I also installed Git for Windows 10.
Git For Windows differs from the Linux Git.
So, if you want to execute commands in a Windows CMD and a Linux WSL shell, then yes, you would need to install both.
On Windows side, that can mean simply uncompressing the self-extracting archive PortableGit-2.22.0-64-bit.7z.exe anywhere you want, and add it to your PATH.
I have both Ubuntu and Debian installed for WSL. When I open a WSL workspace using VS Code remote development, it always opens Ubuntu. How can I open a workspace under the Debian install using WSL in VS Code?
The VS Code Remote - WSL extension always uses the default WSL distro. You can change the default distro using the wsl command (wslconfig on earlier windows versions):
# List the available distributions
wsl --list
# Set the default version to debian
wsl --setdefault debian
After changing the default for WSL, make sure to restart VS Code
Click the "remote button" in the bottom left
Choose New Window using Distro...
Pick your distro!
I have only used Mac in the past to compile, so I am a little lost with the following issue.
I am trying to compile a program in Windows 7 through cygwin. Svn co to get the source code works, but upon $ ccmake. the error "command not found" appears. I have the devel. tools from the cygwin setup, as well as cmake and MinGW-64 installed. Where can be the bug? Is ccmake. command supported at all in cygwin?
Any hints are appreciated.
If you are using Cygwin, you should install Cmake using Cygwin as well. The package should be called "cmake". Once that is done you should find ccmake at
/usr/bin/ccmake
AKA
C:\cygwin\bin\ccmake.exe
and you should make sure your PATH contains /usr/bin
ref
I'm running Mac OS X 10.5.8 and want to compile for target CentOS 5.3 with GCC 4.1.2. How could I:
Compile GCC 4.1.2 toolchain and related tools?
Use that tool to cross compile for target CentOS 5.3?
Any help is greatly appreciated!
Your simplest solution is to just run CentOS 5.3 in a VM (e.g. Sun VirtualBox). This requires minimal setup, has quite reasonable overhead (assuming an Intel Mac), and you'll be able to actually test and debug what you are building.
If you really insist on cross-compiling, you must build a cross-compiler. Instructions are here and here, but beware: it will likely take you several days to get it right, and then you'll still need a VM to test the result, so I don't see any point in doing it that way.
Nowadays you can probably do it with Docker for Mac, I didn't test it because I have no mac. Docker basically creates a Linux VM and provides some nice-to-have functions.
Install docker and prepare your build image.
install docker
start a new container with docker run -ti centos5.3 /bin/bash (search the official Docker Hub for your desired target)
install your desired gcc version (something like sudo yum group install "Development Tools")
exit your container
run docker ps -a to obtain your container id
backup your container as base build image docker commit [id] centos:build
Make a build
Now you can use your created build environment for CentOS builds.
to start your build environment while mounting the working directory inside it you can use something like docker run -it --mount type=bind,source=$(pwd),target=/mnt centos:build /bin/sh -c "cd /mnt && bash"
then run gcc ... or ./configure or make or ninja or whatever to do your build
you can also run automated tests here if you wrote some
Docker vs VM
With docker you can use your beloved terminal with your familiar theme and keymap. Furthermore it most probably will consume less resources for startup and while running.
If your app is graphical and you test it by using interaction with its GUI I guess a VM is still a better option (see #employed-russian's solution).
Use Cocotron to cross-compile directly from Xcode. There's a good getting-started guide here: http://blog.tlensing.org/tag/cocotron/
I struggled to get crosstool-ng to build on OSX 10.9 for x86_64 Linux. I used the very helpful post on how to build a gcc cross-compiler by Jeff Preshing and his script here as the basis for a script that worked for me. His script in the link doesn't work when compiling glibc on my version of OSX (which seems to be a very common complaint for those cross-compiling from OSX to Linux).
My script is here: https://github.com/johnlondon/Cross-compile-toolchain-for-linux-on-OSX
You can use crosstool-ng, or if you don't want to spend too much time to configure it, you can download a pre-configured cross-compiler, as Linaro.
Here's the guide for installing it in Mac OS X.