From fca3adbb07c466f14c943d4057be7983b8b1da31 Mon Sep 17 00:00:00 2001 From: Rafael Garcia-Suarez Date: Fri, 25 Nov 2005 10:22:22 +0000 Subject: Recognize DESTDIR from MakeMaker --- po/Makefile | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/po/Makefile b/po/Makefile index 3271f59c..bc184108 100644 --- a/po/Makefile +++ b/po/Makefile @@ -1,4 +1,5 @@ # Installation directories +PREFIX ?= $(DESTDIR) localedir = $(PREFIX)/usr/share/locale PGOAL = urpmi @@ -7,7 +8,7 @@ PGOAL = urpmi PL_FILES = ../rpm-find-leaves ../urpm.pm ../urpme ../urpmf \ ../urpmi ../urpmi.addmedia ../gurpmi ../gurpmi2 ../gurpmi.pm \ ../urpmi.removemedia ../urpmi.update ../urpmq \ - ../urpm/parallel_ka_run.pm ../urpm/parallel_ssh.pm \ + ../urpm/parallel_ka_run.pm ../urpm/parallel_ssh.pm \ ../urpm/msg.pm ../urpm/args.pm ../rurpmi # C-like files to search translatable strings in CFILES = ./placeholder.h @@ -16,7 +17,7 @@ POFILES = $(shell ls *.po) MOFILES = $(POFILES:%.po=%.mo) LANGS = $(POFILES:%.po=%) -GOALS = $(PGOAL).pot $(MOFILES) +GOALS = $(PGOAL).pot $(MOFILES) all: $(GOALS) @@ -28,9 +29,9 @@ placeholder.h: merge: $(PGOAL).pot @for n in $(POFILES); do \ - echo "Merging $$n"; \ - msgmerge "$$n" $< > "$$n"t; \ - mv -f "$$n"t "$$n"; \ + echo "Merging $$n"; \ + msgmerge "$$n" $< > "$$n"t; \ + mv -f "$$n"t "$$n"; \ done $(PGOAL).pot: $(CFILES) @@ -47,11 +48,9 @@ $(PGOAL).pot: $(CFILES) install: all for l in $(LANGS); do \ - install -d $(localedir)/$$l/LC_MESSAGES; \ - install -m 644 $$l.mo $(localedir)/$$l/LC_MESSAGES/$(PGOAL).mo; \ + install -d $(localedir)/$$l/LC_MESSAGES; \ + install -m 644 $$l.mo $(localedir)/$$l/LC_MESSAGES/$(PGOAL).mo; \ done clean: @rm -rf *~ *.mo $(GOALS) placeholder.pot $(PGOAL)_tmp.pot - - -- cgit v1.2.1