rpms/xulrunner/devel xulrunner.sh.in, NONE, 1.1 xulrunner.spec, 1.119, 1.120
Martin Stransky (stransky)
fedora-extras-commits at redhat.com
Fri Apr 18 09:35:41 UTC 2008
Author: stransky
Update of /cvs/pkgs/rpms/xulrunner/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv11806
Modified Files:
xulrunner.spec
Added Files:
xulrunner.sh.in
Log Message:
* Fri Apr 18 2008 Martin Stransky <stransky at redhat.com> 1.9-0.62
- Fixed multilib issues, added starting script instead of a symlink
to binary (#436393)
--- NEW FILE xulrunner.sh.in ---
#!/bin/sh
#
# The contents of this file are subject to the Netscape Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/NPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s):
#
##
## Usage:
##
## $ xulrunner
##
## This script is meant to run a xulrunner program from the xulrunner
## rpm installation.
##
cmdname=`basename $0`
##
## Variables
##
XUL_ARCH=$(uname -m)
case $XUL_ARCH in
x86_64 | ia64 | s390 )
XUL_LIB_DIR="/usr/lib64"
SECONDARY_LIB_DIR="/usr/lib"
;;
* )
XUL_LIB_DIR="/usr/lib"
SECONDARY_LIB_DIR="/usr/lib64"
;;
esac
if [ ! -x $XUL_LIB_DIR/xulrunner-XULRUNNER_VERSION/xulrunner ]; then
if [ ! -x $SECONDARY_LIB_DIR/xulrunner-XULRUNNER_VERSION/xulrunner ]; then
echo "Error: $XUL_LIB_DIR/xulrunner-XULRUNNER_VERSION/xulrunner not found"
if [ -d $SECONDARY_LIB_DIR ]; then
echo " $SECONDARY_LIB_DIR/xulrunner-XULRUNNER_VERSION/xulrunner not found"
fi
exit 1
fi
XUL_LIB_DIR="$SECONDARY_LIB_DIR"
fi
XUL_DIST_BIN="$XUL_LIB_DIR/xulrunner-XULRUNNER_VERSION"
XUL_PROGRAM="$XUL_DIST_BIN/xulrunner"
exec $XUL_PROGRAM "$@"
Index: xulrunner.spec
===================================================================
RCS file: /cvs/pkgs/rpms/xulrunner/devel/xulrunner.spec,v
retrieving revision 1.119
retrieving revision 1.120
diff -u -r1.119 -r1.120
--- xulrunner.spec 17 Apr 2008 02:23:03 -0000 1.119
+++ xulrunner.spec 18 Apr 2008 09:35:03 -0000 1.120
@@ -14,7 +14,7 @@
Summary: XUL Runtime for Gecko Applications
Name: xulrunner
Version: 1.9
-Release: 0.61%{?nightly}%{?dist}
+Release: 0.62%{?nightly}%{?dist}
URL: http://www.mozilla.org/projects/xulrunner/
License: MPLv1.1 or GPLv2+ or LGPLv2+
Group: Applications/Internet
@@ -26,6 +26,7 @@
Source0: %{tarball}
Source10: %{name}-mozconfig
Source12: %{name}-redhat-default-prefs.js
+Source21: %{name}.sh.in
Source23: %{name}.1
# build patches
@@ -165,6 +166,12 @@
%{__install} -p -D -m 644 rh-default-prefs $RPM_BUILD_ROOT/${MOZ_APP_DIR}/defaults/pref/all-redhat.js
%{__rm} rh-default-prefs
+# Start script install
+%{__rm} -rf $RPM_BUILD_ROOT%{_bindir}/%{name}
+%{__cat} %{SOURCE21} | %{__sed} -e 's,XULRUNNER_VERSION,%{version_internal},g' > \
+ $RPM_BUILD_ROOT%{_bindir}/%{name}
+%{__chmod} 755 $RPM_BUILD_ROOT%{_bindir}/%{name}
+
%{__install} -p -D -m 644 %{SOURCE23} $RPM_BUILD_ROOT%{_mandir}/man1/%{name}.1
%{__rm} -f $RPM_BUILD_ROOT${MOZ_APP_DIR}/%{name}-config
@@ -189,6 +196,42 @@
%{__cp} -rL dist/include/* \
$RPM_BUILD_ROOT/%{_includedir}/${INTERNAL_APP_SDK_NAME}
+# Fix multilib devel conflicts...
+%ifarch x86_64 ia64 s390x ppc64
+%define mozbits 64
+%else
+%define mozbits 32
+%endif
+
+function install_file() {
+genheader=$*
+mv ${genheader}.h ${genheader}%{mozbits}.h
+cat > ${genheader}.h << EOF
+// This file exists to fix multilib conflicts
+#if defined(__x86_64__) || defined(__ia64__) || defined(__s390x__) || defined(__ppc64__)
+#include "${genheader}64.h"
+#else
+#include "${genheader}32.h"
+#endif
+EOF
+}
+
+pushd $RPM_BUILD_ROOT/%{_includedir}/${INTERNAL_APP_SDK_NAME}
+install_file "mozilla-config"
+popd
+
+pushd $RPM_BUILD_ROOT/%{_includedir}/${INTERNAL_APP_SDK_NAME}/unstable
+install_file "mozilla-config"
+popd
+
+pushd $RPM_BUILD_ROOT/%{_includedir}/${INTERNAL_APP_SDK_NAME}/js
+install_file "jsautocfg"
+popd
+
+pushd $RPM_BUILD_ROOT/%{_includedir}/${INTERNAL_APP_SDK_NAME}/unstable
+install_file "jsautocfg"
+popd
+
%{__install} -p -c -m 755 dist/bin/xpcshell \
dist/bin/xpidl \
dist/bin/xpt_dump \
@@ -347,6 +390,10 @@
#---------------------------------------------------------------------
%changelog
+* Fri Apr 18 2008 Martin Stransky <stransky at redhat.com> 1.9-0.62
+- Fixed multilib issues, added starting script instead of a symlink
+ to binary (#436393)
+
* Wed Apr 16 2008 Christopher Aillon <caillon at redhat.com> 1.9-0.61
- Update to latest trunk (2008-04-16)
More information about the fedora-extras-commits
mailing list