Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.

Bug 106563

Summary: OpenOffice.org start-up menus in wrong place
Product: [Retired] Red Hat Raw Hide Reporter: Tim Waugh <twaugh>
Component: openoffice.orgAssignee: Dan Williams <dcbw>
Status: CLOSED RAWHIDE QA Contact: David Lawrence <dkl>
Severity: medium Docs Contact:
Priority: medium    
Version: 1.0CC: browning2man, dyoung, jbeach, mablank, mmuller, petersen, rdieter, zphreak217
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2003-10-31 15:23:42 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 100643    

Description Tim Waugh 2003-10-08 13:30:24 UTC
Description of problem:
The menu items for starting OpenOffice.org components are in Red
Hat->Office->More Office Applications, instead of Red Hat->Office.

Version-Release number of selected component (if applicable):
openoffice.org-1.1.0-1

Comment 1 Dan Williams 2003-10-10 21:27:13 UTC
Actual bug was that redhat-menus was not in the BuildRequires section of the
specfile, so the build farm here at Red Hat didn't install it, and therefore
there were no .desktop files to package up in the RPM.  Will be fixed in 1.1.0-3.

Comment 2 Dan Williams 2003-10-10 21:27:42 UTC
*** Bug 106740 has been marked as a duplicate of this bug. ***

Comment 3 Bill Nottingham 2003-10-14 05:08:05 UTC
*** Bug 106967 has been marked as a duplicate of this bug. ***

Comment 4 Dan Williams 2003-10-14 13:07:22 UTC
*** Bug 106989 has been marked as a duplicate of this bug. ***

Comment 5 Dan Williams 2003-10-15 13:15:11 UTC
*** Bug 107126 has been marked as a duplicate of this bug. ***

Comment 6 Elton Woo 2003-10-17 17:36:13 UTC
To get the menu items in Gnome one has to either run /usr/lib/openoffice/setup
or launch oowriter from a console. However, though this adds the entries to the
Gnome desktop menu, *but* they do not get added to the KDE menus.


Comment 7 Dan Williams 2003-10-20 13:41:52 UTC
*** Bug 107520 has been marked as a duplicate of this bug. ***

Comment 8 Dan Williams 2003-10-20 13:42:01 UTC
*** Bug 107509 has been marked as a duplicate of this bug. ***

Comment 9 Rex Dieter 2003-10-22 16:25:48 UTC
I propose openoffice install global applnk/mimelnk/icons, and disable local
installations of these files.

Add/modify to specfile to inclue:
################################################
## APPLNK
# patch kde's applnk files
pushd %{buildroot}%{_libdir}/openoffice/share/kde/net
perl -pi -e 's@.xpm@@g' *.desktop
popd
# desktop-file case
%if "%{?desktop_file}" == "1"
mkdir -p %{buildroot}%{_datadir}/applications
for i in openoffice-printeradmin openoffice-setup \
         redhat-drawing redhat-math redhat-presentations redhat-word-processor \
         redhat-spreadsheet; do
  ln -sf %{_datadir}/desktop-menu-patches/$i.desktop
%{buildroot}%{_datadir}/applications/$i.desktop
done
rm -rf %{buildroot}%{_datadir}/applnk
rm -rf %{buildroot}%{_datadir}/gnome
%else
# non-desktop-file case
mkdir -p "%{buildroot}/%{_sysconfdir}/X11/applnk/Office/OpenOffice.org %{version}/"
cp -alf %{buildroot}%{_libdir}/openoffice/share/kde/net/*.desktop \
        "%{buildroot}/%{_sysconfdir}/X11/applnk/Office/OpenOffice.org %{version}/"
%endif

## ICONS
# Extract 48x48 PNGs for use by GNOME and Nautilus
# (Nautilus needs pngs under %{_datadir}/pixmaps)
mkdir -p %{buildroot}%{_datadir}/pixmaps
tar --directory %{buildroot}%{_datadir}/pixmaps/ -xjvf %{SOURCE4}
# KDE
mkdir -p %{buildroot}%{_datadir}/icons
cp -alf %{buildroot}%{_libdir}/openoffice/share/kde/net/share/icons/* \
        %{buildroot}%{_datadir}/icons/

## MIME-types
# KDE
mkdir -p %{buildroot}%{_datadir}/mimelnk
# copy to global location
cp -af  %{buildroot}%{_libdir}/openoffice/share/kde/net/share/mimelnk/* \
        %{buildroot}%{_datadir}/mimelnk/

## Fix instdb.ins, to *not* install local copies of these
for entry in Kdeapplnk Kdemimetext Kdeicons Gnome_Apps Gnome_Icons Gnome2_Apps; do
perl -pi -e "/^File gid_File_Extra_$entry/ .. /^End/ and (\
  s|^\tSize\s+\= .*|\tSize\t\t = 0;\r| or \
  s|^\tArchiveFiles\s+\= .*|\tArchiveFiles\t = 0;\r| or \
  s|^\tArchiveSize\s+\= .*|\tArchiveSize\t = 0;\r| or \
  s|^\tContains\s+\= .*|\tContains\t = ();\r| or \
  s|\t\t\t\t\t\".*|\r|g)" \
  %{buildroot}%{_libdir}/openoffice/program/instdb.ins
done


###################################3
Then add to %files:
# applnk files
%if "%{?desktop_file}" == "1"
%{_datadir}/applications/*
%else
%{_sysconfdir}/X11/applnk/Office
%endif
# mimelnk files
%{_datadir}/mimelnk/*/*
# icon files
%{_datadir}/pixmaps/*
%{_datadir}/icons/*/*/*



Comment 10 Dan Williams 2003-10-31 15:23:42 UTC
Rex Dieter, your patch has largely been incorporated into 1.1.0-4. 
Thanks for the scripts.  This bug should be fixed in 1.1.0-4, though
people will need to "rm -f
~/.gnome2/vfolders/applications/ooo645*.desktop" to remove the
duplicate entries.

Dan