This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 123360 - NetBeans 6 doen't have entries in kubuntu's menu.
Summary: NetBeans 6 doen't have entries in kubuntu's menu.
Status: RESOLVED FIXED
Alias: None
Product: installer
Classification: Unclassified
Component: NBI (show other bugs)
Version: 6.x
Hardware: PC Linux
: P2 blocker (vote)
Assignee: dlipin
URL:
Keywords:
: 123503 125638 (view as bug list)
Depends on:
Blocks:
 
Reported: 2007-12-04 14:31 UTC by apux
Modified: 2008-01-21 07:39 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
install log (21.47 KB, text/plain)
2007-12-04 16:42 UTC, apux
Details
New log file (3.35 MB, text/plain)
2007-12-04 23:30 UTC, apux
Details

Note You need to log in before you can comment on or make changes to this bug.
Description apux 2007-12-04 14:31:51 UTC
I installed NB6 in kubuntu 7.04 as root, but it has no entries in the menu. I had installed NB6 RC2 as normal user and
it did.
¿Why the final version doesn't?
Comment 1 dlipin 2007-12-04 14:34:11 UTC
Try logout and login back. 
Is the shortcut for final 6.0 visible now?
Comment 2 apux 2007-12-04 16:08:49 UTC
No, it isn't.

I had to create an item manually. It's not really a problem, but it must work.

Also, kubuntu can't detect when NB6 finish to load, but it works with NB 5.5.

Comment 3 dlipin 2007-12-04 16:29:22 UTC
apux,

how did you install NB6 as root?
via login to root?
or via sudo?
or via sudo -?

please also attach the installation log, it is available at ~/.nbi/log (where ~ is the homedir of the root user)
Comment 4 apux 2007-12-04 16:42:44 UTC
Created attachment 53856 [details]
install log
Comment 5 apux 2007-12-04 16:49:08 UTC
I did with sudo just like I did with NB 5.5.
Comment 6 dlipin 2007-12-04 19:38:34 UTC
apux,

I`am very sorry to say that but the installation log seems to be from the wrong location.
It is from /home/azarel/.nbi/log and doesn`t contain any installation entries (it seems that it correspond to the case 
when you ran the installer, wait while the Welcome page was shown and exit it).

Are there any other log files available at /home/azarel/.nbi/log?
Are there any log files available at /.nbi/log ?

> I did with sudo just like I did with NB 5.5.
In 6.0 we have completely new installer and no garantee that everything that worked fine in 5.5 (at the installation) 
would work the same in 6.0. 
That is why I am asking for the exact command that you execute to run the installer :) What was it?

BTW, is the menu item for 5.5 available if you install NB5.5 using sudo ?
Comment 7 apux 2007-12-04 23:26:21 UTC
In both, NB 5.5 and NB 6, I downloaded the .h, chmod +x, and run ... sudo ./

> I`am very sorry to say that but the installation log seems to be from the wrong location.

Mmmm... yes, I have many files from different dates because I installed the 5.5, 5.5.1, 6 Beta 2, 6 RC1, 6 RC2, and 6.
The attached was for a test as normal user before I did as root. The correct one is in /root/.nbi/log ¿isn't it?.

I'll upload it.
Comment 8 apux 2007-12-04 23:30:05 UTC
Created attachment 53883 [details]
New log file
Comment 9 dlipin 2007-12-05 08:51:47 UTC
apux,

thanks a lot for the log file! it shed some light to the problem.

From the log I see the following:

executing command: id -ru, in directory: .
    [stdout]: 0
    [return]: 0
... command execution finished
executing command: id -u, in directory: .
    [stdout]: 0
    [return]: 0
... command execution finished
... current user is an ordinary user -- creating the shortcut for the current user only

By design, we get the real id (id -ru) and effective id (id -u) of the user who performes the installation.
Then we compare those ids with zero (stdout.equals("0")) and if both are zero then the user is root. I have an 
assumtion that stdout can contain some new-line separators (in other words, it is "0\r\n") and that is why the check 
failed.
I need to check them more thoroughly and let you know the results soon.
Comment 10 dlipin 2007-12-05 11:33:19 UTC
Well...

I`ve debugged the code and, in fact, stdout contains line separator at the end (equals to "0\n" on linux) that is why 
the check fails.

More over, I see that the code is really buggy there:
ExecutionResults resRealID = SystemUtils.executeCommand("id", "-ru");
ExecutionResults resEffID = SystemUtils.executeCommand("id", "-u");
String realID = resRealID.getStdOut();
String effID = resRealID.getStdOut();
if(realID!=null && effID!=null) {
    result = (realID.equals("0") && effID.equals("0"));
}

realID and effID are taken from the same stdout and this code is from the very beginning.

The forst thing is that "id -ru" and "id -u" doesn`t work on Solaris at all (there are no -ru and -u switches in id 
command on solaris).

I wonder how our QE team hasn`t noticed all that facts that in their testing cycles.
Increasing the priority to P2.
Comment 11 dlipin 2007-12-05 20:42:05 UTC
*** Issue 123503 has been marked as a duplicate of this issue. ***
Comment 12 dlipin 2007-12-06 17:34:15 UTC
I hope that it is fixed now.

http://deadlock.netbeans.org/fisheye/browse/netbeans/nbi/engine/native/jnilib/.unix/src/
jni_UnixNativeUtils.c?r1=1.7&r2=1.8
http://deadlock.netbeans.org/fisheye/browse/netbeans/nbi/engine/native/jnilib/.unix/src/
jni_UnixNativeUtils.h?r1=1.4&r2=1.5
http://deadlock.netbeans.org/fisheye/browse/netbeans/nbi/engine/src/org/netbeans/installer/utils/system/
UnixNativeUtils.java?r1=1.33&r2=1.34


nbi/engine/native/jnilib/macosx/dist/macosx.dylib:1.7->1.8
nbi/engine/native/jnilib/linux/dist/linux-amd64.so:1.3->1.4
nbi/engine/native/jnilib/linux/dist/linux.so:1.6->1.7
nbi/engine/native/jnilib/solaris-sparc/dist/solaris-sparc.so:1.5->1.6
nbi/engine/native/jnilib/solaris-sparc/dist/solaris-sparcv9.so:1.2->1.3
nbi/engine/native/jnilib/solaris-x86/dist/solaris-amd64.so:1.2->1.3
nbi/engine/native/jnilib/solaris-x86/dist/solaris-x86.so:1.5->1.6
Comment 13 dlipin 2008-01-21 07:38:27 UTC
*** Issue 125638 has been marked as a duplicate of this issue. ***
Comment 14 dlipin 2008-01-21 07:39:35 UTC
*** Issue 125638 has been marked as a duplicate of this issue. ***