1

I run below commands after unzipping that python 3.6 tar.xz file.

./configure
make
make install

Error log:

ranlib libpython3.6m.a
gcc -pthread -Xlinker -export-dynamic -o python Programs/python.o libpython3.6m.a -lpthread -ldl -lutil -lrt -lm 
if test "no-framework" = "no-framework" ; then \
 /usr/bin/install -c python /usr/local/bin/python3.6m; \
 else \
 /usr/bin/install -c -s Mac/pythonw /usr/local/bin/python3.6m; \
 fi
/usr/bin/install: cannot create regular file `/usr/local/bin/python3.6m': Read-only file system
make: *** [altbininstall] Error 1

When i run ./configure followed by make , and then make install i run into this error!

Klaus D.
14.5k5 gold badges44 silver badges53 bronze badges
asked Jun 1, 2017 at 5:53
7
  • sudo make install Commented Jun 1, 2017 at 5:56
  • i'm already running as root user! Commented Jun 1, 2017 at 5:57
  • @KlausD. [root@machinename Python-3.6.1]# sudo make install if test "no-framework" = "no-framework" ; then \ /usr/bin/install -c python /usr/local/bin/python3.6m; \ else \ /usr/bin/install -c -s Mac/pythonw /usr/local/bin/python3.6m; \ fi /usr/bin/install: cannot create regular file `/usr/local/bin/python3.6m': Read-only file system make: *** [altbininstall] Error 1 Commented Jun 1, 2017 at 5:58
  • 2
    Your file system is read only. Commented Jun 1, 2017 at 5:58
  • @KlausD Can't i do anything to make it work? I know the root password! Commented Jun 1, 2017 at 5:59

3 Answers 3

1

Have you tried running the above commands using sudo powers?

original answer: https://askubuntu.com/q/865554/667903

sudo make install

or

If you are using Ubuntu 16.10 or 17.04, then Python 3.6 is in the universe repository, so you can just run

sudo apt-get update
sudo apt-get install python3.6
answered Jun 1, 2017 at 5:59
Sign up to request clarification or add additional context in comments.

2 Comments

Yes i have done that. [root@slc05kyt Python-3.6.1]# sudo make install if test "no-framework" = "no-framework" ; then \ /usr/bin/install -c python /usr/local/bin/python3.6m; \ else \ /usr/bin/install -c -s Mac/pythonw /usr/local/bin/python3.6m; \ fi /usr/bin/install: cannot create regular file `/usr/local/bin/python3.6m': Read-only file system make: *** [altbininstall] Error 1
the machine uses yum
1

Your filesystem seems to be read-only. You have to remount the partition where /usr/local/bin/ is located with write permissions

The syntax for mount is

mount -o remount,rw /partition/identifier /mount/point

Let's say you have / on /dev/sda2

mount -o remount,rw / /dev/sda2

should fix your problem.

To check your mount points: cat /etc/fstab or df

To check the permissions: cat /proc/mounts

answered Jun 1, 2017 at 6:26

1 Comment

Thanks , i guess you identified the issue, i will try your solution and let you know how it went.
0

Try after installing build essentials whic contains compilers,package dev tools and libs: sudo apt-get install build-essential

answered Jun 1, 2017 at 6:03

1 Comment

My machine uses yum!

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.