Page 1 of 2 12 LastLast
Results 1 to 10 of 20

Thread: Cannot do make install

  1. #1

    Default Cannot do make install

    A package compiled successfully in OBS but now cannot do make install:

    make install
    install -d -m 777 /usr/local
    install: cannot change permissions of `/usr/local': Operation not permitted

    What to do to mitigate this now?

  2. #2

    Default Re: Cannot do make install

    Hi,

    Seems your package is not configured well and installs to the root dir of the machine, which is not authorized, instead files should be installed to the temporary dir %{buildroot}%{_prefix}

    if you're using autotools you can try something like :
    make DESTDIR=%{buildroot} install
    make prefix=%{buildroot}%{_prefix} install

    or with cmake try to configure with -DCMAKE_INSTALL_PREFIX=%{buildroot}%{_prefix}

    else modify your Makefile to support this kind install process

    xan

  3. #3

    Default Re: Cannot do make install

    if you're using autotools you can try something like :
    make DESTDIR=%{buildroot} install
    make prefix=%{buildroot}%{_prefix} install
    Neither works Still tries to install into /usr/local

  4. #4
    Join Date
    Oct 2008
    Location
    Lakeland, Florida
    Posts
    235

    Default Re: Cannot do make install

    You need to run Make Install as root.
    P5N-E SLI, Core2Duo E6850 @ 3GHZ, 2 GB DDR2 800MHZ
    EVGA 8800GTS 320MB, 2x320GB HDD
    Arctic Cooling Freezer 7 Pro

  5. #5

    Default Re: Cannot do make install

    Quote Originally Posted by markcynt View Post
    You need to run Make Install as root.
    When building an RPM? Certainly not!

  6. #6

    Default Re: Cannot do make install

    Well I solved this problem by passing the prefix to configure. But now I have another similar problem:

    install -d -m 644 /opt/kde3/share/locale/de/LC_MESSAGES
    install: cannot change permissions of `/opt/kde3/share/locale/de/LC_MESSAGES': Operation not permitted
    make: *** [install] Error 1

  7. #7
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    26,846
    Blog Entries
    15

    Default Re: Cannot do make install

    Quote Originally Posted by Ansus

    > if you're using autotools you can try something like :
    > make DESTDIR=%{buildroot} install
    > make prefix=%{buildroot}%{_prefix} install


    Neither works Still tries to install into /usr/local
    Hi
    You need to run your configure command with either;
    Code:
    --prefix=%{_prefix}
    
    --prefix=/usr
    As note you never need to build and rpm as root....

    --
    Cheers Malcolm (Linux Counter #276890)
    SUSE Linux Enterprise Desktop 11 (x86_64) Kernel 2.6.27.45-0.1-default
    up 2 days 23:07, 4 users, load average: 0.26, 0.18, 0.06
    GPU GeForce 8600 GTS Silent - CUDA Driver Version: 190.53


  8. #8
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    26,846
    Blog Entries
    15

    Default Re: Cannot do make install

    Quote Originally Posted by Ansus
    Well I solved this problem by passing the prefix to configure. But now I
    have another similar problem:

    > install -d -m 644 /opt/kde3/share/locale/de/LC_MESSAGES
    > install: cannot change permissions of
    > `/opt/kde3/share/locale/de/LC_MESSAGES': Operation not permitted
    > make: *** [install] Error 1
    Hi
    Use the macro %{makeinstall} or use;
    Code:
    make DESTDIR=%{buildroot} install
    --
    Cheers Malcolm (Linux Counter #276890)
    SUSE Linux Enterprise Desktop 11 (x86_64) Kernel 2.6.27.45-0.1-default
    up 2 days 23:16, 3 users, load average: 0.24, 0.18, 0.10
    GPU GeForce 8600 GTS Silent - CUDA Driver Version: 190.53


  9. #9

    Default Re: Cannot do make install

    You need to run your configure command with either;
    Yes! This is exactly what helped with the /usr/local issue :-)

  10. #10

    Default Re: Cannot do make install

    Use the macro %{makeinstall} or use;

    make DESTDIR=%{buildroot} install
    This does not help.

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •