From patchwork Thu Aug 25 14:07:08 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexandre Lissy X-Patchwork-Id: 111576 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 4DF29B6F7F for ; Fri, 26 Aug 2011 00:07:32 +1000 (EST) Received: (qmail 3325 invoked by alias); 25 Aug 2011 14:07:28 -0000 Received: (qmail 3217 invoked by uid 22791); 25 Aug 2011 14:07:27 -0000 X-SWARE-Spam-Status: No, hits=-2.4 required=5.0 tests=AWL, BAYES_00, RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx.mandriva.com (HELO mx1.mandriva.com) (212.85.150.166) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 25 Aug 2011 14:07:13 +0000 Received: from portable-alex.inria.fr (wifi-eduroam-161083.inria.fr [128.93.161.83]) by mx1.mandriva.com (Postfix) with ESMTP id 67AE3274013; Thu, 25 Aug 2011 16:07:12 +0200 (CEST) From: Alexandre Lissy To: gcc-patches@gcc.gnu.org Cc: gcc-melt@googlegroups.com, basile@starynkevitch.net, Alexandre Lissy Subject: [PATCH] [MELT] Fix installation of MELT modules Date: Thu, 25 Aug 2011 16:07:08 +0200 Message-Id: <1314281228-27687-2-git-send-email-alissy@mandriva.com> In-Reply-To: <1314281228-27687-1-git-send-email-alissy@mandriva.com> References: <20110825134531.144180@gmx.net> <1314281228-27687-1-git-send-email-alissy@mandriva.com> MIME-Version: 1.0 X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Path computation for installation in GCC's plugin/melt-modules/ path was broken (in fact not updated to the latest changes). Present commit fixes this by reading the link targets and installing them. --- contrib/ChangeLog.MELT | 2 ++ contrib/MELT-Plugin-Makefile | 10 +++++----- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/contrib/ChangeLog.MELT b/contrib/ChangeLog.MELT index 9b8123c..42f2aca 100644 --- a/contrib/ChangeLog.MELT +++ b/contrib/ChangeLog.MELT @@ -1,3 +1,5 @@ +2011-08-25 Alexandre Lissy + * MELT-Plugin-Makefile (install-melt-modules): Fix installation paths 2011-07-18 Basile Starynkevitch * MELT-Plugin-Makefile (melt_make_move): Use move-if-change. diff --git a/contrib/MELT-Plugin-Makefile b/contrib/MELT-Plugin-Makefile index 5e5baae..a4be1f0 100644 --- a/contrib/MELT-Plugin-Makefile +++ b/contrib/MELT-Plugin-Makefile @@ -288,13 +288,13 @@ install-melt-sources: melt-sources melt-all-sources ### phony makefile target from melt-build.mk install-melt-modules: melt-modules melt-all-modules $(mkinstalldirs) $(DESTDIR)/$(melt_module_dir) - for d in $(wildcard melt-modules/*); do \ - $(mkinstalldirs) $(DESTDIR)/$(melt_module_dir)/`basename $$d` ; \ - for f in $$d/*.so ; do \ - $(INSTALL_PROGRAM) $$f $(DESTDIR)/$(melt_module_dir)/`basename $$d`/`basename $$f ` ; \ - done; \ + for l in $(wildcard melt-modules/*) : ; do \ + if [ "$$l" != ":" ]; then \ + $(INSTALL_PROGRAM) `readlink $$l` $(DESTDIR)$(melt_module_dir)/$$(basename `readlink $$l`) ; \ + fi; \ done + ## install the makefile for MELT modules install-melt-mk: melt-module.mk $(mkinstalldirs) $(DESTDIR)/$(libexecsubdir)