[PD-dev] [pure-data:bugs] #1101 make install fails if already installed to the same prefix

Claude Heiland-Allen claudiusmaximus at users.sf.net
Wed Aug 7 13:09:25 CEST 2013




---

** [bugs:#1101] make install fails if already installed to the same prefix**

**Status:** open
**Labels:** buildsystem 
**Created:** Wed Aug 07, 2013 11:09 AM UTC by Claude Heiland-Allen
**Last Updated:** Wed Aug 07, 2013 11:09 AM UTC
**Owner:** nobody

Pd fresh from git.


Reproduction
------------

    ./autogen.sh ; ./configure --prefix=${HOME}/opt ; make ; make install ; make install


What Happens
------------


    ln: failed to create symbolic link `expr.pd_linux': File exists
    ln: failed to create symbolic link `fexpr~.pd_linux': File exists
    ln: failed to create symbolic link `expr.pd_linux': File exists
    ln: failed to create symbolic link `expr~.pd_linux': File exists
    ln: failed to create symbolic link `fexpr~.pd_linux': File exists
    ln: failed to create symbolic link `expr-help.pd': File exists
    ln: failed to create symbolic link `expr~-help.pd': File exists
    ln: failed to create symbolic link `fexpr~-help.pd': File exists
    make[5]: *** [install-data-hook] Error 1
    make[4]: *** [install-data-am] Error 2
    make[3]: *** [install-am] Error 2
    make[2]: *** [install-recursive] Error 1
    make[1]: *** [install-recursive] Error 1
    make: *** [install] Error 2


Expected Happenings
-------------------

Pd's make install doesn't break if Pd has already been installed to the same prefix.


Simple Bugfix
-------------

    diff --git a/extra/expr~/GNUmakefile.am b/extra/expr~/GNUmakefile.am
    index ab93dd9..b976dc3 100644
    --- a/extra/expr~/GNUmakefile.am
    +++ b/extra/expr~/GNUmakefile.am
    @@ -26,15 +26,15 @@ externaldir = $(pkglibdir)/extra/$(NAME)
     # so we install everything in the install-data-hook
     install-data-hook:
        cd $(DESTDIR)$(externaldir) && ( \
    -     $(LN_S) expr~. at EXTERNAL_EXTENSION@ expr. at EXTERNAL_EXTENSION@; \
    -     $(LN_S) expr~. at EXTERNAL_EXTENSION@ fexpr~. at EXTERNAL_EXTENSION@; \
    +     $(LN_S) -f expr~. at EXTERNAL_EXTENSION@ expr. at EXTERNAL_EXTENSION@; \
    +     $(LN_S) -f expr~. at EXTERNAL_EXTENSION@ fexpr~. at EXTERNAL_EXTENSION@; \
          cd ..; \
    -     $(LN_S) $(NAME)/expr. at EXTERNAL_EXTENSION@ expr. at EXTERNAL_EXTENSION@; \
    -     $(LN_S) $(NAME)/expr~. at EXTERNAL_EXTENSION@ expr~. at EXTERNAL_EXTENSION@; \
    -     $(LN_S) $(NAME)/fexpr~. at EXTERNAL_EXTENSION@ fexpr~. at EXTERNAL_EXTENSION@; \
    -     $(LN_S) $(NAME)/expr-help.pd expr-help.pd; \
    -     $(LN_S) $(NAME)/expr-help.pd expr~-help.pd; \
    -     $(LN_S) $(NAME)/expr-help.pd fexpr~-help.pd; \
    +     $(LN_S) -f $(NAME)/expr. at EXTERNAL_EXTENSION@ expr. at EXTERNAL_EXTENSION@; \
    +     $(LN_S) -f $(NAME)/expr~. at EXTERNAL_EXTENSION@ expr~. at EXTERNAL_EXTENSION@; \
    +     $(LN_S) -f $(NAME)/fexpr~. at EXTERNAL_EXTENSION@ fexpr~. at EXTERNAL_EXTENSION@; \
    +     $(LN_S) -f $(NAME)/expr-help.pd expr-help.pd; \
    +     $(LN_S) -f $(NAME)/expr-help.pd expr~-help.pd; \
    +     $(LN_S) -f $(NAME)/expr-help.pd fexpr~-help.pd; \
        )
     
     uninstall-hook:


The -f flag for ln is specified by POSIX, but I could only test on Debian Wheezy with ln (GNU coreutils) 8.13

Probably would be better to get the configure script to check the best way to force symlink update...



---

Sent from sourceforge.net because pd-dev at lists.iem.at is subscribed to https://sourceforge.net/p/pure-data/bugs/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pure-data/admin/bugs/options.  Or, if this is a mailing list, you can unsubscribe from the mailing list.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-dev/attachments/20130807/b0ad70cf/attachment.htm>


More information about the Pd-dev mailing list