I'm trying to set up the emscripten SDK on Windows 10 but emcc can't be found - windows

On linux there's no problem but I want to compile my code on windows. I follow the instructions exactly. Specifically, I open a command prompt and run the following in the same directory I cloned the emscripten git repo in to.
git pull
emsdk install latest
emsdk activate latest
emsdk_env.bat
There is suspiciously no output and emcc cannot be found. What could I be doing wrong here?

If you go to the command line and type python --version the version of python installed should come up.
If it doesn't, go to the directory in which python is installed and add this to your PATH.
Restart the command prompt and try python --version again. If you get the version of python, follow the steps you mentioned.
You should get some output.
Let me know if the problem still has not been resolved.

You need to install Python 2.7.12 or newer.
https://emscripten.org/docs/getting_started/downloads.html#windows

Related

cygwin bash not returning a valid result

I am following this :
Step 2: Installing Cygwin
Cygwin can be downloaded from http://www.cygwin.com
Run the setup file.
Install from internet. Specify C:\cygwin as the root directory.
In the Select Packages dialog box, select the packages required. gcc-core, gcc-g++, gdb, and make packages are most important. These are the C core, C++ core, the GNU Debugger and the GNU version of ‘make’ utility. These packages will be under the ‘Devel’ category.
Complete the installation.
Step 3: Testing Cygwin
To test whether Cygwin was installed properly, try the following by opening the bash shell:
cygcheck -c cygwin
gcc --version
g++ --version
make --version
gdb --version
If the version details are displayed for all these commands, the installation of Cygwin has been successful.
I got this from here
But the result I get is:
What is wrong or missing with my installation.
Follow up question:
I wanted to use the terminal window in netbeans that is why I installed this.
In this terminal widnow I also have problem. I cant type anything on it. Is this the reason for it?
Try to run /usr/bin/g++. If it is not found, then you don't have g++ installed (installation may have had problems).
You can follow the same procedure for the rest of your commands
If /usr/bin/g++ runs successfully, it means you don't have /usr/bin in your PATH (which is very unlikely). You can put that in your PATH in your startup file.

Issues while trying to run git uninstall.sh on Mac OS

I wanted to try to update Git on my Mac OS to the latest version and it says to run the provided uninstall.sh first. I must confess that I ran the pkg before reading the "Read me". Not sure if that screwed it all up ...
Now I am not big with the terminal and found the following command to run a shell script:
$ sh uninstall
but that resulted in:
/usr/sbin/uninstall: /usr/sbin/uninstall: cannot execute binary file
where I got stuck now.
Any idea what I have to do to resolve this error?
You should run the uninstall.sh packaged with your previous distribution of Git, as explained in "Install and Update to latest version Git on Mac OSX 10.10 Yosemite":
Upgrading Git from a previous version to the latest 2.0.1
If you have previously installed Git you can upgrade to the latest version by uninstalling the previous install using the uninstall.sh file with the installation.
Go through the same process of downloading and mounting and the .dmg – then launch the Terminal.
uninstall and uninstall.sh are two different things. The former is a binary that comes with the os, the latter is a shell script that comes with the package.
Try: sh uninstall.sh instead

Github not installed in terminal os

I downloaded and installed GitHub (latest version) for OS X, installed command line utility under Github in the application and am coming up with an error trying to create my first readme file in a repo entitled "basic-twitbstrap".
Macbooks-MacBook-Pro-2:basic-twitbstrap macbook$ git init
-bash: git: command not found
If they're not installed in standard location, command-line programs need some environment modifications to be called, which consists in adding their directory to the PATH environment variable.
So in your case you need to add /usr/local/github to your path, see how.
I installed the latest version of Ruby Version Manager, then entered 'git' into the Terminal. It came up with a list of usage and common commands.
Now it runs.
Macbooks-MacBook-Pro-2:~ macbook$ git --version
git version 1.7.4.4

Using Google App Engine SDK with Python 2.7 on Mac OS X 10.6

I need to run Python 2.7 on my Mac Snow Leopard, which has Python 2.6 installed. According to this answer, running the Python 2.7 mpkg installer from Python.org should get me there.
The reason I need to do this is that I'm trying to run the Google App Engine SDK for the Python 2.7 runtime.
After installing Python 2.7, I'm still getting the following warning in my GAE server log:
Warning: You are using a Python runtime (2.6) that is older than the
production runtime environment (2.7).
What else must I do to get the GAE SDK to recognize the new Python version?
EDIT 2:
Running:
$ sudo find / -name python2.7
I get:
/Library/Frameworks/Python.framework/Versions/2.7/bin/python2.7
/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7
/usr/local/bin/python2.7
According to the answers I went into GoogleAppLauncher -> Preferences and set the Python path to each of these, and each time I get the exact same error.
Running dev_appserver with the following flags:
--admin_console_server= --port=8081 Python command: /Library/Frameworks/Python.framework/Versions/2.7 2011-11-14
16:12:24.726 GoogleAppEngineLauncher[57590:203] *** NSTask: Task
create for path '/Library/Frameworks/Python.framework/Versions/2.7'
failed: 22, "Invalid argument". Terminating temporary process.
Another Wierd thing is, it always tries to resolve to the same path, no matter which of those I plug in; It always reverts to /Library/Frameworks/Python.framework/Versions/2.7
EDIT 3:
OK, after entering the paths into the prefs field repeatedly, I finally just cleared it out, and somehow it's now pointing to the right place:
Running dev_appserver with the following flags:
--admin_console_server= --port=8081
Python command: /usr/local/bin/python2.7
Open the GAE launcher preferences and set the Python Path option to the fresh installed Python 2.7, in your case /usr/local/bin/python2.7 .
Came across this question looking for a solution to the same dilemma regarding Mac, GAE and Python.
One comment I would like to make regarding setting the Python path using GAE Preferences. I notice you mention that you had a problem setting the Python path using the Preferences. I discovered that after editing the path, you have to press Enter. Otherwise, the path doesn't get updated. This might explain the weirdness you were mentioning when trying to edit the path field.
I installed python 2.7.x from macports. I see this:
$ python --version
Python 2.7.2
$ which python
/opt/local/bin/python
So, in the preferences for GoogleAppEngineLauncher.app I set the python path to:
/opt/local/bin/python
In the console log, I see this:
*** Running dev_appserver with the following flags:
--admin_console_server= --port=8081
Python command: /opt/local/bin/python
I still see some errors about libraries, in particular Can't open zipfile...setuptools but simple stuff at least seems to work.
Good luck!
I am not sure if it helps, but instead of using the binaries from Python, I used MacPorts http://www.macports.org/ and installed the Python 2.7 runtime:
sudo port install python27

Where is PyGTK for Mac OS X?

Is there a binary out there for the current mac os x, python for PyGTK? I work with multiple desktop environments (mac, windows, gnome) and really consider python's lack of cross platform GUI's a problem. Does anyone know where I can find a built version of PyGTK and GTK for Mac?
I cant clone the git repository, it keeps timing out.
brew install pygtk worked for me (requires homebrew).
Confirmed to work with OS X 10.10 too, but by default it will install it into brew's Python distribution, so if you are still using the native python, it will not find it.
I don't use macports but it seems that jhbuild works for me. Below is the steps that I've done.
download gtk-osx-build-setup.sh from: https://raw.github.com/jralls/gtk-osx-build/master/gtk-osx-build-setup.sh and save it to your home directory.
fire up terminal and navigate to your home directory and run the command sh gtk-osx-build-setup.sh
the shell script will warn you that ~/.local/bin isn't added to your environment variable to do this, edit your .profile file located at your home directory and /Users/<username>/.local/bin to your environment variable. to know more on how to edit this file check out: http://www.tech-recipes.com/rx/2621/os_x_change_path_environment_variable/
after that, do a ~/.local/bin/jhbuild bootstrap command. it will download and install some necessary utilities.
download and install the beta version of the gtk+ osx framework at: http://ftp.imendio.com/pub/imendio/gtk-osx/Gtk-Framework-2.14-LATEST.dmg
before installing the meta-gtk-osx-python, you need to build and install some other packages that jhbuild doesn't install automatically, so what i did was i installed libpng by doing the command: ~/.local/bin/jhbuild build libpng
you also need to install libtiff so do the command: ~/.local/bin/jhbuild build libtiff
and also gtk-doc is needed so: ~/.local/bin/jhbuild build gtk-doc
and finally you can now install meta-gtk-osx-python by doing a: ~/.local/bin/jhbuild build meta-gtk-osx-python
Let me know if it works.
There is an installer for PyGTK 2.24 in test here, announced on the PyGTK list.
UPDATE project has moved on macpkg's sourceforge page.
I couldn't make it work with meld (segmentation fault), but sample PyGTK programs work OK.
UPDATE 2 since then a new package Py3GTK3 appeared on the same sourceforge page. Haven't tested though.
There is now a mac package on sourceforge
Download the latest package from http://sourceforge.net/projects/macpkg/files/PyGTK/ and install.
If you're just trying to use the system python, this is all you'll have to do.
If you're not, the following is how to install it with pyenv, which can be installed with Homebrew. With brew installed, you can install version pyenv and Python 2.7.8 with:
brew install pyenv && pyenv install 2.7.8
After you've done that, you'll then have copy the gtk package and its dependencies into your python installation:
cd /opt/gtk/lib/python2.7/site-packages/ && \
cp * ~/.pyenv/versions/2.7.8/lib/python2.7/site-packages/
That's it. You can also similarly install the Py3GTK3 package which has packages for python 2.7 and 3.2 from http://sourceforge.net/projects/macpkg/files/Py3GTK3/.
Have you tried doing it using macports? This website shows how.

Resources