I am trying to learn GTK+3 as per this site: https://python-gtk-3-tutorial.readthedocs.org/en/latest/install.html. From the page:
1.1. Dependencies
- GTK+3
- Python 2 (2.6 or later) or Python 3 (3.1 or later)
- gobject-introspection
[...]
The easiest way to install PyGObject from source is using JHBuild. It is designed to easily build source packages and discover what dependencies need to be build and in what order. To setup JHBuild, please follow the JHBuild manual.
I followed the manual as per that link and downloaded via git JHBuild (as they say to do) and built it with make/make install. That went fine. The next step is where the problem begins. I ran the next command I was supposed to as per the page:
2.3. Build Prerequisites
Before any modules can be built, it is necessary to have certain build tools installed. Common build tools include the GNU Autotools (autoconf, automake, libtool and gettext), The GNU Toolchain (binutils, gcc, g++), make, pkg-config and Python, depending on which modules will be built.
JHBuild can check the tools are installed using the sanitycheck command:
$ jhbuild sanitycheck
When I first ran this I got this:
jhbuild: install prefix (/opt/gnome) can not be created
I ran the following commands and got the results below:
daddara@daddara-desktop:~/jhbuild/jhbuild$ sudo chmod 777 /opt/gnome/ -R
chmod: cannot access `/opt/gnome/': No such file or directory
daddara@daddara-desktop:~/jhbuild/jhbuild$ mkdir /opt/gnome
mkdir: cannot create directory `/opt/gnome': Permission denied
daddara@daddara-desktop:~/jhbuild/jhbuild$ jhbuild sanitycheck
jhbuild: install prefix (/opt/gnome) can not be created
daddara@daddara-desktop:~/jhbuild/jhbuild$ chmod 777 /opt/gnome/ -R
chmod: cannot access `/opt/gnome/': No such file or directory
daddara@daddara-desktop:~/jhbuild/jhbuild$ sudo chmod 777 /opt/gnome/ -R
chmod: cannot access `/opt/gnome/': No such file or directory
daddara@daddara-desktop:~/jhbuild/jhbuild$ jhbuild sanitycheck
jhbuild: install prefix (/opt/gnome) can not be created
daddara@daddara-desktop:~/jhbuild/jhbuild$ mkdir -p /opt/gnome
mkdir: cannot create directory `/opt/gnome': Permission denied
What the problem is with the installation?
You need to make /opt/gnome
with sudo mkdir
, then use sudo chmod
to set its permissions. You forgot the sudo
in your mkdir
.