summaryrefslogtreecommitdiff
path: root/editors/openoffice-1.0
diff options
context:
space:
mode:
authorMartin Blapp <mbr@FreeBSD.org>2003-01-21 17:09:39 +0000
committerMartin Blapp <mbr@FreeBSD.org>2003-01-21 17:09:39 +0000
commita2d8d8b86dd8597ac7432068126509debdb8f450 (patch)
treeee9e27344cfbf9311b4b3dc20f8244cde301ec2a /editors/openoffice-1.0
parentSync this port with the recent Mozilla commits. (diff)
Set $LANG to a useful value if it is not already set. This is a issue
many users have problems with. If US-ASCII is set, OpenOffice.Org cannot read any filenames with special chars and Umlauts !
Notes
Notes: svn path=/head/; revision=73733
Diffstat (limited to 'editors/openoffice-1.0')
-rw-r--r--editors/openoffice-1.0/Makefile36
-rw-r--r--editors/openoffice-1.0/files/openoffice-wrapper6
2 files changed, 39 insertions, 3 deletions
diff --git a/editors/openoffice-1.0/Makefile b/editors/openoffice-1.0/Makefile
index a3df30b81742..b18e237095a2 100644
--- a/editors/openoffice-1.0/Makefile
+++ b/editors/openoffice-1.0/Makefile
@@ -32,6 +32,7 @@ MOUNT?= /sbin/mount
ZIP?= ${PREFIX}/bin/zip
UNZIP?= ${PREFIX}/bin/unzip
TCSH?= /bin/tcsh
+PASTE?= /usr/bin/paste
.include <bsd.port.pre.mk>
@@ -71,6 +72,15 @@ CONFIGURE_ARGS+= --with-lang=${LANG_CONFIGURE_ARG},ENUS
.endif
.endif
+.if !defined (LANG) && !defined(USE_LANG)
+USE_LANG= en_US.ISO8859-15
+LANG_LIST= en_US.ISO8859-15 en_US.ISO8859-1 US-ASCII
+.else
+USE_LANG= ${LANG}
+.endif
+
+LANG_SORTED= `${ECHO} ${LANG_LIST} | ${TR} " " "\n" | ${PASTE} -d " " - -`
+
.if ${OSVERSION} < 500000
#
# OO build is broken with the system gcc on STABLE.
@@ -164,11 +174,29 @@ CONFIGURE_ARGS+= --enable-gcc3
pre-fetch:
@${ECHO}
+.if !defined(LANG)
@${ECHO} "REQUIREMENTS:"
-.if !defined(USE_GCC) || !defined(WITH_DEBUG)
@${ECHO}
- @${ECHO} "OPTIONS:"
+ @${ECHO} "OO requires that the ENV variable LANG"
+ @${ECHO} "is set to a proper value. Dependent on"
+ @${ECHO} "which language port you use, OO does"
+ @${ECHO} "automatically set LANG to a suitable"
+ @${ECHO} "value. You can change this with:"
+ @${ECHO}
+ @${ECHO} "USE_LANG=\"prefered language\""
+ @${ECHO}
+ @${ECHO} "and set a different language"
+ @${ECHO} "like:"
+ @${ECHO}
+ @${ECHO} "${LANG_SORTED}"
+ @${ECHO}
+ @${ECHO} "Your current setting is:"
+ @${ECHO}
+ @${ECHO} "USE_LANG=${USE_LANG}"
+ @${ECHO}
+ @${ECHO}
.endif
+ @${ECHO} "OPTIONS:"
.if !defined(USE_GCC)
@${ECHO}
@${ECHO} "You can compile OO with different"
@@ -232,8 +260,10 @@ pre-fetch:
@${ECHO} "kern.maxssiz=\"268435456\""
.endif
@${ECHO}
+.if ${OSVERSION} < 460002
@${ECHO} "REQUIRED SYSTEM PATCHES:"
@${ECHO}
+.endif
.if ${OSVERSION} < 500000
@${ECHO} "OO.org can crash if you enter a non existing path"
@${ECHO} "or URL in the location bar. To fix these crashes"
@@ -480,6 +510,8 @@ post-install:
@${ECHO_MSG} "===> Add wrapper scripts";
@${SED} -e 's#%%PREFIX%%#${PREFIX}#g' < ${FILESDIR}/openoffice-wrapper \
> ${WRKDIR}/openoffice
+ @${SED} -e 's#%%LANG%%#${USE_LANG}#g' < ${FILESDIR}/openoffice-wrapper \
+ > ${WRKDIR}/openoffice
@${INSTALL_SCRIPT} ${WRKDIR}/openoffice ${PREFIX}/bin/openoffice
@${LN} -fs ${PREFIX}/bin/openoffice ${PREFIX}/bin/openoffice-sagenda
@${LN} -fs ${PREFIX}/bin/openoffice ${PREFIX}/bin/openoffice-scalc
diff --git a/editors/openoffice-1.0/files/openoffice-wrapper b/editors/openoffice-1.0/files/openoffice-wrapper
index 28a571a83200..d5707b7ad633 100644
--- a/editors/openoffice-1.0/files/openoffice-wrapper
+++ b/editors/openoffice-1.0/files/openoffice-wrapper
@@ -1,10 +1,14 @@
#!/bin/sh
#
-# $FreeBSD: /tmp/pcvs/ports/editors/openoffice-1.0/files/Attic/openoffice-wrapper,v 1.2 2002-08-04 00:18:09 mbr Exp $
+# $FreeBSD: /tmp/pcvs/ports/editors/openoffice-1.0/files/Attic/openoffice-wrapper,v 1.3 2003-01-21 17:09:39 mbr Exp $
oopath=%%PREFIX%%/OpenOffice.org1.0/program/
program=`echo $0 | sed -e 's|.*-||'`
+if [ ! $LANG ]; then
+ export LANG=%%LANG%%
+fi
+
case $program in
$0)
exec $oopath/soffice "$@"