[MPlayer-dev-eng] Re: install localized manpages + [PATCH#2]

Andriy N. Gritsenko andrej at lucky.net
Mon Feb 17 13:16:02 CET 2003


    Hi, Gabucino!

Sometime (on Monday, February 17 at 13:34) I've received something...
>Andriy N. Gritsenko wrote:
>> See attached patch against current CVS. It will work.
>It will not. Next time test your patch!!

I've tested it but in my environment LINGUAS was set.

>./configure --prefix=/usr --confdir=/etc/mplayer --enable-runtime-cpudetection --enable-gui  --enable-menu --enable-xmms
>/bin/ls: ??_??: No such file or directory
>./configure: LINGUAS: command not found

OOPS, sorry, I leaved extra space in command. :(
Fixed patch attached.

>> Commit it, please.
>Whatnot.

>> >Anyway, if there are no objections, I'll commit this in an hour.
>> I have an objection. ;)
>Too late :)

May be but may be not. ;)

    With best wishes.
    Andriy.
-------------- next part --------------
diff -udpr MPlayer-20030217.orig/Makefile MPlayer-20030217/Makefile
--- MPlayer-20030217.orig/Makefile	Sun Feb 16 16:14:13 2003
+++ MPlayer-20030217/Makefile	Mon Feb 17 13:04:14 2003
@@ -247,10 +247,25 @@ ifeq ($(GUI),yes)
 endif
 	if test ! -d $(MANDIR)/man1 ; then mkdir -p $(MANDIR)/man1; fi
 	$(INSTALL) -c -m 644 DOCS/en/mplayer.1 $(MANDIR)/man1/mplayer.1
-	@for LCLMANS in de fr hu pl; do $(INSTALL) -D -c -m 644 DOCS/$$LCLMANS/mplayer.1 $(MANDIR)/$$LCLMANS/man1/mplayer.1; done
+	@if [ -n "$(LANGUAGES)" ]; then \
+	    for i in $(LANGUAGES); do \
+		if [ -f DOCS/$$i/mplayer.1 ]; then \
+		    echo "Installing manual for language $$i" ; \
+		    mkdir -p $(MANDIR)/$$i/man1 ; \
+		    $(INSTALL) -c -m 644 DOCS/$$i/mplayer.1 $(MANDIR)/$$i/man1/mplayer.1 ; \
+		fi ; \
+	    done ; \
+	fi
 ifeq ($(MENCODER),yes)
 	$(INSTALL) -m 755 $(INSTALLSTRIP) $(PRG_MENCODER) $(BINDIR)/$(PRG_MENCODER)
-	@for LCLMANS in de fr hu pl; do ln -sf mplayer.1 $(MANDIR)/$$LCLMANS/man1/mencoder.1; done
+	ln -sf mplayer.1 $(MANDIR)/man1/mencoder.1
+	@if [ -n "$(LANGUAGES)" ]; then \
+	    for i in $(LANGUAGES); do \
+		if [ -f DOCS/$$i/mplayer.1 ]; then \
+		    ln -sf mplayer.1 $(MANDIR)/$$i/man1/mencoder.1 ; \
+		fi ; \
+	    done ; \
+	fi
 endif
 	@if test ! -d $(DATADIR) ; then mkdir -p $(DATADIR) ; fi
 	@if test ! -d $(DATADIR)/font ; then mkdir -p $(DATADIR)/font ; fi
diff -udpr MPlayer-20030217.orig/configure MPlayer-20030217/configure
--- MPlayer-20030217.orig/configure	Sat Feb 15 23:51:24 2003
+++ MPlayer-20030217/configure	Mon Feb 17 13:49:55 2003
@@ -293,6 +293,10 @@ EOF
 done # for parm in ...
 
 
+# set up LANGUAGES
+test "$LINGUAS" || LINGUAS=`cd DOCS;/bin/ls -d ?? ??_??` 2>/dev/null
+LANGUAGES=`echo $LINGUAS | sed 's/en//g' | sed 's/^ *//'`
+
 # 1st pass checking for vital options
 _install=install
 _ranlib=ranlib
@@ -4808,6 +4812,7 @@ cat > config.mak << EOF
 
 LANG = C
 LINGUAS = $LINGUAS
+LANGUAGES = $LANGUAGES
 TARGET_OS = $system_name
 DESTDIR =
 prefix = \$(DESTDIR)$_prefix


More information about the MPlayer-dev-eng mailing list