Bug: Site Maps Missing on Beta 20020414
Installation of Beta 20020414 has missing site maps. The header of the table shows, but there is no body.
Apache server keeps returning this line for all searches:
[Thu Apr 25 16:40:22 2002] [error] [client 216.39.170.247] [Thu Apr 25 16:40:22 2002] search: Use of uninitialized value in split at ../lib/TWiki/Search.pm line 276.
The line in search.pm is:
@topicList = split( /\n/, $tempVal );
Uncommenting _traceExec yielded this:
25 Apr 2002 - 16:46 Search exec: chdir to h:/apache/twiki/data/Main ->
25 Apr 2002 - 16:46 Search exec: g:/cygwin/bin/fgrep -i -l "Thoeny" *.txt ->
OOPS - fgrep is a symbolic link to grep. Symoblic links are not understood by Windows! So is egrep!
Strangely, prior releases of TWiki i've been using did do searches before!
Test case
Install beta 20020414 - see missing site map on main page.
Environment
| TWiki version: |
beta20020414 |
| TWiki plugins: |
n/a |
| Server OS: |
Windows 2000 Professional SP 1 + hotfixes |
| Web server: |
Apache-1.3.24 |
| Perl version: |
ActiveState Pearl |
| Client OS: |
Windows 2000 Professional SP 1 + hotfixes |
| Web Browser: |
IE 6.0 |
--
DavidLeBlanc - 25 Apr 2002
Follow up
Fix record
Change twiki.cfg to use available .exe files instead of symbolic links to them:
# Unix egrep command :
$egrepCmd = "g:/cygwin/bin/grep";
# Unix fgrep command :
$fgrepCmd = "g:/cygwin/bin/grep";
Perhaps a correction to the windows install cookbook might be in order for cygwin utils on native command processor?
I'm afraid you have a broken installation of Cygwin, since it should never use symbolic links for commands that can be called from Windows (i.e. most commands) - here's the output of my Cygwin 1.3.10 installation, showing that the .exes are not symbolic links:
$ ls -l /bin/{fgrep,grep}.exe
-rwxr-xr-x 1 Administ None 85504 Feb 22 02:19 /bin/fgrep.exe
-rwxr-xr-x 1 Administ None 85504 Feb 22 02:19 /bin/grep.exe
The second column is the link count, so it's clear they are not hard links either.
Please confirm how you found out that symbolic links are used, as I have never seen this on Cygwin. You can just turn the files into copies by removing the symbolic links and copying the 'real' .exe to have the correct alternative names.
Which release of Cygwin are you using? You can type
uname -r to find out.
I have the alpha release (i.e. similar code to the beta) working OK under Cygwin.
--
RichardDonkin - 26 Apr 2002
cygwin reports:
$ uname -r
1.3.10(0.51/3/2)
Administrator@LION /bin
$ ls -l {egrep,fgprep}.exe
ls: egrep.exe: No such file or directory
ls: fgprep.exe: No such file or directory
Administrator@LION /bin
$ ls -l {egrep,fgrep}
lrwxrwxrwx 1 Administ None 15 Apr 11 14:56 egrep -> grep
lrwxrwxrwx 1 Administ None 15 Apr 11 14:56 fgrep -> grep
I don't believe that I have a broken installation of cygwin - these symbolic links are the direct result of a standard installation using cygwin's setup tool, and the installation was last updated on 11 April, 2002. There are 20 files that are symlinks in /cygwin/bin.
--
DavidLeBlanc - 26 Apr 2002
Interesting - I originally installed an older version of Cygwin then upgraded to 1.3.10, yet my symlink settings are different. Presumably the extra symlinks were added in some release after my initial install, but the Cygwin installer doesn't bother resetting them from files to symlinks when upgrading.
IMO Cygwin itself is broken in this respect - using Cygwin tools directly from Windows programs is important, so the tools themselves should not be symlinked. Once a tool is running, it can make use of symlinks for non-program directories etc. Even in my setup, there are some other symlinks in
/bin.
The man page says that
fgrep is the same as
grep -F, but the $fgrepCmd setting you give is fine for topic name searches.
I've updated the
WindowsInstallCookbook. Thanks for reporting and fixing this!
--
RichardDonkin - 27 Apr 2002