Uninstalling a program from Cygwin in Windows XP

2007-09-14 Thread D
I have installed a program called Fontforge (An
outline font editor) into the Cygwin environment in
order to create and manipulate fonts for Windows XP. I
would like to update the editor, but when I try the
uninstall commands cygwin does not uninstall the
program can some provide help as to how to uninstall
Fontforge.  

This is the command that was used to install the
program in Cygwin:

$ bunzip2 fontforge_cygwin-*.tar.bz2
$ tar xf fontforge_cygwin-*.tar
$ cd fontforge
$ ./doinstall

Now when I try to uninstall the program I was supposed
to use this command:
$ su
password:
$ rm -rf /usr/local/bin/{fontforge,sfddiff} \
/usr/local/lib/{libgdraw,libgunicode,libuninameslist}*
\
/usr/local/lib/pkgconfig/fontforge.pc \
/usr/local/man/man1/{fontforge,sfddiff}.1 \
/usr/local/share/doc/fontforge \
/usr/local/share/locale/*/LC_MESSAGES/FontForge.mo

but it does not uninstall the program.  Any
suggestions as to what I need to do to uninstall this
program? 


  

Shape Yahoo! in your own image.  Join our Network Research Panel today!   
http://surveylink.yahoo.com/gmrs/yahoo_panel_invite.asp?a=7 



--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: Uninstalling a program from Cygwin in Windows XP

2007-09-14 Thread D

--- Thorsten Kampe  wrote:


> It's not a part of the official Cygwin distribution. So how can we 
> know how to uninstall the program?

> 
> A sufficient problem description would be fine. What happens when you 
> issue this command and why does it not uninstall the program?
> 
> On the other hand it really doesn't matter: the command just removes 
> all the fontforge files. Why don't you do it by hand? It would take 
> about two minutes of your precious time.
> 
> 
> Thorsten

When I tried to ask the developer of the program how to remove the program he 
indicated
that the problem was not with fontforge, but with Cygwin, so that is why I came 
to this
user group to find out how to fix the problem.  If on the other hand all I have 
to do is
just manually remove the program, I did not know that was possible because I 
was under
the assumption that since I used cygwin to install the program I would need 
(cygwin) to
uninstall the program.  Do I just go to the directory that it is located in and 
delete
the file and that is it.  Or is there more that I would need to do?




   

Pinpoint customers who are looking for what you sell. 
http://searchmarketing.yahoo.com/

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: Uninstalling a program from Cygwin in Windows XP

2007-09-14 Thread D
So basically take the command that is at the bottom and use that instead 
because I am on
windows xp?




--- Dave Korn wrote:

> On 14 September 2007 15:14, Dave Korn wrote:
> 
> > On 14 September 2007 13:56, D wrote:
> > 
> >> When I tried to ask the developer of the program how to remove the program
> >> he indicated that the problem was not with fontforge, but with Cygwin,
> > 
> >   He is wrong.
> > 
> >   The command he provided is a simple delete of all the files that the
> > installer should have installed.  If it doesn't work, it's not because
> > Cygwin refused to delete the files for no reason, it's because he's
> > specified the wrong paths in that command.   
> 
>   Hey, hang on a minute... it *is* because Cygwin's refusing to delete files
> for no reason!
> 
> /tmp/ff/fontforge $ ls -la /usr/local/bin/fontforge.exe
> -rwxr-xr-x 1 dk Domain Users 13700198 Sep 14 15:20
> /usr/local/bin/fontforge.exe
> /tmp/ff/fontforge $ rm -rf /usr/local/bin/{fontforge,sfddiff}
> /tmp/ff/fontforge $ ls -la /usr/local/bin/fontforge.exe
> -rwxr-xr-x 1 dk Domain Users 13700198 Sep 14 15:20
> /usr/local/bin/fontforge.exe
> /tmp/ff/fontforge $ echo rm -rf /usr/local/bin/{fontforge,sfddiff}
> rm -rf /usr/local/bin/fontforge /usr/local/bin/sfddiff
> /tmp/ff/fontforge $ rm -rf /usr/local/bin/fontforge /usr/local/bin/sfddiff
> /tmp/ff/fontforge $ ls -la /usr/local/bin/fontforge.exe
> -rwxr-xr-x 1 dk Domain Users 13700198 Sep 14 15:20
> /usr/local/bin/fontforge.exe
> /tmp/ff/fontforge $ rm -rf /usr/local/bin/fontforge.exe
> /tmp/ff/fontforge $ ls -la /usr/local/bin/fontforge.exe
> ls: cannot access /usr/local/bin/fontforge.exe: No such file or directory
> /tmp/ff/fontforge $
> 
> >   Basically, you need to find the files listed in the 'rm' command:
> > 
> >> $ rm -rf /usr/local/bin/{fontforge,sfddiff} \
> >> /usr/local/lib/{libgdraw,libgunicode,libuninameslist}* \
> >> /usr/local/lib/pkgconfig/fontforge.pc \
> >> /usr/local/man/man1/{fontforge,sfddiff}.1 \
> >> /usr/local/share/doc/fontforge \
> >> /usr/local/share/locale/*/LC_MESSAGES/FontForge.mo
> > 
> > and delete them.  That's all the command does.
> 
>   Hmm.  So, after the rm command, we still have:
> 
> /usr/local/bin:
> +cyguninameslist-0.dll
> +cyguninameslist-fr-0.dll
> +fontforge.exe
> +fontimage
> +pfaedit.exe
> 
> /usr/local/man/man1:
> +fontimage.1
> 
> /usr/local/share:
> +fontforge
> 
> +/usr/local/share/fontforge:
> +Adobe-CNS1-4.cidmap
> +Adobe-GB1-4.cidmap
> +Adobe-Identity-0.cidmap
> +Adobe-Japan1-6.cidmap
> +Adobe-Japan2-0.cidmap
> +Adobe-Korea1-2.cidmap
> 
>   So, there seems to be a failure of 'exe magic', and part of it is because he
> hasn't allowed for the cygwin library naming scheme (and the fact that dlls go
> into bin, not lib).  The working version of the command should therefore be:
> 
> $ rm -rf /usr/local/bin/{fontforge.exe,fontimage,sfddiff,pfaedit.exe} \
>  /usr/local/bin/cyguninameslist* \
>  /usr/local/lib/{libgdraw,libgunicode,libuninameslist}* \
>  /usr/local/lib/pkgconfig/fontforge.pc \
>  /usr/local/man/man1/{fontforge,fontimage,sfddiff}.1 \
>  /usr/local/share/doc/fontforge \
>  /usr/local/share/locale/*/LC_MESSAGES/FontForge.mo \
>  /usr/local/share/fontforge
> 
> 
>   You could pass it on to the fontforge guy if you liked.
> 
> cheers,
>   DaveK
> -- 
> Can't think of a witty .sigline today
> 
> 
> --
> Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
> Problem reports:   http://cygwin.com/problems.html
> Documentation: http://cygwin.com/docs.html
> FAQ:   http://cygwin.com/faq/
> 
> 



  

Catch up on fall's hot new shows on Yahoo! TV. Watch previews, get listings, 
and more!
http://tv.yahoo.com/collections/3658 

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Updating Cygwin and packages

2007-09-30 Thread D
When I downloaded and installed cygwin I had installed various packages.  I was 
wondering
how do I go about updating those packages and cygwin for that matter if 
possible.


   

Be a better Heartthrob. Get better relationship answers from someone who knows. 
Yahoo! Answers - Check it out. 
http://answers.yahoo.com/dir/?link=list&sid=396545433

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: YouCompleteMe build fails: problem with LONG_BIT in pyport.h or ld missing python lib

2013-12-19 Thread D
Whitedwarf  tura-home.de> writes:

> 
> Hi all,
> 
> I'm trying to install (i.e., mainly, build) the vim plugin YouCompleteMe
> in cygwin64 on a x86_64 machine and got stuck.
> 
> The first error message was
> 
> [ 11%] Building CXX object
> BoostParts/CMakeFiles/BoostParts.dir/libs/python/src/converter/
arg_to_python_base.cpp.o
> In file included from /usr/include/python2.7/Python.h:58:0,
>  from
> /home/matu_gr/.vim/bundle/YouCompleteMe/cpp/BoostParts/boost/python/
detail/wrap_python.hpp:142,
>  from
> /home/matu_gr/.vim/bundle/YouCompleteMe/cpp/BoostParts/boost/python/
detail/prefix.hpp:13,
>  from
> /home/matu_gr/.vim/bundle/YouCompleteMe/cpp/BoostParts/boost/python/
handle.hpp:8,
>  from
> /home/matu_gr/.vim/bundle/YouCompleteMe/cpp/BoostParts/boost/python/
converter/arg_to_python_base.hpp:7,
>  from
> /home/matu_gr/.vim/bundle/YouCompleteMe/cpp/BoostParts/libs/python/src/
converter/arg_to_python_base.cpp:6:
> /usr/include/python2.7/pyport.h:886:2: Fehler: #error "LONG_BIT
> definition appears wrong for platform (bad gcc/glibc config?)."
>  #error "LONG_BIT definition appears wrong for platform (bad gcc/glibc
> config?)."
>   ^
> BoostParts/CMakeFiles/BoostParts.dir/build.make:402: recipe for target
> 'BoostParts/CMakeFiles/BoostParts.dir/libs/python/src/converter/
arg_to_python_base.cpp.o'
> failed
> make[3]: ***
> [BoostParts/CMakeFiles/BoostParts.dir/libs/python/src/converter/
arg_to_python_base.cpp.o]
> Error 1
> CMakeFiles/Makefile2:78: recipe for target
> 'BoostParts/CMakeFiles/BoostParts.dir/all' failed
> make[2]: *** [BoostParts/CMakeFiles/BoostParts.dir/all] Error 2
> CMakeFiles/Makefile2:212: recipe for target
> 'ycm/CMakeFiles/ycm_support_libs.dir/rule' failed
> make[1]: *** [ycm/CMakeFiles/ycm_support_libs.dir/rule] Error 2
> Makefile:148: recipe for target 'ycm_support_libs' failed
> make: *** [ycm_support_libs] Error 2
> 
> I've tried to work around with (as mentioned in
> https://github.com/Valloric/YouCompleteMe/issues/66 )
> 
> -DPYTHON_INCLUDE_DIR=/usr/include/python2.7
> -DPYTHON_LIBRARY=/usr/lib/libpython2.7.dylib
> 
> but this did not help. (CMake configuration reports the same libs if not
> provided explicitly anyway.)
> 
> Then I've tried to reset the compilers CMake uses: using
> -DCMAKE_C_COMPILER and -DCMAKE_CXX_COMPILER, I've set the compilers
> first to /usr/bin/x86_64-pc-cygwin-gcc and
> /usr/bin/x86_64-pc-cygwin-g++, respectively; then to
> /usr/bin/i686-pc-cygwin-gcc and /usr/bin/i686-pc-cygwin-g++. But now I 
get:
> 
> Linking CXX shared library ycm_core.pyd
> /usr/lib/gcc/i686-pc-cygwin/4.7.3/../../../../i686-pc-cygwin/bin/ld:
> cannot find -lpython2.7
> collect2: Fehler: ld gab 1 als Ende-Status zurück
> ycm/CMakeFiles/ycm_core.dir/build.make:390: recipe for target
> 'ycm/ycm_core.pyd' failed
> make[3]: *** [ycm/ycm_core.pyd] Error 1
> CMakeFiles/Makefile2:168: recipe for target
> 'ycm/CMakeFiles/ycm_core.dir/all' failed
> make[2]: *** [ycm/CMakeFiles/ycm_core.dir/all] Error 2
> CMakeFiles/Makefile2:212: recipe for target
> 'ycm/CMakeFiles/ycm_support_libs.dir/rule' failed
> make[1]: *** [ycm/CMakeFiles/ycm_support_libs.dir/rule] Error 2
> Makefile:148: recipe for target 'ycm_support_libs' failed
> make: *** [ycm_support_libs] Error 2
> 
> Do you have any ideas or experience on how to fix this?
> 
> Best regards,
> 
> whitedwarf
> 
> System/versions: win7-64, cygwin64 with cygwin-gcc installed in 32- and
> 64-bit versions, https://github.com/Valloric/YouCompleteMe
> 
> 

I've been having the same problem as you, though YCM compiles fine under 32-
bit Cygwin. I don't think that using the i686 compilers is the way to go 
because, as said at the top of this page (https://github.com/Valloric/
YouCompleteMe/wiki/Windows-Installation-Guide):

"Before starting this installation procedure, it's critically important 
that you understand that the architecture (x86 vs x86-64) that you build 
ycm_core.pyd for has to match the architecture of the python27.dll on your 
system and the architecture of the Vim binary you will be running. All 
three need to match, otherwise things won't work."

I have also tried downloading older versions of YCM, up to August 2013, 
because that's when the author of the YCM installation for Cygwin guide 
(see link above) wrote his guide. Still the same LONG_INT error.

I hope a solution for this emerges.


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: microprobing ........... a grrrrrrreat technique !

2003-07-05 Thread W. D.
At 12:26 7/5/2003, mount me, wrote:
>Hello Experts,
>What is basically needed to do microprobing in
>a controller/processor board ?? How and where to
>start with my analysis for solving some
>of the hardware problems in my h/w ?? 
>
>karthik bala guru
>[EMAIL PROTECTED]

Try here:
mailto:[EMAIL PROTECTED]

Start Here to Find It Fast!™ -> http://www.US-Webmasters.com/best-start-page/


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



`sig_send: wait for sig_complete...' instead of core dump

2003-02-13 Thread D. Tweed
Hi, I'm trying to figure out how to fix the setting up of creating core
dumps and wonder if anyone can give me any pointers.

I'm working on my fresh installation of Cygwin on a fresh Windows XP
machine (cygcheck -s attatched). AFAICS I've followed all the instructions
on the web by setting CYGWIN to
"error_start=c:\cygwin\bin\dumper.exe". (If I unset that I get the
stackdump as expected.)

However even the uncontroversial program

---
#include 
int
main(int argc,char* argv[])
{
  abort();
  return 0;
}
---

when run does:
* it looks like a window pops up and vanishes fast enough that I can just
register its vague size (about the natural size of a cygwin bash shell) --
it's so quick I can't even see what colour it is.

* cpu usage hits 100%  as the abort starts and the terminal prints out
---
  4 [main] a 424 sig_send: wait for sig_complete event failed, signal
6, rc 258
, Win32 error 0
60617142 [main] a 424 sig_send: wait for sig_complete event failed, signal
-2, rc 2
58, Win32 error 0
121254342 [main] a 424 sig_send: wait for sig_complete event failed,
signal -2, rc 
258, Win32 error 0
181871550 [main] a 424 sig_send: wait for sig_complete event failed,
signal -2, rc 
258, Win32 error 0
242478672 [main] a 424 sig_send: wait for sig_complete event failed,
signal -2, rc 
258, Win32 error 0
---
reproducibly every time (except for first and fourth column details which
vary).

Can anybody give me a clue as to how to solve this; I'm not even sure if
it's indicative of misinstallation by me, a problem with cygwin on the
version of Windows XP I've got or a deeper problem in cygwin somewhere.

(FWIW, searching the web archives it appears that this behaviour crops up
every year or so in some circumstance (possibly in association with
self-compiled cygwin stuff, which isn't so in my case), but I can't find
any messages detailling how the problem was solved. The latest example I
could find was

http://sources.redhat.com/ml/cygwin/2003-01/msg00093.html
in reply to
http://sources.redhat.com/ml/cygwin/2003-01/msg00086.html
)

Many thanks for any enlightenment anyone can offer,

___cheers,_dave_
www.cs.bris.ac.uk/~tweed/  |  `It's no good going home to practise
email:[EMAIL PROTECTED]  |   a Special Outdoor Song which Has To Be
work tel:(0117) 954-5250   |   Sung In The Snow' -- Winnie the Pooh






Cygwin Win95/NT Configuration Diagnostics


Current System Time: Thu Feb 13 13:49:20 2003





Windows XP Home Edition Ver 5.1 Build 2600 Service Pack 1





Path:   C:\cygwin\bin


C:\WINDOWS\system32


C:\WINDOWS


C:\WINDOWS\System32\Wbem


C:\Program Files\ATI Technologies\ATI Control Panel





SysDir: C:\WINDOWS\System32


WinDir: C:\WINDOWS





CYGWIN = `error_start=c:\cygwin\bin\dumper.exe'


HOME = `C:/'


PWD = `/tmp'





Use `-r' to scan registry





a:  fd   N/A    N/A


c:  hd  NTFS   19069Mb  31% CP CS UN PA FC 65_02_31


d:  cd   N/AN/A





C:\cygwin  /  system  binmode


C:\cygwin/bin  /usr/bin   system  binmode


C:\cygwin/lib  /usr/lib   system  binmode


.  /cygdrive  system  binmode,cygdrive





Found: C:\cygwin\bin\awk.exe


Found: C:\cygwin\bin\bash.exe


Found: C:\cygwin\bin\cat.exe


Found: C:\cygwin\bin\cp.exe


Found: C:\cygwin\bin\cpp.exe


Found: C:\cygwin\bin\find.exe


Found: C:\cygwin\bin\gcc.exe


Found: C:\cygwin\bin\gdb.exe


Found: C:\cygwin\bin\grep.exe


Found: C:\cygwin\bin\ld.exe


Found: C:\cygwin\bin\ls.exe


Found: C:\cygwin\bin\make.exe


Found: C:\cygwin\bin\mv.exe


Found: C:\cygwin\bin\rm.exe


Found: C:\cygwin\bin\sed.exe


Found: C:\cygwin\bin\sh.exe


Found: C:\cygwin\bin\tar.exe





   58k 2002/05/07 C:\cygwin\bin\cygbz2-1.dll


  847k 2003/01/09 C:\cygwin\bin\cygcrypto-0.9.7.dll


  644k 2002/12/08 C:\cygwin\bin\cygcrypto.dll


  380k 2002/07/24 C:\cygwin\bin\cygdb-3.1.dll


  487k 2002/07/24 C:\cygwin\bin\cygdb_cxx-3.1.dll


   45k 2001/04/25 C:\cygwin\bin\cygform5.dll


   35k 2002/01/09 C:\cygwin\bin\cygform6.dll


   19k 2002/02/20 C:\cygwin\bin\cyggdbm.dll


   17k 2001/06/28 C:\cygwin\bin\cyghistory4.dll


   20k 2002/10/10 C:\cygwin\bin\cyghistory5.dll


  929k 2002/06/24 C:\cygwin\bin\cygiconv-2.dll


   22k 2001/12/13 C:\cygwin\bin\cygintl-1.dll


   28k 2002/09/20 C:\cygwin\bin\cygintl-2.dll


   21k 2001/06/20 C:\cygwin\bin\cygintl.dll


  119k 2002/02/09 C:\cygwin\bin\cygjpeg6b.dll


   26k 2001/04/25 C:\cygwin\bin\cygmenu5.dll


   20k 2002/01/09 C:\cygwin\bin\cygmenu6.dll


  156k 2001/04/25 C:\cygwin\bin\cygncurses++5.dll


  175k 2002/01/09 C:\cygwin\bin\cygncurses++6.dll


  226k 2001/04/25 C:\cygwin\bin\cygncurses5.dll


  202k 2002/01/09 C:\cygwin\bin\cygncurses6.dll


   15k 2001/04/25 C:\cygwin

tetex (latex) permission problem on NT

2004-03-09 Thread d j

Dear All,

I could not find any reference to this anywhere, so
FYI or maybe for the FAQ:

Running Cygwin 1.5.7-1 on XP professional, any attempt
to run latex produced an immediate permission error on
texmf.cnf ('cannot access', if I recall well). I
noticed that some of the files in the texmf subdir
have a  'group' property of Users, other of 'None'
(which is everyone, afaik). 

I logged in to XP as Admin and recursively allowed
Users access to files/directories under texmf. This
solved the problem.

I think my problem was related to the fact that my
login is domain controlled (ie not local to the
machine). This renders me a member of the group Users,
who don't have access to all files in the texmf
directory. 

I am not exactly an expert on the confusing topic of
NT vs unix vs cygwin permissions, so correct me if
what I did is overkill.

CHeers,
Dirk
 


__
Do you Yahoo!?
Yahoo! Search - Find what you’re looking for faster
http://search.yahoo.com

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: gettext-0.12.1-3 (+gettext-devel+libgettextpo0+libintl2) ques tion

2004-04-29 Thread D K
Eric Lassauge said: 
> I had problems with gettext enabled programs when
running 
> Cygwin with a french locale 
> (LANG=fr;LC_ALL=fr;LC_CTYPE=iso-8859-1), all
translated 
> messages containing special characters (0x160 to
0x255 : 
> letters with accent,
> grave,...) where bad: é (small e acute) was
displayed 'e (accent+e = 2
> characters)
> for example.
> 
> Am I the only one to see that ? Is the underlying
system (see 
> my cygcheck
> output)
> the cause ? I recompiled from source (using 
> gettext-0.12.1-3-src.tar.bz2) and the new generated
version 
> has not this problem ...

The cygwin version of gettext is compiled with
libiconv, which provides translation between the input
(message catalog) character set and your output
character set.

Cygwin uses newlib. Newlib only supports the C
(USASCII) character set.

Despite setting LC_CTYPE, libiconv thinks you're using
the USASCII character set, and gettext transliterates
to that character set.

When you recompiled (without libiconv), gettext can't
do the character set conversion and just outputs the
text in the input character encoding (which happens to
work).

You can get around this with the distributed gettext
by setting the environment variable OUTPUT_CHARSET to
your desired character set. Note that if your terminal
is not using that character set you might not see the
correct characters.

Dave.




__
Do you Yahoo!?
Win a $20,000 Career Makeover at Yahoo! HotJobs  
http://hotjobs.sweepstakes.yahoo.com/careermakeover 

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



dumb question: where is gcc?

2002-02-22 Thread D. Mckenzie

I just installed cygwin on Win2KPro, using the standard
"setup.exe" off cygwin web site with the "install everything"
(or so I thought) option.  My trusty GNU C compiler
is nowhere in sight.  What totally obvious thing am I missing?

Thanks.  I found no mention of a separate download of gcc in the FAQ.

Please reply to me off-list.

Don McKenzie


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/




Re: cygwin setup freezes

2002-05-10 Thread D G

> Jack Tan wrote:
>At 09:59 AM 5/7/2002, Sander Timmermans wrote:
>>I tried to use the KDE sourceforge ftp with the latest cygwin setup.exe, but
>>it messed up my Cygwin install.
>>So I must reinstall cygwin but setup.exe freezes everytime.
>>I tried with the setup.exe that comes with local packages and the normal
>>internet install setup.exe.
>>I am desperate ! I cannot continue :(
>
>I also experienced this problem using setup 2.194.2.24.  setup.ini downloads
>to 98% (96k/98k), the CPU spikes for several seconds (450MHz), and then focus
>shifts to an invisible "Parse Error" error dialog, as indicated by the
>Taskbar.  Hitting Enter dismisses the dialog and brings the user back to the
>"select a download site" setup screen.  There's nothing interesting in the
>setup.log file.
>
>The problem goes away if you download setup 2.194.2.26 from
>http://www.cygwin.com/setup.exe.

Interesting.  By clicking on this link, I got the 2.194.2.24 version.  However, using 
http://cygwin.com/setup.exe downloaded the 2.194.2.26 version.  Then when I went back 
to http://www.cygwin.com/setup.exe, it downloaded the 2.194.2.26 version.  Must be a 
caching issue with my proxy.  Anyway...

The 2.194.2.26 version works for me on selecting the "Download from Internet" option, 
while the 2.194.2.24 version was hanging at a parse error.  One funny thing about the 
2.194.2.26 version is that when selecting packages, there is a second "Cygwin Setup" 
window that says "This space left intentionally blank".  I'm not sure what that's all 
about.  It doesn't seem to cause any problems.

However, the "Install from Local Directory" option (after doing the Download from 
Internet) gave me quite a few errors.  First, there were multiple windows with lots of 
parse errors.  After clicking OK on four or five of them, the install continued and 
appeared to work.  During the install, there was a pop-up that said "Can't open (null) 
for reading".  I clicked OK and the install continued.  When the install finished, 
everything appeared OK, but I'm very apprehensive about all the errors and pop-up 
windows.

The first line in the "Parse Errors" window is:

setup.ini line 3297: parse error, unexpected $undefined

Thereafter, all lines look like this:

setup.ini line 3297: unrecognized line in setup.ini headers (do you have the latest 
setup?)

The line numbers keep incrementing up to 3332.  Clicking OK brings up another window 
that looks the same but the last line number is higher.  As I said before, after four 
or five windows, it continues with the installation and completes it successfully.  
The strange thing about this is that there are only 2216 lines in the setup.ini file 
(from mirrors.rcn.net).

There's nothing interesting in the setup.log or setup.log.full files.

I'm running Windows NT4, Service pack 5.

--
Daniel
[EMAIL PROTECTED]
(remove the Z-'s to reply--they're what I do when I read spam)

-- 
___
Sign-up for your own FREE Personalized E-mail at Mail.com
http://www.mail.com/?sr=signup


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/




Re: cygwin setup freezes

2002-05-10 Thread D G

OK, that last message did not come through very well.  Here's another try...

Jack Tan wrote:
>At 09:59 AM 5/7/2002, Sander Timmermans wrote:
>>I tried to use the KDE sourceforge ftp with the latest cygwin setup.exe, but
>>it messed up my Cygwin install.
>>So I must reinstall cygwin but setup.exe freezes everytime.
>>I tried with the setup.exe that comes with local packages and the normal
>>internet install setup.exe.
>>I am desperate ! I cannot continue :(
>
>I also experienced this problem using setup 2.194.2.24.  setup.ini downloads
>to 98% (96k/98k), the CPU spikes for several seconds (450MHz), and then focus
>shifts to an invisible "Parse Error" error dialog, as indicated by the
>Taskbar.  Hitting Enter dismisses the dialog and brings the user back to the
>"select a download site" setup screen.  There's nothing interesting in the
>setup.log file.
>
>The problem goes away if you download setup 2.194.2.26 from
>http://www.cygwin.com/setup.exe.

Interesting.  By clicking on this link, I got the 2.194.2.24 version.
However, using http://cygwin.com/setup.exe downloaded the 2.194.2.26
version.  Then when I went back to http://www.cygwin.com/setup.exe,
it downloaded the 2.194.2.26 version.  Must be a caching issue with
my proxy.  Anyway...

The 2.194.2.26 version works for me on selecting the "Download from
Internet" option, while the 2.194.2.24 version was hanging at a parse
error.  One funny thing about the 2.194.2.26 version is that when
selecting packages, there is a second "Cygwin Setup" window that says
"This space left intentionally blank".  I'm not sure what that's all
about.  It doesn't seem to cause any problems.

However, the "Install from Local Directory" option (after doing the
Download from Internet) gave me quite a few errors.  First, there were
multiple windows with lots of parse errors.  After clicking OK on four
or five of them, the install continued and appeared to work.  During
the install, there was a pop-up that said "Can't open (null) for
reading".  I clicked OK and the install continued.  When the install
finished, everything appeared OK, but I'm very apprehensive about all
the errors and pop-up windows.

The first line in the "Parse Errors" window is:

setup.ini line 3297: parse error, unexpected $undefined

Thereafter, all lines look like this:

setup.ini line 3297: unrecognized line in setup.ini headers (do you have the latest 
setup?)

The line numbers keep incrementing up to 3332.  Clicking OK brings up
another window that looks the same but the last line number is higher.
As I said before, after four or five windows, it continues with the
installation and completes it successfully.  The strange thing about
this is that there are only 2216 lines in the setup.ini file (from
mirrors.rcn.net).

There's nothing interesting in the setup.log or setup.log.full files.

I'm running Windows NT4, Service pack 5.

--
Daniel
[EMAIL PROTECTED]
(remove the Z-'s to reply--they're what I do when I read spam)

-- 
___
Sign-up for your own FREE Personalized E-mail at Mail.com
http://www.mail.com/?sr=signup


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/




Re: Setup failures over the last few days

2002-05-10 Thread D G

Robert Collins wrote:
>Short answer: use
>http://www.cygwin.com/setup-snapshots/setup-20020510.exe.
[snip]
>
>Please, try the setup linked above, and if you have any errors let me
>know. AFAICT though, it should be ready for widespread use now.

This did not perform any differently than 2.194.2.26 version of setup.  See my post 
titled "Re: Cygwin Setup Freezes", unfortunately, it still applies to this 2.218.2.3 
version of setup.

--
Daniel
[EMAIL PROTECTED]
(remove the Z-'s to reply--they're what I do when I read spam)

-- 
___
Sign-up for your own FREE Personalized E-mail at Mail.com
http://www.mail.com/?sr=signup


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/




RE: Setup failures over the last few days

2002-05-14 Thread D G

From: "Robert Collins" <[EMAIL PROTECTED]>
Date: Sat, 11 May 2002 09:34:49 +1000
> Can you be more specific about what from that message applies?
> 
> Rob

Yes.  This part:


However, the "Install from Local Directory" option (after doing the
Download from Internet) gave me quite a few errors.  First, there were
multiple windows with lots of parse errors.  After clicking OK on four
or five of them, the install continued and appeared to workWhen
the install finished, everything appeared OK, but I'm very apprehensive
about all the [parse] errors and pop-up windows.

The first line in the "Parse Errors" window is:

setup.ini line 3297: parse error, unexpected $undefined

Thereafter, all lines look like this:

setup.ini line 3297: unrecognized line in setup.ini headers (do you have the latest 
setup?)

The line numbers keep incrementing up to 3332.  Clicking OK brings up
another window that looks the same but the last line number is higher.
As I said before, after four or five windows, it continues with the
installation and completes it successfully.  The strange thing about
this is that there are only 2216 lines in the setup.ini file (from
mirrors.rcn.net).

There's nothing interesting in the setup.log or setup.log.full files.

I'm running Windows NT4, Service pack 5.


The above still happens with the 2.218.2.6 version of setup.exe,
except now the first parse error is at line 2275, and there are 2274
lines in the setup.ini file.

--
Daniel
[EMAIL PROTECTED]
(remove the Z-'s to reply--they're what I do when I read spam)

> 
> > -Original Message-
> > From: D G [mailto:[EMAIL PROTECTED]] 
> > Sent: Saturday, May 11, 2002 4:17 AM
> > To: [EMAIL PROTECTED]
> > Subject: Re: Setup failures over the last few days
> > 
> > 
> > Robert Collins wrote:
> > >Short answer: use 
> > >http://www.cygwin.com/setup-snapshots/setup-20020510.exe.
> > [snip]
> > >
> > >Please, try the setup linked above, and if you have any 
> > errors let me 
> > >know. AFAICT though, it should be ready for widespread use now.
> > 
> > This did not perform any differently than 2.194.2.26 version 
> > of setup.  See my post titled "Re: Cygwin Setup Freezes", 
> > unfortunately, it still applies to this 2.218.2.3 version of setup.
> > 
> > --
> > Daniel
> > [EMAIL PROTECTED]
> > (remove the Z-'s to reply--they're what I do when I read spam)

-- 
___
Sign-up for your own FREE Personalized E-mail at Mail.com
http://www.mail.com/?sr=signup


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/




RE: New setup uploaded - 2.218.2.8

2002-05-16 Thread D G

From: "Harig, Mark A."  
>I think I see now.  I was simply letting 'setup.exe' use its defaults.
>It defaults to using 'c:\cygwin' for the Root Install Directory and
>'c:\cygwin' for the Local Package Directory.  I assumed that setup was
>searching in the '/' directory tree, but that was just a coincidence
>because my '/' mount point is 'c:\cygwin'.  In fact, setup searches in
>whatever location is provided for Local Package Directory.  I changed my
>Local Package Directory setting to c:\cygwin\setup (a directory that did
>not exist), and setup created the needed directory.  None of the parsing
>errors that I reported earlier were generated because setup no longer
>finds invalid 'setup.ini' files from other, non-setup packages.

OK.  For those of us who did it the "wrong" way (mine is set to H:\), how can I change 
the local package directory and still keep all the current package information?  Is it 
automatic?  What about the "latest" and "contrib" directories?  Are those obsolete?

On the other hand, would it be a good idea for setup.exe to tag its directories in 
some way, like with a zero-byte file, so that it doesn't take just any old setup.ini 
file it finds?

--
Daniel
[EMAIL PROTECTED]
(remove the Z-'s to reply--they're what I do when I read spam)

-- 
___
Sign-up for your own FREE Personalized E-mail at Mail.com
http://www.mail.com/?sr=signup


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/




RE: New setup uploaded - 2.218.2.8

2002-05-17 Thread D G

From: "Robert Collins" <[EMAIL PROTECTED]>
Date: Fri, 17 May 2002 08:04:42 +1000
> > -Original Message-
> > From: D G [mailto:[EMAIL PROTECTED]] 
> > Sent: Friday, May 17, 2002 5:32 AM
> 
> > OK.  For those of us who did it the "wrong" way (mine is set 
> > to H:\), how can I change the local package directory and 
> > still keep all the current package information?  Is it 
> > automatic?  
> 
> Just change it in setup next time you run it. If you want to keep all
> the cached data, just copy the directories that look like ftp%3f and
> their contents to whereever your new local package dir will be. BTW: the
> default is the dir you run setup from, so you must have created
> c:\cygwin, copied setup there, and then run it...right?

Well, it appears to be automatic since I moved the latest/ contrib/
and http[etc]mirrors.rcn.net[more etc]/ to a seperate drive (not in
the path) and setup still ran correctly.  I can only conclude that
the information about installed packages is stored somewhere else,
and that the latest/ contrib/ and [that other directory] are only used
to store downloaded packages.

> > On the other hand, would it be a good idea for setup.exe to 
> > tag its directories in some way, like with a zero-byte file, 
> > so that it doesn't take just any old setup.ini file it finds?
> 
> Mmmm. I'll think about this. I don't want to interfere with users using
> mirroring tools.
> 
> Rob

--
Daniel
[EMAIL PROTECTED]
(remove the Z-'s to reply--they're what I do when I read spam)

-- 
___
Sign-up for your own FREE Personalized E-mail at Mail.com
http://www.mail.com/?sr=signup


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/




isip_production in cygwin

2002-09-26 Thread Gangaa D

Dear Sir,

I trying to install Production System (r00_n09) in
cygwin on win98. But is does not install. 
Is here anyone successful install Production System  
in cygwin?

Please kindly recommend me

Regards,
Gangaa

 


__
Do you Yahoo!?
New DSL Internet Access from SBC & Yahoo!
http://sbc.yahoo.com

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/




telnet, ftp unknown service

2003-10-02 Thread V D
suddenly telnet, ftp, rlogin stopped running last tuesday, I did not change
anything, I have a w2k/cygwin :
CYGWIN_NT-5.0 nbvdu01 1.5.5(0.94/3/2) 2003-09-20 16:31 i686 unknown unknown
Cygwin

I re-install some parts of cygwin package (login, cygwin engine) and
strangely telnet only works when used with Expect, but does not work from a
bash !!!

-- 
Vincent Dutat
-




--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: telnet, ftp unknown service

2003-10-02 Thread V D
here is the result of strace on a telnet, if you need specifically on ftp
just let me know.




"Corinna Vinschen" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> On Thu, Oct 02, 2003 at 10:48:58AM +0200, V D wrote:
> > suddenly telnet, ftp, rlogin stopped running last tuesday, I did not
change
> > anything, I have a w2k/cygwin :
> > CYGWIN_NT-5.0 nbvdu01 1.5.5(0.94/3/2) 2003-09-20 16:31 i686 unknown
unknown
> > Cygwin
> >
> > I re-install some parts of cygwin package (login, cygwin engine) and
> > strangely telnet only works when used with Expect, but does not work
from a
> > bash !!!
>
> I can't reproduce this, trying with ftp and slogin.  Can you send an
> strace of a failing ftp session to this list, please?
>
> Corinna
>
> -- 
> Corinna Vinschen  Please, send mails regarding Cygwin to
> Cygwin Developermailto:[EMAIL PROTECTED]
> Red Hat, Inc.
>


begin 666 strace.out.gz
M'XL("%FW>C\``W-TNU>Z(\T`?E15
M5U77J[MK_O*70_[\_--=$C\F_M2(_&G@&2UO,'I]? FCP5?XFP63*,AJP?? 
M.*&N*=[__%-S-C.>@[EMAIL PROTECTED](5>.GAC\+/8/47/+S3^WKZ\T'K-4#IGK@
MZSR-+&(WCE]2XO3^S:@#^8^#/C#3\
[EMAIL PROTECTED] 8KL)2<$6I0[E'+X_;//QW$&6"-P3AU)32+68[Q
MQ]0/H[\:BB>&9(<11,]A$D?#, HS&-[W)C$)(<(S_NVCU_BX8"4``@@V`G($
MKPK(; [EMAIL PROTECTED]'LVG092EAA^-C7Z096'TF Z:DXGQ
M*07&273<<20ZF]JD*CJ+$D!W=]=NWC=WH'D.HQ%<'8 >3,*1GX&8#&"[EMAIL PROTECTED]
MF\1JL>I8+<#::M\U[S\V:[EMAIL PROTECTED]&Y6!F-+,-?-?A\A`?D+M;X,)T$Z
MZ'P?!<&X!G0_C29_)J/TN?:GGYSO>.Y<#4A1PEU1F9(+D%JK>W/3O069?>@U
M;Z3<^MLDM>+I%'B'/R0N4XG,$8Y5&=_&Y_8E013N7
M\ 3CE6FWJ8+7O^NT),%?KFYO[P?I:YH%4\X&H^E8F@(4$5? '8?J@,_\) V&
M\4QJ1^H9H$3!R$"J3"+DBRYUW HO9MFKM"#J36'AF[:MU8J--Y,@FR<1:*Q\
ME1%DK2OTU&I9P:48?_\`+&@H\H$6),.6$YD2SBM;!-LA"[EMAIL PROTECTED] ,%
MXR4!4HM5)[EMAIL PROTECTED]&]/5Y/"?4(RNY4$8L+9,>@PRP`DC/&/G1N\Q(
[EMAIL PROTECTED],![BQ/C8!1T"ZPI3W(CB!6[C-[EMAIL PROTECTED]I/L)F#J7_L=GK- :#*(4PB5"4S7 <)K\,P)0HWX%3RS[ R D3
[EMAIL PROTECTED];S\T+GO*G>&4L 6M;-:$)4%T/Z G6Z?$H8YV9FG!V I,]Q8"I\^='@RT
MZ!8M5&C'[EMAIL PROTECTED],_.\.;;KO3F$?A]Y7#IH(0K2O30FH2">D6Q>C5YVE2
M3]-)?>I'BC2<#(+;U;G>`H"WGVXN.KUA]W(($4>KT^]W>_T&+0A!"+.Z$#H`
ML7O=OOO2;M1ASJWB.NHR4AV,#$VZ?79]=;&(R#:[EMAIL PROTECTED]X_FC]H8_%-'R\)[EMAIL PROTECTED])+?5_D T@)B.CMG)7$(K8
M6O/Q8]X3!#68Q(_[7"9C#&EPA3;&W.W<'+V,[EMAIL PROTECTED]:.VGC_9/'J>TED\9YQ
[EMAIL PROTECTED]:09* ?A'E`E%E`:XV:=)K58$IN@>,DUHN;V0#
MH*@8=CJGK]-)&'U;8'\*1M\@
MMHDSPU_<[EMAIL PROTECTED](&[EMAIL PROTECTED]"X2 U/(;-;RDG9=.P2/FA=]A2F9[_*QS33YA3%]>2G0W\T24_$>U6V0 &;#C\J
ML-T]8<']`>:1/Y&UIE-C5ZAO(I
M'B'6%04',":7O&* I<]U?DP.>[F/13!F":[USONX7XWGJY&BB[*)>92;1$Y7
MX?$2'T')VLRL;('>CK,0?B-R4X_\;3G+L?3";.>X]/UPSF(9C]FN/K<[AK.U
MG=RD+GH[!Y*.8Q#62D96*XH*#.%1P-]$3QQ+C_R-]01SH)M .!'(#T'WRX!BAN42=H ,-$A*^:]YMJB#+N/:0'8O
M[X&IXP2RR/[EMAIL PROTECTED])PS;>+N$:;N?=N;[EMAIL PROTECTED]:[EMAIL PROTECTED]
M/UGT%1!%'^?U"_Q'Z/4"'9584N ])U2\62RP0%3!O'/"]7AWLWPOIR4*2C!/
MX=2TCAK:%H/W\/6]6B\P$:=XNXK'[EMAIL PROTECTED]>FR.B5,R(.6";0X]FO
MU&N/%RH1G+'C=&I;LQ+J&==R='T54)
M8W\^F\5)9MS'\23=(2H5EW!N$>TTKBBJ=6S5Y;7^7AZH6$B0H,<%2J5"6\-5
M67(:"G.U,HE^[?TM0JD_Q]\JA+0H.9/IR__5PJD<4>60*G^^$%/#7#>U\=S1
[EMAIL PROTECTED]""T*E*D%M^X*[EMAIL PROTECTED]/J-"7^',H9B@'-<^:J2:7H.I_*OO<>Z8T&%"Z)?-*AH
MW9>XJEOVY2O%*$#(&L>;6G5 45]0=AC;<[EMAIL PROTECTED]>M-ZQC_9.GX&ZV9-3HD
M%_^G6\`-?0[0ZHJM!IXP(#=RVA%>B.
MO6=KRV/>[EMAIL PROTECTED]>K\N:5EX6V;VD>7LNTO0JYWHYGUE.+V06RB
MCE8YZ'HA<:^\-[A)%_[OJT,?AC0#C_*SD?S/]]\.0-7@:$.(OOOQJKW>ZFZ8KJX%'G\EW,
MRWV=MBQ_F!;75Y"T<.1AF_['Z\_7:D^U112(DKJ"%H3<]MW_O7_?N5$'`5KJ
M(("#%MIF^G1#`PGF^1+2XB016D85?B./;*$'MV_O,X"\*]_[S'%O#>3T;YJL
MM;NM3S>=_Z'+4X77W5;[EMAIL PROTECTED]/I;.]N9BQ7FHZI/VY8FJ[MQKHK6]O]9F'_
MFNG8/UY#76"KY]CJ"VSUG,ZCN*I2-1O]AF!NY6,]>:I6F3ZU(PN-BS!%Y=-(
MN4:B-NX=BUI)5$,1^FV\.P-:Q'+8D'+OYS+]:IAVTDH_=0PJ/!4!CE&_?JZU
M-!>(JG?3^)X%R5293CE+P"[K]QCN-0L[K8*M8)OTJ-+2_XU5P#WO%K'U)OX?
M8Q6XQ9$H5[^Y[/^)5;#0*EC4TA]C?"NKX.)N;HN9;F4T"ZM0U2B8EHDH7$OK
M&G8;A<,GJD"5X]6/[EMAIL PROTECTED]'),ZUVB5+7WK,%DR#I(]!)9'ZAR$89;L)\B,Y,E6/''XY"?!,N5DJ^C=
MLBW]N3 M:'G*$F+/]E5O+0K-I>:0RF4':

lockfile & link on Core Duo laptop

2006-06-24 Thread Benjamin D
Hi!

I've been using cygwin for a long time on my notebooks and desktops. I
recently got a Core Duo for work. Most things seem to work fine, but
lockfie didn't. I got the helpful error message:
  lockfile foo
  lockfile: Try praying, giving up on "foo"

So, I downloaded the source and traced where the error was occuring.
It's happening at a call to link(2):

   #include 

   int link(const char *oldpath, const char *newpath);

Which is returning errno:
   ENOENT A directory component in oldpath or newpath does not exist or is
  a dangling symbolic link.

lockfile creates a temporary file, then links that to the file you
specify on the command line. When I was tracing through, I could see
that the temporary file was created. That suggests to me that the path
and permissions are OK. It just can't link. I ran it through strace, and
see:

   51   77145 [main] lockfile 4080 fhandler_base::set_flags: O_TEXT/O_BINARY 
set in flags 0x1
   50   77195 [main] lockfile 4080 fhandler_base::set_flags: filemode set to 
binary
   49   77244 [main] lockfile 4080 fhandler_base::open: 0 = NtCreateFile 
(0x6B4, 20100, C:\cygwin\tmp\_w_.CsgnEB.bdodge-lt, io, NULL, 0, 7, 1, 4400, 
NULL, 0)
   53   77297 [main] lockfile 4080 fhandler_base::open: 1 = fhandler_base::open 
(C:\cygwin\tmp\_w_.CsgnEB.bdodge-lt, 0x11)
   51   77348 [main] lockfile 4080 fhandler_base::open_fs: 1 = 
fhandler_disk_file::open (C:\cygwin\tmp\_w_.CsgnEB.bdodge-lt, 0x1)
 5656   83004 [main] lockfile 4080 fhandler_disk_file::link: CreateHardLinkA 
failed
   85   83089 [main] lockfile 4080 seterrno_from_win_error: 
/netrel/src/cygwin-1.5.19-4/winsup/cygwin/fhandler_disk_file.cc:786 windows 
error 3
   57   83146 [main] lockfile 4080 geterrno_from_win_error: windows error 3 == 
errno 2
   50   83196 [main] lockfile 4080 __set_errno: void 
seterrno_from_win_error(const char*, int, DWORD):310 val 2
   51   83247 [main] lockfile 4080 fhandler_base::close: closing 
'/tmp/_w_.CsgnEB.bdodge-lt' handle 0x6B4
   75   83322 [main] lockfile 4080 link: -1 = link (_w_.CsgnEB.bdodge-lt, foo)
   50   83372 [main] lockfile 4080 lstat64: entering
   49   83421 [main] lockfile 4080 normalize_posix_path: src 
_w_.CsgnEB.bdodge-lt
   48   83469 [main] lockfile 4080 cwdstuff::get: posix /tmp


So, I tried just linking a file:

  $ ls -il foo bar; touch foo && link foo bar && ls -il foo bar
  ls: foo: No such file or directory
  ls: bar: No such file or directory
  2251799813741751 -rw--- 2 bdodge mkgroup-l-d 0 Jun 24 20:56 bar
  2251799813741751 -rw--- 2 bdodge mkgroup-l-d 0 Jun 24 20:56 foo

Works fine, so I try seeing what happens with strace:

  $ ls -il foo bar; touch foo && strace link foo bar > strace.out 2>&1 && ls 
-il foo bar
  ls: foo: No such file or directory
  ls: bar: No such file or directory
  ls: bar: No such file or directory
  2814749767163063 -rw--- 1 bdodge mkgroup-l-d 0 Jun 24 20:58 foo

It doesn't work when run under strace. strace.out is below.

Any suggestions on how to make link work reliably on this system? I've
tried using the revs of lockfile(procmail) & cygwin from my old laptop
and the latest install.


Thanks,
Benjamin


**
Program name: C:\cygwin\bin\link.exe (pid 3888, ppid 1)
App version:  1005.19, api: 0.150
DLL version:  1005.19, api: 0.150
DLL build:2006-01-20 13:28
OS version:   Windows NT-5.1
Heap size:402653184
Date/Time:2006-06-24 21:06:23
**
   49 449 [main] link 3888 set_myself: myself->dwProcessId 3888
   45 494 [main] link 3888 time: 1151208383 = time (0)
  388 882 [main] link 3888 environ_init: GetEnvironmentStrings returned 
0x245300 - "=::=::\"
   72 954 [main] link 3888 environ_init: 0x460238: !::=::\
   691023 [main] link 3888 environ_init: 0x460248: 
ALLUSERSPROFILE=C:\Documents and Settings\All Users
  1311154 [main] link 3888 environ_init: 0x460280: APPDATA=C:\Documents and 
Settings\bdodge\Application Data
   581212 [main] link 3888 environ_init: 0x4602C0: CLIENTNAME=Console
   571269 [main] link 3888 environ_init: 0x4602D8: COLORFGBG=0;default;15
   561325 [main] link 3888 environ_init: 0x4602F8: COLORTERM=rxvt-xpm
   561381 [main] link 3888 environ_init: 0x460310: 
COMMONPROGRAMFILES=C:\Program Files\Common Files
   561437 [main] link 3888 environ_init: 0x460348: COMPUTERNAME=BDODGE-LT
   571494 [main] link 3888 environ_init: 0x460368: 
COMSPEC=C:\WINDOWS\system32\cmd.exe
   561550 [main] link 3888 environ_init: 0x460390: CVS_RSH=/bin/ssh
   561606 [main] link 3888 environ_init: 0x4603A8: DISPLAY=127.0.0.1:0
   551661 [main] link 3888 environ_init: 0x4603C0: EDITOR=vim
   561717 [main] link 3888 environ_init: 0x4603D0: 
ENV=/cygdrive/c/Data/bdodge/.bashrc
   561773 [main] link 3888 environ_init: 0x4603F8

Re: lockfile & link on Core Duo laptop

2006-06-24 Thread Benjamin D
> >Any suggestions on how to make link work reliably on this system? I've
> >tried using the revs of lockfile(procmail) & cygwin from my old laptop
> >and the latest install.
> 
> Any chance the source of this problem is related to this:
> 
> 

I did have that problem with ssh, so I updated the Wave software. It
fixed ssh, but not the lockfile/link problems.

- Benjamin

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: lockfile & link on Core Duo laptop

2006-06-25 Thread Benjamin D
On Jun-25-06 07:06AM, Lev Bishop wrote (Re: lockfile & link on Core Duo laptop):
> On 6/25/06, Benjamin D wrote:
> >
> >Works fine, so I try seeing what happens with strace:
> >
> > $ ls -il foo bar; touch foo && strace link foo bar > strace.out 2>&1 && 
> > ls -il foo bar
> > ls: foo: No such file or directory
> > ls: bar: No such file or directory
> > ls: bar: No such file or directory
> > 2814749767163063 -rw--- 1 bdodge mkgroup-l-d 0 Jun 24 20:58 foo
> 
> Some WAG things to try:
> a) Put in a pause:
> $ ls -il foo bar; touch foo && sleep 2 && strace link foo bar >
> strace.out 2>&1 && ls -il foo bar

Nope.

> b) Completely uninstall the Embassy Trusted Security thing (or
> whatever it's called).

Yes! Thanks! :-)

> c) Suspect (and, to test, uninstall (not just disable)) any realtime
> virus scanners, personal firewalls, file indexers (google desktop
> search) and anything else that hooks into file syscalls stuff.
> (Especially do this if step (a) made any difference).

For the record, I tried this 2nd (before uninstalling Embassy). It
didn't help to disable the Windows "Indexing Service".

Thanks again!
- Benjamin

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Is SEM_UNDO problem fixed (in v 1.5.11)?

2004-10-28 Thread D L
Hi,

I am calling semop to increment or decrement
an IPC semaphore with SEM_UNDO. Then I abort
the process using Ctrl+C and check the semaphore
status. I expect the effect of the semop
to be undone at that point, but it is not.

It is either a bug or I am doing something wrong.

I see that the problem with SEM_UNDO was already
reported and on 2 Mar 2004 Corinna Vinschen wrote:

"Yes, it's a bug in Cygserver.  "
...
"I've checked in a fix to Cygserver."

I am using cygserver: (cygwin) 1.10
API version 1.5.11(0.116/4/1)-(3.0.0.2) 2004-09-04
23:17

So, my question is whether the SEM_UNDO was indeed  
fixed and, whether it was recently tested and, if yes,
how to use it properly to have the result of semop
undone on process exit/abort.

Thank you
John




__
Do you Yahoo!?
Yahoo! Mail Address AutoComplete - You start. We finish.
http://promotions.yahoo.com/new_mail 

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



No _g_config.h on gcc dist?

2004-10-31 Thread John D
Hi,

I have built a mips cross-compiler environment by installing the default cygwin 
packages plus gcc and glib and then installing the mips cross compiler under 
usr/local - this is on a W2K OS. C prog compile and run fine, but C++ apps that 
use the STL fail to compile as below. I've searched my installation and can't 
find any _G_config.h file. Should this be created by cygwin or the cross 
compiler?

Cheers,
John

mips-g++ -c -O2 -mtap -mlong-calls -msoft-float -D_TAP -DNDEBUG -fno-rtt
i -fno-exceptions -Wno-pmf-conversions -I c:\cygwin\usr\local\include\g++-3 -I..
\..\Build\include -I c:\cygwin\usr\include -I c:\cygwin\usr\local\include mysamp
le.cpp
In file included from c:/cygwin/usr/local/include/g++-3/stl_algobase.h:36,
 from c:/cygwin/usr/local/include/g++-3/stack:30,
 from mysample.cpp:4:
c:/cygwin/usr/local/include/g++-3/stl_config.h:151:26: _G_config.h: No such file
 or directory
In file included from c:/cygwin/usr/local/include/g++-3/streambuf.h:36,
 from c:/cygwin/usr/local/include/g++-3/iostream.h:31,
 from c:/cygwin/usr/local/include/g++-3/stl_algobase.h:53,
 from c:/cygwin/usr/local/include/g++-3/stack:30,
 from mysample.cpp:4:
c:/cygwin/usr/local/include/g++-3/libio.h:30:23: _G_config.h: No such file or di
rectory
NMAKE : fatal error U1077: 'mips-g++' : return code '0x1'
Stop.


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: ssh expect on Cygwin

2004-10-31 Thread D N
Since passwordless authentication is broken on many cygwin systems I use, I 
end
up using the following expect script (more frequently that I would like).
Are you sure you cant just fix the passwordless login?
I have cyg on 5 different systems - works like a charm! I use keychain to 
manage the keys.

_
Express yourself instantly with MSN Messenger! Download today - it's FREE! 
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


mailling list ID tag

2004-11-16 Thread D N
I apologize if this has been suggested before...
Would it be possible to ask the kind Cygwin people to put a tag on their 
mailing list?

For example, I am subscribed to several other lists that use:
[Subject] as their tag. This makes filtering into different folders easy and 
I can find what I want to read more easily.


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


RE: SSH, SFTP, and NTSEC

2004-12-27 Thread D N

My problem is simple... I have users that I created that cannot log in via 
SSH unless I make them >members of the Windows ADMINISTRATORS group on the 
Windows 2003 server that is running >Cygwin.  I've tried everything I can 
think of and lots of stuff from other people that I could never >have 
thought up myself.
What user account is your SSH daemon running as? Using priv separation?
Dan

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


tetex problems: postinstall hangs, format not installed, root can run latex

2005-04-14 Thread d j
00 Service
Pack 2

Path:   C:\cygwin\usr\local\bin
C:\cygwin\bin
C:\cygwin\bin
C:\cygwin\usr\X11R6\bin
c:\WINDOWS\system32
c:\WINDOWS
c:\WINDOWS\System32\Wbem
c:\Program Files\Common Files\Adaptec Shared\System
c:\PROGRA~1\ATT\Graphviz\bin
c:\PROGRA~1\ATT\Graphviz\bin\tools
C:\cygwin\bin
c:\WINDOWS\system32
c:\WINDOWS
c:\WINDOWS\System32\Wbem
c:\Program Files\Common Files\Adaptec Shared\System
c:\PROGRA~1\ATT\Graphviz\bin
c:\PROGRA~1\ATT\Graphviz\bin\tools
C:\cygwin\bin
C:\cygwin\bin
c:\Program Files\R\rw2001\bin
.\

Output from C:\cygwin\bin\id.exe (nontsec)
UID: 91048(dpj)  GID: 10513(Domain Users)
10513(Domain Users)

Output from C:\cygwin\bin\id.exe (ntsec)
UID: 91048(dpj)  GID: 10513(Domain Users)
547(Power Users) 545(Users)  
81252(aldus users)
58043(All Staff) 81276(caxton users) 
10513(Domain Users)
57962(KLT4Users) 91083(N104 Users)   
81132(seurat users)
22793(SYR Accounts)  75512(VPN-auth-users)   
66399(VPNUsers)

SysDir: C:\WINDOWS\system32
WinDir: C:\WINDOWS

CYGWIN = `ntsec tty'
HOME = `c:\Documents and Settings\dpj\My Documents'
MAKE_MODE = `unix'
PWD = `/cygdrive/x/admin/cv'
USER = `dpj'

ALLUSERSPROFILE = `C:\Documents and Settings\All
Users'
APPDATA = `C:\Documents and Settings\dpj\Application
Data'
CLIENTNAME = `Console'
COMMONPROGRAMFILES = `C:\Program Files\Common Files'
COMPUTERNAME = `PCPSY087'
COMSPEC = `C:\WINDOWS\system32\cmd.exe'
CVS_RSH = `/bin/ssh'
FP_NO_HOST_CHECK = `NO'
HOMEDRIVE = `Z:'
HOMEPATH = `\'
HOMESHARE = `\\bodiam\SYR\dpj'
HOSTNAME = `pcpsy087'
INFOPATH =
`/usr/local/info:/usr/info:/usr/share/info:/usr/autotool/devel/info:/usr/autotool/stable/info:'
LOGONSERVER = `\\CRAY'
MANPATH =
`/usr/local/man:/usr/man:/usr/share/man:/usr/autotool/devel/man::/usr/ssl/man'
NUMBER_OF_PROCESSORS = `2'
OLDPWD = `/cygdrive/c/Documents and Settings/dpj/My
Documents/admin'
OS = `Windows_NT'
PATHEXT =
`.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH'
PROCESSOR_ARCHITECTURE = `x86'
PROCESSOR_IDENTIFIER = `x86 Family 15 Model 2 Stepping
9, GenuineIntel'
PROCESSOR_LEVEL = `15'
PROCESSOR_REVISION = `0209'
PROGRAMFILES = `C:\Program Files'
PROMPT = `$P$G'
PS1 = `\[\033]0;\w\007
[EMAIL PROTECTED] \[\033[33m\w\033[0m\]
$ '
SESSIONNAME = `Console'
SHLVL = `1'
SYSTEMDRIVE = `C:'
SYSTEMROOT = `C:\WINDOWS'
TEMP = `C:\DOCUME~1\dpj\LOCALS~1\Temp'
TERM = `cygwin'
TEXDOCVIEW_dvi = `cygstart %s'
TEXDOCVIEW_html = `cygstart %s'
TEXDOCVIEW_pdf = `cygstart %s'
TEXDOCVIEW_ps = `cygstart %s'
TEXDOCVIEW_txt = `cygstart %s'
TMP = `C:\DOCUME~1\dpj\LOCALS~1\Temp'
USERDNSDOMAIN = `AD.KENT.AC.UK'
USERDOMAIN = `UKC'
USERNAME = `dpj'
USERPROFILE = `C:\Documents and Settings\dpj'
WINDIR = `C:\WINDOWS'
_ = `/usr/bin/cygcheck'
POSIXLY_CORRECT = `1'

HKEY_CURRENT_USER\Software\Cygnus Solutions
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin
HKEY_CURRENT_USER\Software\Cygnus
Solutions\Cygwin\mounts v2
HKEY_CURRENT_USER\Software\Cygnus
Solutions\Cygwin\Program Options
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus
Solutions\Cygwin\mounts v2
  (default) = `/cygdrive'
  cygdrive flags = 0x0022
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus
Solutions\Cygwin\mounts v2\/
  (default) = `C:\cygwin'
  flags = 0x000a
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus
Solutions\Cygwin\mounts v2\/usr/bin
  (default) = `C:\cygwin/bin'
  flags = 0x000a
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus
Solutions\Cygwin\mounts v2\/usr/lib
  (default) = `C:\cygwin/lib'
  flags = 0x000a
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus
Solutions\Cygwin\mounts v2\/usr/X11R6/lib/X11/fonts
  (default) = `C:\cygwin\usr\X11R6\lib\X11\fonts'
  flags = 0x000a
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus
Solutions\Cygwin\Program Options

a:  fd N/AN/A
c:  hd  NTFS 29996Mb  92% CP CS UN PA FC 
d:  hd  FAT3212499Mb   3% CPUN   DATA
e:  cd N/AN/A
f:  cd N/AN/A
t:  net NTFS  8683Mb  66% CP CS UN PA FC 
u:  net NTFS  7671Mb 100% CP CS UN PA FC User
Disk
v:  net NTFS105081Mb  89% CP CS UN PA FC New
Volume
w:  net NTFS 34859Mb  90% CP CS UN PA FC User
x:  net NTFS 43999Mb  98% CP CS UN PA FC Local
Disk
y:  net NTFS 34859Mb  90% CP CS UN PA FC User
z:  net NTFS30Mb  39% CP CS UN PA FC User
Disk - Home 5

C:\cygwin  /  
  system  binmode
C:\cygwin/bin  /usr/bin   
 

cygwin shell as a service

2004-08-03 Thread D N
Hi,
I am trying to solve a problem that is a bit "out of the box":
For my cygwin implementation, I need to do this:
-Start the cygwin shell (bash) as a windows service, hidden (no console). 
Reason being, I
cannot have someone closing the console, which would then kill all processes 
launched FROM
that window. Having it run as a service would ensure it starts on boot 
rather than upon my
admin user logging in via remote desktop.

-Start various daemons from within the cygwin shell, rather than as windows 
services:
sshd/proftpd/cron/(and init???)

-Start various programs from within the cygwin shell, some with console/GUI 
windows that
need desktop interaction.

I have noticed a few things with this.
First, the sshd/proftpd/cron processes fork children when someone connects 
or when cron jobs
are carried out, but the children do not die upon disconnect/completion. I 
have a feeling
that I am not passing the correct arguments to those, and they are not being 
run as daemons
but rather as processes.

Second, do I need to run the cygwin shell service as LocalSystem, or as as 
my admin user?
Reason being, some of the processes I would like to launch from within the 
cygwin
environment have console/GUI windows that I need to interact with on the 
desktop of my admin
user.

The reason for this whole mess is to provide a linux-like environment for my 
windows game
servers. I noticed that if I run sshd the usual way, as a windows service 
with cygrunsrv,
that the GUI windows of the applications are not "drawn" anywhere if they 
are launched from
ssh. They are "drawn" on the desktop if I launch them from the cygwin 
console though. I
briefly investigated SFU (services for unix), and I found this blurb about 
"window stations"
on that site: http://www.interopsystems.com/tools/FAQ.htm#8

I assume this non-drawing issue is the same issue present with SFU (and 
therefore a
microsoft problem rather than a cygwin/SFU problem).

This is remedied if I run the sshd directly from the cygwin shell rather 
than as a separate
service (/usr/sbin/sshd.exe), although it forks many copies of itself that 
do not die. I
think I can solve that as I mentioned above by ensuring it is run as a 
daemon rather than
just a process.

Thus, by possibly making the entire cygwin system load up as a service, 
hidden, I figure I
can eliminate the possibility of someone closing the cygwin shell window and 
killing all
subsequent processes. Does that sound rational / possible?

The only detail left is HOW to actually do that. Here is a short summary of 
what I had in
mind:
1. Windows boots up
2. Cygwin (bash) shell service started
3. Cygwin shell launches other daemons via sysVinit (sshd, proftpd, etc)
4. Cygwin shell launches my GUI programs via rc.local or equivalent

Can someone help me carry this out? Thanks!
_
Express yourself instantly with MSN Messenger! Download today - it's FREE! 
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


cygserver

2004-08-03 Thread D N
Can someone clear up for me what the purpose of cygserver is??
I was reading through the docs, I searched the lists.. I see tons about how 
to use it with PostGres, but I am not really sure *what-it-is* or if it is 
used in any other context than PostGres.

Thanks!!
Dan
_
Express yourself instantly with MSN Messenger! Download today - it's FREE! 
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


children processes left alive

2004-08-20 Thread D N
Hi,
I want to run some common daemons within cygwin rather than using windows 
services to control them, like proftpd, cron, ssh.

I have noticed that when I simply launch them from my cygwin shell window, 
like:

/usr/sbin/sshd
/usr/sbin/proftpd
/usr/sbin/cron
The applications work fine. However, if I connect via SSH or FTP, then 
disconnect, it leaves the child process that handled my connection running. 
In other words, children processes never die!

What I would like to know is how to run those daemons entirely within the 
cygwin shell and not as a separate windows service, like this:

Start cygwin bash shell --> Have Cygwin (via init) startup the various 
daemons.

Thanks!
Dan
_
Check out Election 2004 for up-to-date election news, plus voter tools and 
more! http://special.msn.com/msn/election2004.armx

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


cygwin crashes after every ~ 10th command and starts up only every ~ 4th try...

2005-06-22 Thread D. Bollmann

Hi,

Since a couple of hours cygwin crashes all the time on my windows nt 
computer. In order to restart cygwin I have to execute the xserver batch 
file several times until finally an xterm shows up. The same xterm than 
crashes after only a couple of commands - for example 10 executions of 
'ls'. I updated cygwin and also tried to reboot my computer, but the 
problem remains...


I had a somehow similar problem a couple of months ago when I tried to 
copy files recursively or used the find command. Also since a couple of 
months emacs crashes on a regular basis complaining not to be able to 
connect to the xserver.


But never the problem has been as bad as now. I am unable to use cygwin 
at all - and as cygwin for me is the only comfortable way to use windows 
I am unable to do anything at all :(  ( Here comes a very big "Thank 
you" to those guys developing cygwin - cygwin is the only thing I really 
like about Windows :)


Could it be that the crashes are related to a mapped windows drive I am 
linking to from my home directory?


I am sure I am not the first person asking this question and I know 
about the naiveness and clumsiness of this mail. Still, I don't have any 
idea how to deal with this problem and couldn't find any way out of this 
situation by myself.


Thanks for any answer, best wishes, Dietrich



--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: cygwin crashes after every ~ 10th command and starts up only every ~ 4th try...

2005-06-22 Thread D. Bollmann

Hi Dave, thanks for your long and detailed reply :)

> > Since a couple of hours cygwin crashes all the time on my windows nt
> > computer. In order to restart cygwin I have to execute the xserver 
batch

> > file several times until finally an xterm shows up. The same xterm than
> > crashes after only a couple of commands - for example 10 executions of
> > 'ls'. I updated cygwin and also tried to reboot my computer, but the
> > problem remains...
>
>   What happens if you switch your computer off and let it cool down for a
> few hours?  Odd behaviour like this is very common when a PC is 
overheating,

> and sometimes a PC can be OK in the winter and spring and then start to
> experience overheating problems when the hot summer weather arrives.  
Which
> it just has, here in England, and I'd guess over there in Deutschland 
too?


I switched off the computer yesterday in the most intense mood of 
frustration and went homeonly to find it (producing some ugly 
hovercraft like sound when starting up) working this morning as if 
nothing ever had happened...


I am working in Tokyo and thanks to the rainy season the weather changes 
all the time - plain sun & hot humid air  / less hot & rainy / hot 
weather & sun again... It would be impossible to work if the 
air-conditioner wouldn't run all the time. Still - sometimes it is quite 
hot even with the air-conditioner running...


> > I had a somehow similar problem a couple of months ago when I tried to
> > copy files recursively or used the find command. Also since a couple of
> > months emacs crashes on a regular basis complaining not to be able to
> > connect to the xserver.
> >
> > But never the problem has been as bad as now. I am unable to use cygwin
> > at all
>
>   This really does sound like an intermittent hardware problem.  Copying
> files and searching directories are among the simplest jobs a 
computer does.

> Do you experience problems with other software, or is it just cygwin that
> crashes, or do you not know because cygwin apps are almost all you run on
> the machine?

I had no problems when using the windows explorer, shifting directory 
icons from one explorer window to the next. Copying files made problems 
only when using emacs or 'cp' in a cygwin xterm. Unfortunately I do not 
remember the error message...


> > Could it be that the crashes are related to a mapped windows drive I am
> > linking to from my home directory?
>
>   Pretty unlikely.

I thought it could be caused by some network problem / mapped drive 
because normally the ls command produces output immediately. Before 
crashing on the other hand, there would be a short delay (~ half a 
second) without anything happening before the xterm finally blows up.
Also emacs would normally crash only when loading some new file or 
opening a new frame.


>   Apart from hardware troubles, the only other kinds of things that might
> cause such problems would be (very) faulty device drivers, firewall or AV
> software, but I'm still guessing it's a real hardware problem.  It might
> help if you open up your PC and make sure all the PCI cards are firmly
> seated down in their slots and all the other cables and connections are
> tight and well-made.  Sometimes things work loose with repeated cycles of
> expansion and contraction caused by heating and cooling; that's another
> reason why PCs sometimes suddenly begin to fail in peculiar ways in hot
> weather.

The strange thing is that today the computer is working normally again. 
Also, during the last weeks I had the impression that emacs and xterms 
would crash more often in the afternoon (everybody is there at this time 
- and probably it is the period of the most intense concentration and 
work). In the morning and late afternoon I normally wouldn't have too 
many problems.


Anyway, for the moment I am happy again - waiting for the next period of 
frustration...


Is there some function (network / processor data etc.) I could protocol 
somehow in order to provide some more helpful information if the problem 
repeats?


Thanks again for your detailed reply!!! I am most grateful for the time 
and effort you dedicated to your answer in order to help somebody you 
never ever have met. I don't know how I would survive my computer life 
without people like you!


Cheers & greetings from a Tokyo, gray, coolish and rainy again 
(...aha?...) - Dietrich



--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



problem with running tcl/tk scripts

2007-01-14 Thread d gitelman
Dear Cygwin
 
I apologize if this issue has been posted but I searched and could not find
a solution.
 
I am using a software package called FSL from fmrib.ox.ac.uk. It is made to
run within cygwin on windows. It uses tcl/tk for its gui, and a problem
occurs with the GUI only with cygwin1.dll 1.5.19 and greater. 1.5.18 worked
fine. Here is the code in question.
 
A GUI is set up with a series of buttons: 
 
if { [ file exists ${FSLDIR}/tcl/fdt.tcl ] } {
 button $w.f1.fdt -text "FDT Diffusion" \
 -command { exec sh -c "${FSLDIR}/bin/Fdt$gui_ext" & }
 pack $w.f1.fdt -in $w.f1 -fill x -padx 1 -pady 1
}
 
The global variables above expand to:
${FSLDIR}  = /usr/local/fsl
$gui_ext   = _gui

so pressing the button should execute: exec sh -c /usr/local/fsl/bin/Fdt_gui
instead nothing happens.

Fdt_gui is actually a link to a file
   Fdt_gui -> Runtcl

and the code in Runtcl is: 
  
  #!/bin/sh

  # Set TCLTKSHELL \
  TCLTKSHELL=wish ; export TCLTKSHELL

  # Check for display being set \
  if [ _`uname | grep CYGWIN` = _ -a _$DISPLAY = _ ] ; then echo "DISPLAY is
not set. Please set your DISPLAY environment variable!" ; exit 1 ; fi

  # the next line restarts using wish \
  if [ _$FSLWISH = _ ] ; then echo "You need to source an FSL setup file -
either
  fsl.sh or fsl.csh in \$FSLDIR/etc/fslconf !" ; exit 1 ; else exec $FSLWISH
"$0"
  -- "$@" ; fi

  set FSLDIR $env(FSLDIR)

  set origname [ string tolower [ file tail [ info script ] ] ]

  set UNAME [ exec uname ]
  if { $UNAME == "Darwin" || [ string compare CYGWIN [ string range $UNAME 0
5 ] ]
   == 0 } {
  regsub "_gui" $origname "" origname
  }

  source ${FSLDIR}/tcl/${origname}.tcl

  exit

=
so what should happen is that it should source the .tcl file
/usr/local/fsl/tcl/fdt.tcl.

Note: all the files are present. If I type: wish /usr/local/fsl/tcl/fdt.tcl
the appropriate dialog appears.

Also, if I use an older version of cygwin (1.5.18-1) the exact same
installation of fsl with the above code runs fine. The older version of
cygwin is installed in its own directory.

Interestingly other buttons that reference actual .exe files work fine in
the new version. So if instead of Fdt_gui the line referenced a .exe file
the button works (must be an actual .exe file, changing the filename to
Fdt_gui.exe does not work).

If I try to execute the following command from the bash shell I get the
following

exec sh -c /usr/local/fsl/bin/Fdt_gui &

In the older version (1.5.18-1)
  the dialog I expect to see appears.

In the newer version (1.5.19) I see the following errors

: command not foundsr/local/fsl/bin/Fdt_gui: line 2:
': not a valid identifieri: line 4: export: `TCLTKSHELL
: command not foundFdt_gui: line 5:
/usr/local/fsl/bin/Fdt_gui: line 12: syntax error near unexpected token `('
'usr/local/fsl/bin/Fdt_gui: line 12: `set FSLDIR $env(FSLDIR)
[1]+  Exit 2  exec sh -c /usr/local/fsl/bin/Fdt_gui



Any ideas would be appreciated, and please let me know if more information
is needed.

Thanks,
Darren



--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: problem with running tcl/tk scripts

2007-01-15 Thread d-gitelman
Dave:

Thank you very much! That worked part way. 

It now properly runs this command when I call it from the command line.
exec sh -c /usr/local/fsl/bin/Fdt_gui &

However, it the buttons in the GUI still do not work.  For some reason the 
command in the button is 
not executed. The button is setup just fine but pressing it does nothing. Again 
if I substitue the
name of an actual .exe file for Fdt$gui_ext then the button works. Here is the 
button code.

if { [ file exists ${FSLDIR}/tcl/fdt.tcl ] } {
 button $w.f1.fdt -text "FDT Diffusion" \
 -command { exec sh -c "${FSLDIR}/bin/Fdt$gui_ext" & }
 pack $w.f1.fdt -in $w.f1 -fill x -padx 1 -pady 1
}

also note that getting rid of the variables ${FSLDIR} and $gui_ext so the 
command line is written
-command { exec sh -c "/usr/local/fsl/bin/Fdt_gui" & }   does not work so it's 
not a variable
expansion issue.

So based on your suggestion I then ran d2u on every text file in this 
distribution I could find and 
certainly every .tcl file. (I assume it is called as d2u name_of_file? Anyway 
it made no difference. 

I did try substituting some commands in the Runtcl file (Fdt_gui is a link to 
Runtcl) which was in
the last email. Those commands do not even get executed when the button is 
pressed so if the
command above references a script file and not a .exe file there is something 
broken in how it
handles the exec sh call. 

again, any thoughts appreciated.

Regards,
Darren

On 15 January 2007 07:04, Dave Kore wrote:
> In the older version (1.5.18-1)
>   the dialog I expect to see appears.
> 
> In the newer version (1.5.19) I see the following errors
> 
>> command not foundsr/local/fsl/bin/Fdt_gui: line 2:
> ': not a valid identifieri: line 4: export: `TCLTKSHELL
>> command not foundFdt_gui: line 5:
> /usr/local/fsl/bin/Fdt_gui: line 12: syntax error near unexpected token `('
> 'usr/local/fsl/bin/Fdt_gui: line 12: `set FSLDIR $env(FSLDIR)
> [1]+  Exit 2  exec sh -c /usr/local/fsl/bin/Fdt_gui
> 
> 
> 
> Any ideas would be appreciated, and please let me know if more information
> is needed.

  You have DOS line endings.  Try d2u on it.  This is a consequence of the
newer versions of bash, rather than anything that changed in the cygwin dll
itself.


cheers,
  DaveK



--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Download Cygwin???

2007-02-08 Thread Brian D

Hi,

  ...I live in Fox, Alaska.  High-speed internet is not an option at this point.
 Trying to install Cygwin via the usual setup.exe method fails because my
internet connection likes to have problems far too many times during a huge
download...

  Is there any way that I can d/l Cygwin, with the packages that I need, at my
workplace, then write a CD-R and take it home for installation???  Comments or
advice???

Thanks,
Brian



--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: FW: Re: [EMAIL PROTECTED]: ***MEMORY-ERROR***: emacs[5172]: GSlice: failed

2007-02-20 Thread Jan D.

Jan Djärv wrote:


Christopher Faylor wrote:


Thanks much for the details.  We do want to make things work correctly
but, if that just means some work in emacs source code, then someone who
is familiar with emacs will have to do that, i.e., someone else will
have to come up with the config.h.

OTOH, if someone could debug exactly why the error was occurring from
one of the above calls then maybe we could make cygwin work better,
too.  Again, this requires someone who has access to emacs source
and (presumably) knows how to use a debugger.


I got W32 and cygwin up on a (not so fast) spare box, so I'm looking 
in to it now.  memalign is definitely the function failing, but 
something more is going on here, I can't yet reduce this to a more 
simple case.


Will keep trying though.



It seems that when Emacs defines its own malloc and friends, memalign 
returns ENOSYS.  But emacs defines its own memalign as well.  Shouldn't 
that one be called?


   Jan D.



--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Compiling emacs 22.1 from source

2008-01-29 Thread Taras D
Hi all,

I'm trying to compile emacs 22.1 from source using Cygwin.

The install file says:

"`cd' to the directory where you unpacked Emacs and invoke the
  `configure' script:

   ./configure"

I do this, but I get the following errors:

./configure: line 12: $'\r': command not found
./configure: line 23: syntax error near unexpected token `$'in\r''
./configure: line 23: `  case `(set -o) 2>/dev/null` in
'

I searched for these errors on the internet, and found the following
(in the Cygwin FAQ):

You may get mysterious messages when bash reads your .bashrc or
.bash_profile, such as "\r command not found" (or similar). When you
get rid of empty lines, the complaints about "\r" disappears, but
probably other errors remain. What is going on? The answer may lie in
the fact that a text file (also called ASCII file) can come in two
formats: in DOS format or in UNIX format. Most editors can
automatically detect the formats and work properly in either format.
In the DOS format, a new line is represented by two characters: CR
(carriage return or ASCII code 13) and LF (line feed or ASCII code
15). In the UNIX format, a new line is represented by only one
character, LF. When your .bashrc file is read, bash thinks the extra
character is the name of a command, hence the error message. In Cygwin
or unix, you can convert a file INFILE in DOS format to a file OUTFILE
in Unix format by calling: > tr -d '\15' < INFILE > OUTFILE NOTE: If
you now compare the number of characters in INFILE and OUTFILE, you
will see that the latter has lost the correct number of characters
(i.e., the number of lines in INFILE): > wc INFILE OUTFILE

I tried this, but now get the error:

configure_dos_format: error: cannot run /bin/sh
/emacs_downloaded/emacs-22.1/config.sub

What is going wrong?

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: Compiling emacs 22.1 from source

2008-01-29 Thread Taras D
> You probably unpacked a tarball with a windows zip utility that
> "helpfully" changes the line endings on files.  Don't do that.  Use cygwin
> tools to unzip the tarball (and this topic has been in the list archives
> as well).

Correct

> By the way, any reason you're trying to compile emacs rather than using it
> pre-built?  You may also want to download the source that accompanies the
> pre-built version, since it comes with a script that takes care of all the
> unpacking and compilation for you (in fact, it was that script that the
> maintainer uses to compile the pre-built version in the cygwin distribution).
>

I'm trying to get the GUI layout of GDB working (sorry if I'm using
the terminology, I just discovered these things half a week ago).
Screenshots are found at
http://www.emacswiki.org/cgi-bin/wiki/GrandUnifiedDebugger and
http://www.linuxjournal.com/article/7876. The latter article states
that: "I describe a new mode, which I call GDB-UI, that is a part of
the next release of Emacs (21.4) and offers the GUI features of many
modern debuggers". Whenever I start gdb it creates a buffer within
emacs that looks the same as if I was using it from bash, so I'm
guessing the reason why I don't have the 'GDB-UI' layout as shown in
the images is because the emacs version I have is too old (the binary
you donwload using the cygwin setup program is version 21-2). If I'm
doing something wrong I'd love to know what.

Now make runs successfully until the following error message appears:

/usr/lib/gcc/i686-pc-cygwin/3.4.4/../../../../i686-pc-cygwin/bin/ld:
cannot find -lcurses
collect2: ld returned 1 exit status
make[1]: *** [temacs.exe] Error 1
make[1]: Leaving directory `/emacs_downloaded/emacs-22.1/src'
make: *** [src] Error 2

I looked on the internet, but there was nothing referring to lcurses
and emacs. I woul think that all of the required libraries would get
automatically included?

Taras

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



xemacs

2008-02-11 Thread Taras D
Hi everyone,

Can anyone tell me why the following has occurred.

When I first installed cygwin, I pretty much just installed xemacs (no
emacs and a whole bunch of other stuff). Xemacs could be started from
the bash script (black background) with the command 'xemacs &'. It
would start in a new window with a white background.

Now that I have installed a whole bunch of other cygwin things:

1) I find I need to run startxwin.sh, then type 'xemacs &' in the
shell with a white background (no longer runs from the black
background)
2) xemacs now starts with a grey bacground (?!)

How come this has changed? Is it a different version of xemacs?

Thanks all

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Cygwin and lz/lza running out of memory?

2013-09-22 Thread Matt D.
Depending on the options I choose, I keep running into lz/lzma 
reporting: "ERROR: Can't allocate required memory!".


This can occur before or during compression. The lz/lza process tends to 
stop after gaining about 400MB on the process; then it exits with this 
error. The problem does not appear to be how much available memory I 
have but rather q question of why the process can't seem to allocate it.


Any advice?


Matt D.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Cygwin and lz/lza running out of memory?

2013-09-22 Thread Matt D.
The link sounded promising but no matter how high I set it (tried up to 
8192), I get the same error, even when bringing down the compression 
ratio a bit.


I attempted to increase the cygwin heap on both /usr/lib/p7zip/7z.exe 
and 7za.exe.



Matt D.

On 9/22/2013 10:25 PM, Larry Hall (Cygwin) wrote:

On 9/22/2013 5:30 PM, Matt D. wrote:

Depending on the options I choose, I keep running into lz/lzma reporting:
"ERROR: Can't allocate required memory!".

This can occur before or during compression. The lz/lza process tends to
stop after gaining about 400MB on the process; then it exits with this
error. The problem does not appear to be how much available memory I have
but rather q question of why the process can't seem to allocate it.

Any advice?


Take a look at this thread and see if this leads you to an answer.

<http://cygwin.com/ml/cygwin/2012-11/msg00104.html>

If not, please follow the problem-reporting guidelines found here:


Problem reports:   http://cygwin.com/problems.html





--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Run bash script in cmd with cygwin

2013-09-24 Thread Matt D.

Try adding this to your script:

cd /cygdrive/d/path/to/dir;`for file..


Matt D.

On 9/24/2013 5:43 PM, Ulrich Pogson wrote:

Hello

I would like to run this script `for file in `find . -name "*.po"` ;
do msgfmt -o ${file/.po/.mo} $file ; done` in windows cmd. The script
need to run in a different folder. I have been able to run it though
cygwin but want to integrate it with another system where it will be
run through cmd.

C:\cygwin\bin
D:\path\to\dir

How can I do this?

Thanks.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple





--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



vi stealing SYSTEM-owned permissions and ownership

2013-11-02 Thread D. Boland
Hi group,

I'm a Linux teacher at a school for vocational education in the Netherlands. 
I use Cyqwin to help my students overcome their fear of the command line by 
showing them their Windows systems through the eyes of Linux.

I had them install Apache and then configure it in Cygwin using vi.

As of Windows 8, the Apache installation sometimes fails, because of permission
issues. Installing "As administrator" solves the problem. This is fine 
with me because in other Linuxes, Apache is installed as root by default.

After installation, permissions in the Apache "conf" directory look like this:

drwx--+ 1 SYSTEM SYSTEM 0 28 okt 20:43 .
drwx--+ 1 SYSTEM SYSTEM 0  2 nov 13:10 ..
-rwx--+ 1 SYSTEM SYSTEM 35142 26 okt 18:07 httpd.conf
-rwx--+ 1 SYSTEM SYSTEM 34770  7 okt 23:29 httpd.default.conf
-rwx--+ 1 SYSTEM SYSTEM 13340  3 okt 07:59 magic
-rwx--+ 1 SYSTEM SYSTEM 13340 21 nov  2004 magic.default
-rwx--+ 1 SYSTEM SYSTEM 54599  3 okt 07:59 mime.types
-rwx--+ 1 SYSTEM SYSTEM 54599 17 mrt  2012 mime.types.default
-rwx--+ 1 SYSTEM SYSTEM  9390  5 feb  2013 openssl.cnf
-rwx--+ 1 SYSTEM SYSTEM 11050  3 okt 07:59 ssl.conf
-rwx--+ 1 SYSTEM SYSTEM 11030  7 okt 23:29 ssl.default.conf

To emulate the Unix permissions model, I had my students add a group in Windows,
named "apache", making themselves a member and then import it using the mkgroup 
command.

After a chgrp and chmod on the entire Apache folder, the "conf" directory looks 
like this:

drwxrwx---+ 1 SYSTEM apache 0 28 okt 20:43 .
drwxrwx---+ 1 SYSTEM apache 0  2 nov 13:10 ..
-rwxrwx---+ 1 SYSTEM apache 35142 26 okt 18:07 httpd.conf
-rwxrwx---+ 1 SYSTEM apache 34770  7 okt 23:29 httpd.default.conf
-rwxrwx---+ 1 SYSTEM apache 13340  3 okt 07:59 magic
-rwxrwx---+ 1 SYSTEM apache 13340 21 nov  2004 magic.default
-rwxrwx---+ 1 SYSTEM apache 54599  3 okt 07:59 mime.types
-rwxrwx---+ 1 SYSTEM apache 54599 17 mrt  2012 mime.types.default
-rwxrwx---+ 1 SYSTEM apache  9390  5 feb  2013 openssl.cnf
-rwxrwx---+ 1 SYSTEM apache 11050  3 okt 07:59 ssl.conf
-rwxrwx---+ 1 SYSTEM apache 11030  7 okt 23:29 ssl.default.conf

My students can now administer Apache without running Cygwin "As administrator".
Also, this is extremely useful in real-time business situations. It enables my 
students to grant Apache admin permissions to other users by putting them in 
the apache group, without giving them full admin access on the entire system.

But here's the problem. After editing the httpd.conf file with vi, the 
permissions 
on the "httpd.conf" file are changed to:

--+ 1 Daniel None   35142  2 nov 13:20 httpd.conf

This should not be. I tested this on my RedHat and OpenBSD systems, and there 
are 
no changes in ownership or permissions after editing with vi.

After fiddling with chown, chgrp, chmod, getfacl, setfacl and icacl for a few 
hours, I finally installed nano. Nano behaved. It did not alter anything except
the contents of the file.

But I want my students to learn vi, so having them install nano is not an 
option. 

I think the problem is vi. Vi deletes the original file and creates a new one 
with
the changed contents, without resetting the original ownership and permissions. 
See 
also this post:

http://unix.stackexchange.com/questions/58880/how-does-vim-steal-root-owned-files

Can somebody shed some light on this?

Meanwhile, I accidentally found sort of a solution: deleting the file without 
write
permissions on the containing folder, restores the permissions set by 
Administrator.

As Administrator:
chmod 0700 .
touch test.txt
chown SYSTEM:apache test.txt
chmod 0770 test.txt

Results in:

-rwxrwx---+ 1 SYSTEM apache 0  2 nov 13:26 test.txt

As "normal" user:
Edit the file with vi. After, permissions will look like:

--+ 1 Daniel None   9  2 nov 13:29 test.txt

$ getfacl.exe test.txt
# file: test.txt
# owner: Daniel
# group: None
user::---
group::---
group:SYSTEM:rwx
group:Administrators:rwx
group:Gebruikers:r-x
group:apache:rwx
mask:rwx
other:---

To "solve" this, simply delete the file:

rm test.txt

The file is not deleted because of 0700 on the containing folder. But the 
original 
permissions, set by Admin are restored!!

-rwxrwx---+ 1 SYSTEM apache 9  2 nov 13:29 test.txt

$ getfacl.exe test.txt
# file: test.txt
# owner: SYSTEM
# group: apache
user::rwx
group::rwx
group:Administrators:rwx
group:Gebruikers:r-x
mask:rwx
other:---


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: vi stealing SYSTEM-owned permissions and ownership

2013-11-02 Thread D. Boland
"Brian S. Wilson" wrote:
> 
> > I'm a Linux teacher at a school for vocational education in the
> Netherlands.
> > I use Cyqwin to help my students overcome their fear of the command line
> by showing them their Windows systems through the eyes of Linux.
> ...
> > After a chgrp and chmod on the entire Apache folder, the "conf" directory
> looks like this:
> >
> > drwxrwx---+ 1 SYSTEM apache 0 28 okt 20:43 .
> > drwxrwx---+ 1 SYSTEM apache 0  2 nov 13:10 ..
> > -rwxrwx---+ 1 SYSTEM apache 35142 26 okt 18:07 httpd.conf
> > -rwxrwx---+ 1 SYSTEM apache 34770  7 okt 23:29 httpd.default.conf
> > -rwxrwx---+ 1 SYSTEM apache 13340  3 okt 07:59 magic
> > -rwxrwx---+ 1 SYSTEM apache 13340 21 nov  2004 magic.default
> > -rwxrwx---+ 1 SYSTEM apache 54599  3 okt 07:59 mime.types
> > -rwxrwx---+ 1 SYSTEM apache 54599 17 mrt  2012 mime.types.default
> > -rwxrwx---+ 1 SYSTEM apache  9390  5 feb  2013 openssl.cnf
> > -rwxrwx---+ 1 SYSTEM apache 11050  3 okt 07:59 ssl.conf
> > -rwxrwx---+ 1 SYSTEM apache 11030  7 okt 23:29 ssl.default.conf
> >
> >My students can now administer Apache without running Cygwin "As
> administrator".
> 
> Your statement may not be quite accurate.  The Cygwin Apache instance
> appears to be running as the "SYSTEM" user since that is the file owner, but
> your students can administer the files because they are members of the
> "apache" group.  I can't really tell which user id is running your Apache
> process because I don't know how you are actually starting the Apache
> process.  Most production Apache instances do not run as the "root" user
> since this is a security risk.
> 
> If my guess about the Apache process owner is correct, please make your
> students aware that if someone hacks their Cygwin Apache servers, the hacker
> may gain the same user access rights as the user id actually running the
> Apache process.  The Apache process owner would normally be a unique user
> account with no login or access privileges to protect the server from
> successful attacks (just because your Apache files are owned by "SYSTEM",
> Apache could be started under another, less privileged, user id for better
> protection; but it is common practice to have the file owner also be the
> user id that normally executes the file).  It is common to see a "nobody"
> user as the owner of Apache in production systems.
> 
> I've spent some time over several years trying to figure out how to get
> Apache working as a "nobody" user under Cygwin.  I've never succeeded in
> getting it to work properly, and my comments to this board have not yielded
> an answered.  I don't think it is possible to make Apache work this way
> under Cygwin, but your students should be made aware of this difference.
> 
> If anyone is aware of how to get Apache working using a restricted "nobody"
> user id under Cygwin, please respond (or start a new thread).

Your concern is very real, I thought about that also.

First, in my student-setup, Apache is not running under Cygwin. I used the 
.msi distribution, available on the Apache website. This installs Apache as a 
native Windows Service, and it can be configured using the Windows Services 
Control Panel.

As to running as the SYSTEM user, I agree with you. In Linux, Apache is started
by root, and then immediately switches to the "nobody" user, so it is unable 
to touch or even see the outside of its ServerRoot.

In Windows, this mechanism does not work. That is why the "User" and "Group"
directives are left out of the httpd.conf file in the Windows distribution.

I now have Apache running under the username "Daemon" which I created using 
the standard Windows "Users" Control Panel. I put this user in my "apache" 
group like this:

net localgroup apache Daemon /add

The tricky part was assigning the following permissions to the "Daemon"
user:

* Log on as a service
* Act as part of the operating system

I did this in the "Local Security Settings" Control Panel, which can 
be found in the "System Administration" Control Panel. It is also possible to 
bring it up by running "secpol.msc" from the Start menu.

Finally, I configured Apache to run as user "Daemon" in the "Services" control 
panel (services.msc).

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: vi stealing SYSTEM-owned permissions and ownership

2013-11-03 Thread D. Boland
Andrey Repin wrote:
> 
> Greetings, D. Boland!
> 
> Your main problem is that you are trying to break into native Windows
> ACL system with Cygwin tools. And not only that, you also trying to
> wrest native ACLs into POSIX permissions, and expect native applications to
> work fine afterward.
> Which can be done theoretically, but in reality is a real big headache to
> maintain.

You are speaking of Cygwin as if it's some kind of quick hack. This is not the 
case.
Most of the tools are of the GNU software collection, which is high quality
software. ACL is also available on other Linux flavours, and they don't have to
"wrest" it into POSIX.

Also, one could say that ACL is a superset of the POSIX model. It uses POSIX's 
idea
of users, groups and others, but then offers the posibility to add more users 
and
groups for more elaborate schemes. The headache starts when one actually starts
using these extra posibilities.

> 
> If you truly want to show your students their Windows systems from the command
> line, I suggest you learn Windows command line.
> If not very robust, it is nonetheless rich, and allow for many operations
> normally performed from GUI, and some operations, that can not be done from
> GUI, either without much complication or at all.
> In the case mentioned below, the "net" tool should come in handy. As well
> as "sc" tool.
> 

I could just give my students an iMac, but these are not used in IT production
infrastructures. Windows (business/government) and Linux/Unix (ISP's) are.

The Windows command line is frustrating to work on. For instance, their
implementation of autocompleting with the tab-key sucks. In stead of really
simplifying and improving on DOS, MS comes up with more weird tools like 
PowerShell.
Now you have to be a programmer to use the command-line.

> Also, forcing someone to use vi over more sane editors is a torture which no
> one deserve.
> 

Haha, yes. But if my students have to administer remote production-machines, 
most of
the time they have no other option. I want them to succeed where others fail.

> Sorry for my terrible english...

No problem.

Sincerely,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Some first questions.

2013-11-03 Thread D. Boland
Gert Koefoed Andersen wrote:
> 
> Hello list.
> 
> I have some first questions for cygwin works on windows 7 by compile sources
> I normally just fine compile on my linux systems but not like to compile
> well and by cygwin.
> The sources I trying to compile is been packed on linux with tar archiwing
> program so I can get the sources over to windows 7 and cygwin.
> 
> So it is then this then.
> 1. where is the best place to unpack the sources for compile by cygwin.
>My windows cygwin is installed on c:\cygwin and by installing cygwin is
> the cygwin download sources been put at k:\cygwinsrc.
> 2. if the extra sources is best to be places at k:\cygwin, then is it then
> best to handle them for cygwin ?
> 
> 3. Then is it that - the sources have makefiles .cyg and other compilers +
> some main configs like Makefile and huskymak.cfg.
> When I have copied the file makefile.cyg to makefile.cfg and then have this
> file in the main home dir for example - \...\husky\smapi\ and then is got in
> to \smapi source dir and then run make to compile the sources for smapi goes
> it fine to I getting a error of gcc -mno-cygwin and then error 2 of it not
> can find some file it should make and when I checking out for the file is it
> where it should be by not compile to make a .o files for more compile
> finish.
> 
> Regards,
> Gert

There is a standard location for sources, as is for libraries and includes. In
Cygwin it's /usr/src. In some other Linuxes it's /usr/local/src.

I have been compiling lots of source distributions over the years. I am not 
aware
that you have to move or copy Makefiles. As far as I know you just need to:

cd /usr/src/yournewapp
./configure
make
make install

With the last command, all configuration files are automatically put in the 
right
folders.

HTH,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: SV: Some first questions.

2013-11-04 Thread D. Boland
Gert Koefoed Andersen wrote:
> 
> I have compiled lot of sources on linux systems and got now errors here but
> on cygwin on my windows 7 32bit things not like to work for me.
> What I ever I have done for it, like:
> Cd /cygdrive/k/huskysrc/smapi
> Or copied it to /src/src/huskysrc
> Cd /usr/src/huskysrc/smapi
> Make
> Make install
> And it ends by error for ld not found some files and others.
> Output from cygwin terminal by the error:
> gcc   1stchar.o   -o 1stchar
> /usr/lib/gcc/i686-pc-cygwin/4.7.3/../../../libcygwin.a(libcmain.o): I
> funktionen "main":
> /usr/src/debug/cygwin-1.7.25-1/winsup/cygwin/lib/libcmain.c:39: undefined
> reference to `WinMain@16'
> collect2: fejl: ld returnerede afslutningskoden 1
> : recipe for target '1stchar' failed
> make: *** [1stchar] Error 1

I know this error (unknown reference to WinMain). You get it when you try to 
compile
a module. A module has no "main" function (like a program has). You need to 
compile
it with option -c. Like:

gcc -c lstchar.o -o lstchar

Maybe you can add the extra option in the Makefile? I must say, this kind of 
error
occurs only in poorly made distributions, so this will be a difficult build...

HTH,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: vi stealing SYSTEM-owned permissions and ownership

2013-11-04 Thread D. Boland
Thanks for the input, guys.

I think I have new information on the stealing of ownership. Below test has been
performed on the Apache folder, placed in the Windows Program Files folder by 
the
Apache msi installer:

"/cygdrive/c/Program Files (x86)/Apache Group/Apache2/"

But if I perform the same test in my Cygwin home directory, vi behaves 
beautifully.

So, I was thinking this difference must be related to the Windows ACL 
assigments on
the "Program Files" folder.
Maybe vi is confused within this folder, because it is a system folder which
recursively forces extra permissions on its subfolders.

This means I could solve the issue by telling the Apache installer to put the 
files
in a "neutral" folder, like:

/cygdrive/c/apache/

But then the question would stay, nagging in my mind: why would vi be confused 
and
nano (and notepad.exe by the way) not? 

Also, Larry Hall pointed out:

"When I looked at the information provided, I was left with the distinct 
impression
that the 'vi' in use was not a Cygwin version.  The fact that the file edited 
with
it had no POSIX permissions was a red flag for me."

I initially used the original version of "vi" that came with the standard 
distro of
Cygwin. When I noticed the problem, I installed "vim" and went on, testing with
that.

I really, really would like to persue this issue some more in the direction 
Larry
points to.

Cincerely,
Daniel


"D. Boland" wrote:
> 
> Meanwhile, I accidentally found sort of a solution: deleting the file without 
> write
> permissions on the containing folder, restores the permissions set by 
> Administrator.
> 
> As Administrator:
> chmod 0700 .
> touch test.txt
> chown SYSTEM:apache test.txt
> chmod 0770 test.txt
> 
> Results in:
> 
> -rwxrwx---+ 1 SYSTEM apache 0  2 nov 13:26 test.txt
> 
> As "normal" user:
> Edit the file with vi. After, permissions will look like:
> 
> --+ 1 Daniel None   9  2 nov 13:29 test.txt
> 
> $ getfacl.exe test.txt
> # file: test.txt
> # owner: Daniel
> # group: None
> user::---
> group::---
> group:SYSTEM:rwx
> group:Administrators:rwx
> group:Gebruikers:r-x
> group:apache:rwx
> mask:rwx
> other:---
> 
> To "solve" this, simply delete the file:
> 
> rm test.txt
> 
> The file is not deleted because of 0700 on the containing folder. But the 
> original
> permissions, set by Admin are restored!!
> 
> -rwxrwx---+ 1 SYSTEM apache 9  2 nov 13:29 test.txt
> 
> $ getfacl.exe test.txt
> # file: test.txt
> # owner: SYSTEM
> # group: apache
> user::rwx
> group::rwx
> group:Administrators:rwx
> group:Gebruikers:r-x
> mask:rwx
> other:---


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: vi stealing SYSTEM-owned permissions and ownership

2013-11-08 Thread D. Boland
Achim Gratz wrote:
> 
> D. Boland writes:
> > I think I have new information on the stealing of ownership. Below test has 
> > been
> > performed on the Apache folder, placed in the Windows Program Files folder 
> > by the
> > Apache msi installer:
> >
> > "/cygdrive/c/Program Files (x86)/Apache Group/Apache2/"
> >
> > But if I perform the same test in my Cygwin home directory, vi behaves 
> > beautifully.
> >
> > So, I was thinking this difference must be related to the Windows ACL 
> > assigments on
> > the "Program Files" folder.
> 
> If you are operating as a normal user on this folder, you aren't
> actually editing the files you think you see there, the whole contents
> is virtualized by UAC and redirected to your own personal copy on edit.
> If you want to keep your sanity, do not place anything that you intend
> to edit / change as a normal user into system directories on Win7 (that
> includes Cygwin itself).
> 
> http://msdn.microsoft.com/en-us/library/bb756960.aspx
> 
> Regards,
> Achim.

Thanks for this input. So Apache should be put in a folder, outside the windows
special folders, like:

/cygdrive/c/Apache2

This seems to be the default for most open source distributions: cygwin, perl, 
msys,
mingw, even xampp. I am still wondering, though, why the Apache Foundation 
wants it
in the "Program Files" folder.

You all are right in saying that the Apache .msi is a "hybrid" configuration. I
guess, maybe it's better to just use the Apache installation provided by 
CygWin...

I also found out about "cygrunsrv". This makes Linux daemons run Windows-native.
Very nice.

Thanks again for your input,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: SV: Some first questions.

2013-11-08 Thread D. Boland
Mr. Anderson,

Sorry, I couldn't resist. I saw the Matrix movie recently ;-)

Thanks for the extended output you sent me privately, but maybe it's better to 
keep
this public, because others want to know of your progress, too.

I wanted to try to compile the Husky software myself. So I went to the Husky
sourcefourge page. I downloaded the 1.9-current file:

husky-all-1.9-w32mvcdll-20131030.zip

When I unzipped it to my /usr/src/husky-all-1.9 folder, I saw that it where all
precompiled win32 binaries. Why do you need to compile the sources?

Greetings,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: SV: SV: Some first questions.

2013-11-09 Thread D. Boland
Dear Gert,

I'm sorry, but this is too much for me. I don't have that much time.

I suspect that the build script for Cygwin contains a bug, because of the 
"undefined
reference to `WinMain@16'" error. Impossible to solve without changing it.

What about contacting the author of the build scripts?

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: vi stealing SYSTEM-owned permissions and ownership

2013-11-27 Thread D. Boland
Again, thanks for the input. I's now about three weeks later. I made all of my
students re-install Apache in:

/cygdrive/c/Apache2

and made them symlink this location on:

/usr/local/apache

For me, Achim Gratz's comment on the "Program Files" folder made perfect sense:

>If you are operating as a normal user on this folder, you aren't
>actually editing the files you think you see there, the whole contents
>is virtualized by UAC and redirected to your own personal copy on edit.
>If you want to keep your sanity, do not place anything that you intend
>to edit / change as a normal user into system directories on Win7 (that
>includes Cygwin itself).

I am also a software developer, and most of my releases are installed on MS 
Citrix
servers for remote desktop connections. I initially made the mistake to put all
files in the "Programs Files" folder, including the executable, the database and
configuration files (.ini).

This works fine on a stand-alone XP/Win7 PC, but in a Citrix environment this
crashes the application, because of lacking write permissions on the .ini files.
Then I found out about the "Application Data" folder. Releasing my database and 
.ini
files to that folder solved the problem. MS has an article about it:

http://msdn.microsoft.com/en-us/library/windows/apps/jj553522.aspx

This would mean that in order to install Windows native and avoid 
virtualization of
the conf files the Apache Group should release Apache for Windows into both 
"Program
Files" and "Application Data":

Program Files
-
bin
error
icons
include
lib
manual
modules

Application Data

cgi-bin
conf
htdocs
logs
proxy

Thanks again for the comments,
Daniel

-- 
Sent by my Altair 8800


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Cygrunsrv crashes when setting STDERR to /dev/null

2014-03-02 Thread D. Boland
Hi group,

I have Apache running via cygrunsrv on a WinXP system. It works fine. Apache can
even do a setuid on startup, so a 'ps -ef' looks like this:

 UID PIDPPID  TTYSTIME COMMAND
   httpd16041308 ?14:26:47 /usr/local/apache/bin/httpd
  SYSTEM13081400 ?14:26:47 /usr/local/apache/bin/httpd
   httpd 8961308 ?14:26:47 /usr/local/apache/bin/httpd
   httpd 5361308 ?14:26:47 /usr/local/apache/bin/httpd
   httpd 6121308 ?14:26:47 /usr/local/apache/bin/httpd
   httpd 5601308 ?14:26:47 /usr/local/apache/bin/httpd

As you can see, I have it running as 'httpd', an unprivileged user, which I 
created
without password and removed from the 'Users' group, so it cannot login.

Unfortunately, this doesn't work on a Win7 system. If I try the same 
configuration
in a Win7 system, the following message is logged in logs/error_log and the 
Service
won't start:

[alert] (1)Operation not permitted: setuid: unable to change to uid: 1006

So, I set a password for the 'httpd' user and configured the Service to log on 
as
that user. This works, but now I cannot use cygrunsrv's -1 or -2 switches for
redirecting STDOUT and STDERR anymore.

cygrunsrv crashes if I set either one of them to /dev/null. If I unset them, it
works.

Can anybody help?

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Minires truncates host names

2014-07-05 Thread D. Boland
Hi Group,

I finally got Sendmail ported to Cygwin. But when looking up valid hostnames 
from
sender addresses, Minires fails. Here's the output, testing one of Sendmails' 
rules.

$ echo "check_mail dan...@cygwin.com" | /usr/sbin/sendmail -d8.20 -bt
readcf: option TrustedUser may cause problems on systems
which do not support fchown() if UseMSP is not set.
ADDRESS TEST MODE (ruleset 3 NOT automatically invoked)
Enter  
> check_mail input: daniel @ cygwin . com
Basic_check_mail   input: daniel @ cygwin . com
tls_client input: $| MAIL
TLS_connection input:
TLS_connection   returns:
tls_client   returns:
CanonAddr  input: < daniel @ cygwin . com >
canonify   input: < daniel @ cygwin . com >
Canonify2  input: daniel < @ cygwin . com >
dns_getcanonname(cygwin.com, trymx=1)
dns_getcanonname: trying cygwin.com. (A)
Minires: query "cygwin.co." type 1
Minires: DnsQuery: 9003 (Windows)
NO: errno=0, h_errno=1
Canonify2returns: daniel < @ cygwin . com >
canonify returns: daniel < @ cygwin . com >
Parse0 input: daniel < @ cygwin . com >
Parse0   returns: daniel < @ cygwin . com >
CanonAddrreturns: daniel < @ cygwin . com >
Basic_check_mail returns: $# error $@ 5 . 1 . 8 $: "553 Domain of sender 
address " "
does not exist"
check_mail   returns: $# error $@ 5 . 1 . 8 $: "553 Domain of sender 
address " "
does not exist"
>

As can be seen, Minires queries "cygwin.co.", not "cygwin.com." Is this a bug? 
Is
there a way to test Minires lookups outside of Sendmail?

Greetings,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Minires truncates host names

2014-07-06 Thread D. Boland
"Pierre A. Humblet" wrote:
> To me it looks like the string was already truncated when it was passed to
> the function.
> 
> You can test e.g. by using exim -d+resolver  -bt   dan...@cygwin.com
> 
> It's wonderful that you got sendmail to work.
> 
> Pierre
> 

Thanks for the swift reply!

I looked at Sendmails' source code. Here's the snippet which produces the output
from my first email. It's taken from the file sendmail/domain.c:

sm_dprintf("dns_getcanonname: trying %s.%s (%s)\n",
host, *dp,
# if NETINET6
qtype == T_ ? "" :
# endif /* NETINET6 */
qtype == T_A ? "A" :
qtype == T_MX ? "MX" :
"???");
errno = 0;
ret = res_querydomain(host, *dp, C_IN, qtype,
  answer.qb2, sizeof(answer.qb2));


As you can see, it first prints the host to be looked up, and then passes the 
string
unaltered to res_querydomain.

I will create a source release, so it can be tested.

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: rebaseall breaks some packages(?)

2014-07-06 Thread D. Boland
Hi Katsumi,

Katsumi Yamaoka wrote:

> However, those reinstallations cause some other programs to not
> work.  For those other programs, rebaseall does help.  Though it
> breaks bzr, emacs-w3m, etc. again.  It's annoying.
> 
> Thanks in advance for your help.
> Regards,

I agree. It's annoying. See this post also:

http://cygwin.com/ml/cygwin/2009-11/msg00894.html

I'm a developer of Windows software for 15 years now, and my clients never had 
to
rebase my binaries.

I'm also a Linux teacher and I use Cygwin in class. My students (100+) 
repeatedly
got these errors, so I switched to an improved version of apt-cyg, which does 
not
rebase. I'm a happy teacher now.

What's the deal with this "rebasing" anyway? Every compiler has a built-in 
mechanism
to create unique offsets. Windows itself also rebases binaries at load-time. 

On the other hand, why not rebase at compile-time? Rebasing should not be the
responsibility of the user, but of the developer. See this article:

http://harshdeep.wordpress.com/2007/05/14/thou-shalt-rebase-thy-dll/

Hmm.. This turned out to be a rant. I'm sorry for hijacking your thread.

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Minires truncates host names

2014-07-06 Thread D. Boland
Hi Pierre,

"Pierre A. Humblet" wrote:
> 
> You are right, there is a bug in res_querydomain,
> Line 737 *(ptr++ - 1) = '.';   should be
> *ptr++ = '.';
> 
> I would also add a debug printf at the top of the function:
> DPRINTF(statp->options & RES_DEBUG, "querydomain \"%s\"  \"%s\" type %d\n",
> Name, DomName, Type);
> 
> Unfortunately I am not setup to build Cygwin so I can't test the above nor
> submit a proper patch.

I downloaded the source code from your site:

ftp://ftp.franken.de/pub/support/win32/develop/gnuwin32/cygwin/porters/Humblet_Pierre_A/V1.5/minires-0.97-src.tar.gz

After a 'make', I get multiple warnings and errors, for example:

resolver.h:48:6: fout: conflicting types for `dprintf´
 void dprintf(char * format, ...);
  ^
In file included from /usr/include/string.h:10:0,
 from resolver.h:16,
 from minires.c:14:
/usr/include/stdio.h:337:5: note: previous declaration of `dprintf´ was here
 int _EXFUN(dprintf, (int, const char *__restrict, ...)
 ^

Looks like the dprintf function is already defined in stdio.h. Are you using 
gcc?

Greetings,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: using make without cygwin terminal

2014-07-10 Thread Matt D.

Rob,

You need to setup your environment paths to include both the compiler's 
include and libs directories as well as the targeted platform sdk, if 
you're using one.


I use a custom tool chain with Cygwin/GNU Make in my build system with 
support for every version of Visual Studio, including 6.


Here is an example of the required paths:

Includes:
vs6/vc98/include
vs6/vc98/mfc/include
vs6/vc98/atl/include

Libs:
vs6/vc98/lib
vs6/vc98/mfc/lib

Visual Studio 6 is compatible with the Windows platform SDK up to 
"Windows Server 2003 R2 Platform SDK", but you shouldn't need it.


Your shell environment will need to be setup for both the compiler 
(cl.exe) and the linker (link.exe). See here:


http://msdn.microsoft.com/en-us/library/aa236630(v=vs.60).aspx
http://msdn.microsoft.com/en-us/library/aa270757(v=vs.60).aspx


Matt D.

On 7/10/2014 6:14 PM, Robert Pendell wrote:

On Thu, Jul 10, 2014 at 12:46 PM, Okan Erat wrote:

Dear Cygwin users,

I am trying to compile a project using VS6 compiler and makefiles
generated by imake.
When i run make from cygwin terminal it compiles everything without any problem.
However if i run make from windows terminal (c:/cygwin/bin is already in Path)
VS6 complains about various problems.
  such as:

winbase.h(1011) : error C2733: second C linkage of overloaded function
'InterlockedIncrement' not allowed

mswsock.h(69) : error C2065: 'SOCKET' : undeclared identifier

winsock2.h(85) : error C2378: 'SOCKET' : redefinition; symbol cannot
be overloaded with a typedef

Why make works with cygwin terminal but not with windows terminal.

Thanks for your answers


Those errors are not coming from cygwin make.  That's coming from VS6
make.  Cygwin make doesn't have errors formatted that way.

With that in mind Visual Studio is a Microsoft product and not really
supported here.

Robert Pendell
A perfect world is one of chaos.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple





--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Minires truncates host names

2014-07-10 Thread D. Boland
Hi Corinna,

Corinna Vinschen wrote:
> 
> I've checked that in.  I also changed the debug output to print
> "Resolv" instead of "Minires" to make sure that people don't think
> they are stil using the external Minres lib.
> 

How can I test the new code? I've tried updating with the Cygwin install 
program,
but the error is still there.

$ uname -a
CYGWIN_NT-5.1 dimension 1.7.30(0.272/5/3) 2014-05-23 10:36 i686 Cygwin

Also, I'm afraid I'm not done yet. Sendmail passes the dot as the root domain, 
which
I think is legitimate:

res_querydomain("cygwin.com", ".", ...

Is there a way for me to test the resolver code?

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Minires truncates host names

2014-07-17 Thread D. Boland
Hi Pierre,

"Pierre A. Humblet" wrote:
> 
> You are right, there is a bug in res_querydomain,
> Line 737 *(ptr++ - 1) = '.';   should be
> *ptr++ = '.';
> 
> I would also add a debug printf at the top of the function:
> DPRINTF(statp->options & RES_DEBUG, "querydomain \"%s\"  \"%s\" type %d\n",
> Name, DomName, Type);
> 
> Unfortunately I am not setup to build Cygwin so I can't test the above nor
> submit a proper patch.

Just letting you know how it went with the Resolver (miniedit). The error, 
pointed
out by you, solved the problem.

Now I have an even bigger problem. Sendmail works perfectly. But only on my XP
machine. As of Windows Vista, MS decided to remove certain privileges from the
SYSTEM user.

As a consequence, SYSTEM is no longer able to perform the 'setuid' function. 
This is
very much needed, since local mail has to be delivered by a mail delivery agent,
like procmail, running under the recipient's credentials.


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Minires truncates host names

2014-07-17 Thread D. Boland
Hi Corinna,

Corinna Vinschen wrote:
> 
> On Jul 17 20:14, D. Boland wrote:
> > Hi Pierre,
> >
> > "Pierre A. Humblet" wrote:
> > >
> > > You are right, there is a bug in res_querydomain,
> > > Line 737 *(ptr++ - 1) = '.';   should be
> > > *ptr++ = '.';
> > >
> > > I would also add a debug printf at the top of the function:
> > > DPRINTF(statp->options & RES_DEBUG, "querydomain \"%s\"  \"%s\" type 
> > > %d\n",
> > > Name, DomName, Type);
> > >
> > > Unfortunately I am not setup to build Cygwin so I can't test the above nor
> > > submit a proper patch.
> >
> > Just letting you know how it went with the Resolver (miniedit). The error, 
> > pointed
> > out by you, solved the problem.
> 
> Did you read my previous reply?  Do *not* use the minres lib.  Use the
> Cygwin resolver.  There's no minires lib on 64 bit anymore and the 32
> bit runtime minres is only maintained for backward compatibility.

Yes, I read it. I just don't like to swap my current Cygwin DLL. I will test it
proper on a fresh Cygwin system on another computer. When will the fix be 
released?

> > Now I have an even bigger problem. Sendmail works perfectly. But only on my 
> > XP
> > machine. As of Windows Vista, MS decided to remove certain privileges from 
> > the
> > SYSTEM user.
> 
> You might have to read the user's manual in the long run ;)
> 
> https://cygwin.com/cygwin-ug-net/ntsec.html#ntsec-setuid-overview

I did read it. Very well written, I might add. It looked very complicated at 
first
but when I read it, it made my problem very clear.

> Other services are set up so that they use another account called
> cyg_server.  See, for instance, how ssh-host-config helps an admin to
> set this up.  The csih package helper script is lending you a hand when
> creating such service installer scripts.  See also
> 
> https://cygwin.com/faq/faq.html#faq.using.sshd-in-domain

I must say, I am not a big fan of this csih thang. It totally obfuscates what I 
am
doing with my Cygwin server as an administrator. Also, it creates the 
"cyg_server"
user, which just mimicks what the SYSTEM user used to do. Maybe it should have 
been
called "root"?

The SYSTEM user was/is also regarded as the root user by other softwares from 
the
Unix world. It's in the procmail source code (#define ROOT_uid 18).

I searched for MS's position on this issue. I found this article:

http://technet.microsoft.com/en-us/library/bb457125.aspx

In the section about the SeTcbPrivilege, which the "cyg_server" user needs to 
log in
as another user, it reads:

-
The default settings are taken from the Windows XP Professional Local Computer
policy.

Act as part of the operating system (SeTcbPrivilege)

Allows a process to assume the identity of any user and thus gain access to the
resources that the user is authorized to access. Typically, only low-level
authentication services require this privilege.

Default setting: Not assigned.

Note that potential access is not limited to what is associated with the user by
default; the calling process might request that arbitrary additional privileges 
be
added to the access token. The calling process might also build an access token 
that
does not provide a primary identity for tracking events in the audit log.

When a service requires this privilege, configure the service to log on using 
the
Local System account, which has the privilege inherently. Do not create a 
separate
account and assign the privilege to it.
-

I cannot believe that MS just disabled this privilege in the newer Windows 
versions,
without providing an alternative. So now I'm trying the LocalService user...

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Minires truncates host names

2014-07-20 Thread D. Boland
Hi Corinna,

Corinna Vinschen wrote:
> 
> Hi Daniel,
> 
> On Jul 17 22:29, D. Boland wrote:
> > Hi Corinna,
> >
> > Corinna Vinschen wrote:
> > >
> > > On Jul 17 20:14, D. Boland wrote:
> > > > Just letting you know how it went with the Resolver (miniedit). The 
> > > > error, pointed
> > > > out by you, solved the problem.
> > >
> > > Did you read my previous reply?  Do *not* use the minres lib.  Use the
> > > Cygwin resolver.  There's no minires lib on 64 bit anymore and the 32
> > > bit runtime minres is only maintained for backward compatibility.
> >
> > Yes, I read it. I just don't like to swap my current Cygwin DLL. I will 
> > test it
> > proper on a fresh Cygwin system on another computer. When will the fix be 
> > released?
> 
> With 1.7.31 in the next few days.  But there are still the developer
> snapshots for testing.  Here's the deal: If you test a developer
> snapshot you can make sure that the next release will fix the problem.
> If you don't test the snapshot you won't have that privilege and the
> functionality will still be broken up to the next release.  Simple.
> 

Ok, I put in the new Cygwin1.dll from the latest 32bit developer snapshot:

$ uname -a
CYGWIN_NT-5.1 dimension 1.7.31s(0.272/5/3) 20140716 11:15:29 i686 Cygwin

Then, I removed /usr/lib/resolv.a, so the call is explicitly done on the new 
Cygwin
DLL.

I removed the complete source code from my /usr/local/src directory, 
re-extracted
the sendmail source, made and installed. So now the test-output of the sendmail 
rule
"check_mail" looks like this:

$ echo "check_mail dan...@cygwin.com" | /usr/sbin/sendmail -d8.20 -bt
dns_getcanonname(dimension, trymx=1)
dns_getcanonname: trying dimension.sassenheim.dmz (A)
Resolv: querydomain "dimension"  "sassenheim.dmz" type 1
Resolv: query "dimension.sassenheim.dmz" type 1
Resolv: DnsQuery: 0 (Windows)
Resolv: dimension.sassenheim.dmz Section 1 Type 1 Windows Record Length 4
YES
dns_getcanonname: dimension.sassenheim.dmz
readcf: option TrustedUser may cause problems on systems
which do not support fchown() if UseMSP is not set.
ADDRESS TEST MODE (ruleset 3 NOT automatically invoked)
Enter  
> check_mail input: daniel @ cygwin . com
Basic_check_mail   input: daniel @ cygwin . com
tls_client input: $| MAIL
TLS_connection input:
TLS_connection   returns:
tls_client   returns:
CanonAddr  input: < daniel @ cygwin . com >
canonify   input: < daniel @ cygwin . com >
Canonify2  input: daniel < @ cygwin . com >
dns_getcanonname(cygwin.com, trymx=1)
dns_getcanonname: trying cygwin.com. (A)
Resolv: querydomain "cygwin.com"  "" type 1
Resolv: query "cygwin.com." type 1
Resolv: DnsQuery: 0 (Windows)
Resolv: cygwin.com Section 1 Type 1 Windows Record Length 4
Resolv: ns2.redhat.com Section 3 Type 1 Windows Record Length 4
Resolv: ns1.redhat.com Section 3 Type 1 Windows Record Length 4
Resolv: ns3.redhat.com Section 3 Type 1 Windows Record Length 4
YES
dns_getcanonname: cygwin.com
Canonify2returns: daniel < @ cygwin . com . >
canonify returns: daniel < @ cygwin . com . >
Parse0 input: daniel < @ cygwin . com . >
Parse0   returns: daniel < @ cygwin . com . >
CanonAddrreturns: daniel < @ cygwin . com . >
Basic_check_mail returns: @ daniel < @ cygwin . com >
check_mail   returns: @ daniel < @ cygwin . com >

It works. As you can see, this is done on a WinXP machine. I could also test on 
a
Win7 machine. I don't have Win8 or Win8.1.

Greetings,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: [ANNOUNCEMENT] Updated: Cygwin 1.7.31-1

2014-07-21 Thread D. Boland
Hi Corinna,

Corinna Vinschen wrote:
> 
> [Now with correct subject, sorry]
> 
> Hi Cygwin friends and users,
> 
> I just released Cygwin 1.7.31-1.  This is mostely a bugfix release.
> 

$ uname -a
CYGWIN_NT-5.1 dimension 1.7.31s(0.272/5/3) 20140716 11:15:29 i686 Cygwin

With the snapshot in place, the ftp client hangs indefinitely after entering the
password. Switching back to my old Cygwin DLL, it works again.

Greetings,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: [ANNOUNCEMENT] Updated: Cygwin 1.7.31-1

2014-07-21 Thread D. Boland
Hi Warren,

Warren Young wrote:
> 
> On 7/21/2014 06:19, D. Boland wrote:
> >
> > With the snapshot in place, the ftp client hangs indefinitely after 
> > entering the
> > password. Switching back to my old Cygwin DLL, it works again.
> 
> Which FTP client is that?  The ftp.exe that comes with Windows, the
> ftp.exe from Cygwin's inetutils (?) package, or some other FTP client?

I used the ftp program from the inetutils package. 

D.


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: [ANNOUNCEMENT] Updated: Cygwin 1.7.31-1

2014-07-21 Thread Matt D.
Cannot replicate on Windows XP SP3 with latest Cygwin DLL by launching 
Cygwin's ftp from Windows command prompt or from a bash prompt. 
Everything connects fine.



Matt D.

On 7/21/2014 10:52 AM, D. Boland wrote:

Hi Warren,

Warren Young wrote:


On 7/21/2014 06:19, D. Boland wrote:


With the snapshot in place, the ftp client hangs indefinitely after entering the
password. Switching back to my old Cygwin DLL, it works again.


Which FTP client is that?  The ftp.exe that comes with Windows, the
ftp.exe from Cygwin's inetutils (?) package, or some other FTP client?


I used the ftp program from the inetutils package.

D.


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple





--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Minires truncates host names

2014-07-21 Thread D. Boland
Hi Corinna,

Corinna Vinschen wrote:
> 
> > It works. As you can see, this is done on a WinXP machine. I could also 
> > test on a
> > Win7 machine. I don't have Win8 or Win8.1.
> 
> That's fine.  Thanks a lot for confirming again that Pierre's patch
> works and the latest Cygwin DLL is doing the right thing here.
> 
> Out of curiosity, did you manage to build sendmail on 64 bit Cygwin yet?

No, only the 32bit one yet. I need to have it working smoothly before the start 
of
the upcoming school year. I'm a Linux teacher in Holland.

> And more importantly, are you going to become Cygwin maintainer for the
> sendmail package?  This would be way cool.
> 

I'd be delighted! Is there some infos I should read?

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Caveats for removing /cygdrive prefix?

2014-07-22 Thread Matt D.
I've always used Cygwin's fstab /cygdrive default but I'm growing tired 
of always typing it out; msys's simple "/a" "/c" "/d" prefix for drive 
letters always seemed closer to home while on a Windows machine.


The only problem I've encountered is a borked ls display when an actual 
folder "a", "b", etc., appears in the Cygwin root folder and the 
inability to enumerate drive with "ls /cygdrive".


Are there any other caveats to consider?

Also, it would be nice if doing a directory list on /cygdrive was a 
hard-coded operation, to preserve this functionality.



Matt D.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



The eternal uid issue

2014-07-23 Thread D. Boland
Hi Cygwin lovers,

After some weeks of serious compiling, researching, understanding, fixing, 
testing
and compiling again, I managed to get the Sendmail source code compiled and 
working.

But I had to compromise in some critical areas. One of them is the uid issue.

* sendmail, procmail, mail.local assume that the id of the privileged user is 
'0'.

Within the current Cygwin DLL, this is '18'. So the maintainer of, let's say, 
the
procmail code has to change a constant, named ROOT_uid to be 18 if compiled in
cygwin. I had to do the same in Sendmails' own Mail Delivery Agent, 
'mail.local'.

But that's no real fix. That's a work-around. Cygwin is supposed to emulate 
Linux,
so why not change the 'getuid' function to return '0' if the uid is '18'? This 
is
exactly what all Linux source code expects, so we would never have to worry 
about it
again.

Instead, maintainers constantly have to "correct" this "bug" in every new 
version of
their source code.

The general idea behind this is "never to break user space", where the programs 
are
seen as the users. Actually, it's Linus Torwalds's first rule of kernel 
programming
and one can read here how serious he is about this:

https://lkml.org/lkml/2012/12/23/75

Isn't it about time to make this our First Directive also?

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: The eternal uid issue

2014-07-23 Thread D. Boland
Linda Walsh wrote:
> 
> D. Boland wrote:
> > But I had to compromise in some critical areas. One of them is the uid 
> > issue.
> >
> > * sendmail, procmail, mail.local assume that the id of the privileged user 
> > is '0'.
> >
> > Isn't it about time to make this our First Directive also?
> >
> >
> I thought sendmail used capabilities?
> 
> Isn't it about time none of them used a fixed 'uid', but used capabilities?
> 
> I thought hard coding a Uid was going out with the dodo bird?

You didn't get the point. We create a kernel on which Linux software runs. We 
don't
dictate how software should be written.

Regards,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: The eternal uid issue

2014-07-23 Thread D. Boland
Hi Corinna,

Corinna Vinschen wrote:
> 
> > Isn't it about time to make this our First Directive also?
> 
> Not in relation to the uid.  In contrast to Linux we don't have the one
> single root user.  We have potentially endless numbers of them, and one
> of them, not necessarily SYSTEM, is used to run the service.  Keep in
> mind that there may also be company policy in place which disallows
> installing services under specific accounts unless absolutely necessary.
> 
> Therefore, while we mostly strive to make Cygwin accommodate user
> space, we're not able to do it related to the root uid.
> 

Thanks for your lengthly and detailed answer. I appreciate that. But don't you 
think
upstream maintainers will raise at least one eyebrow if we propose code that 
makes
any user who starts the program the root/admin user?
You suggest only those who are in the admin group. But that will soon be any 
service
that starts up.

It actually is my solution to running Sendmail: create the Sendmail user, called
'smmsp' and make it an Administrator, so it can impersonate users on my system.
But I don't like my solution, because this would mean I have to create an 
admin-user
for any Linux service that I install. So now my Cygwin setup would be crowded 
with
highly
privileged daemons, listening, waiting to get hacked.

The more elegant solution would be to create only one secondary privileged user,
let's call it 'root' ;-). Now Sendmail can start as root, switch to the totally
*unprivileged* 'smmsp' user and receive mail.
Of course the real bonus is that these unprivileged users wouldn't need 
passwords,
since they are impersonated, not logged on. These would consequently be
*super-secure* users, because it is impossible to login with an empty password.

Why is this related to the uid issue? I already tested the second solution. I 
found
out that if I assign my 'root' user the '0' id in /etc/passwd, it actually 
works. I
was delighted, because I could roll-back all these weird changes I put in the
Sendmail/procmail/mail.local source to fix the getuid != 0 problem.

If we go with this MS-imposed idea of "putting services in admin-context", 
Cygwin
security will be done for in the long run. Why not make the leap and show MS
admins/developers how it should be done?

Sincerely,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: The eternal uid issue

2014-07-23 Thread D. Boland
Hi Corinna,

Thanks for the reply.

Corinna Vinschen wrote:
> 
> On Jul 23 13:35, D. Boland wrote:
> > Corinna Vinschen wrote:
> > > Not in relation to the uid.  In contrast to Linux we don't have the one
> > > single root user.  We have potentially endless numbers of them, and one
> > > of them, not necessarily SYSTEM, is used to run the service.  Keep in
> > > mind that there may also be company policy in place which disallows
> > > installing services under specific accounts unless absolutely necessary.
> > >
> > > Therefore, while we mostly strive to make Cygwin accommodate user
> > > space, we're not able to do it related to the root uid.
> >
> > Thanks for your lengthly and detailed answer. I appreciate that. But
> > don't you think upstream maintainers will raise at least one eyebrow
> > if we propose code that makes any user who starts the program the
> > root/admin user?  You suggest only those who are in the admin group.
> > But that will soon be any service that starts up.
> 
> You're getting this wrong.  Cygwin is not the OS.  We do not make
> every user an admin since we're in no position to do that.  We can't
> give the user any more rights the OS is already giving the user.

Yes, Cygwin is not the OS. But to the user-software, it re-presents the OS as 
if it
were Linux. That's what an emulator does.

> 
> The idea of such a test is to make the test independent of the actual
> uid.  There are two cases.  One is to check if the user has admin
> rights to perform certain actions, the other is to check if a file
> ownership is safe.  A safe ownership is one where the file belongs
> to the user running the service.  On Linux or BSD systems that's
> usually the root user, in our case it's some arbitrary user account.
> The check is basically the same.
> 
> > It actually is my solution to running Sendmail: create the Sendmail
> > user, called 'smmsp' and make it an Administrator, so it can
> > impersonate users on my system.  But I don't like my solution, because
> > this would mean I have to create an admin-user for any Linux service
> > that I install. So now my Cygwin setup would be crowded with highly
> > privileged daemons, listening, waiting to get hacked.
> 
> That's what the cyg_server account is meant for.  It's the one account
> which has the right to change the user context even when using method 1
> from the setuid overview of the User's Guide.
> 
> Other services don't need this permissions, they just have to have
> the right to create certain objects.  Cygserver is such a service,
> for instance.  It's perfectly fine for cygserver to run under SYSTEM
> or, FWIW, any other account with local administrative privileges.
> 
> > The more elegant solution would be to create only one secondary
> > privileged user, let's call it 'root' ;-). Now Sendmail can start as
> > root, switch to the totally *unprivileged* 'smmsp' user and receive
> > mail.  Of course the real bonus is that these unprivileged users
> > wouldn't need passwords, since they are impersonated, not logged on.
> > These would consequently be *super-secure* users, because it is
> > impossible to login with an empty password.
> 
> Same thing with cyg_server.
> 
> > Why is this related to the uid issue? I already tested the second
> > solution. I found out that if I assign my 'root' user the '0' id in
> > /etc/passwd, it actually works. I was delighted, because I could
> > roll-back all these weird changes I put in the
> > Sendmail/procmail/mail.local source to fix the getuid != 0 problem.
> 
> Yes, you can do that and it was always possible, but it requires
> unnecessary user changes.  Also, passwd and group files are going
> to become entirely superfluous at one point, and there's not a
> single account which is translated to uid 0 on the fly.  There
> simply isn't one.

That's my point. All Linux software expects one. So Cygwin has to provide one.
Otherwise, the emulation breaks.

Sendmail, for instance, is filled to the brim with uid checks, all assuming that
there is a '0' account. Its whole idea of security is based around it. Below a
sample:

$ grep -r getuid *
sendmail/deliver.c: if (RealUid != 0 && RealUid !=
getuid())
sendmail/deliver.c:(int) getuid(), (int)
geteuid(),
sendmail/deliver.c: ret = safefile(m->m_mailer, getuid(),
getgid(),
sendmail/deliver.c: (int) getuid(), (int) geteuid(),
sendmail/main.c:RealU

Re: The eternal uid issue

2014-07-24 Thread D. Boland
Hi Christopher,

Thanks for your reply.

Christopher Faylor wrote:
> 
> On Wed, Jul 23, 2014 at 08:08:07PM +0400, Andrey Repin wrote:
> >Greetings, D. Boland!
> >> Cygwin security will be done for in the long run. Why not make the leap and
> >> show MS admins/developers how it should be done?
> >
> >You really think they are all idiots?... Like, really?
> 
> Sure, why not.  MS admins/developers are all idiots who are apparently
> supposed to be taught by Cygwin developers who have been getting it
> wrong for many years until being correct by the OP.
> 
> To the OP: If you want to start a dialog, do research and ask questions.
> Don't just assume that you understand everything and can provide insight
> that no one else has thought of.
> 
> cgf

I didn't say 'idiots', but I did LOL at Andrey's suggestion. Andrey, I'm 
beginning
to like you. By the way, your english really isn't that bad.

What I meant was that MS dicided to take away impersonation privileges from the
SYSTEM user, without educating admins/developers about the new model or 
alternatives
for SYSTEM.

I searched the web extensively for an explanation on the newly imposed 
restriction.
I didn't find one yet. Only vague advice to not start services using the local
System account:

"Minimize the use of the Local System account on the site servers and site 
systems
by not installing other services that use the Local System account. This ensures
that other processes cannot take advantage of the enhanced privileges of the
system’s computer account, accessing Configuration Manager 2007 files and data
through those other systems."
--
source: http://technet.microsoft.com/en-us/library/bb680595.aspx

So I have to assume that it was to enhance Windows security. That is not
far-fetched, since the SYSTEM "user" is totally unrestricted and not suited to 
be
exposed directly to users from the outside.
I also have to assume that what they mean by "not installing other services 
that use
the Local System account" is to create a new user and running a service on 
behalf of
it.

Here's how they explain how to configure MS SQL Server (which uses 
impersonation),
but without explaining the underlying security model for services:

http://msdn.microsoft.com/en-us/library/ms143504.aspx

The only reference I can find about the service security model are the terms
"minimum rights" and "minimum privileges". 

In Linux, the daemon security model is well-known and can be implemented by 
running
as an 'unprivileged user'. Sendmail uses this idea extensively. 

Again, the only option I have at this moment is to run the Sendmail user 
(smmsp) as
an Administrator, so it can do impersonation. But this does *not* constitute
'minimum privileges', nor does this make the Sendmail user run as an 
'unprivileged
user'.

The preferred solution is to only *start* Sendmail with a privileged user, 
let's say
'cyg_server'. Now Sendmail can switch to the 'smmsp' user and be running totally
unprivileged, only having access to its mail queue directory.

But after configuring Sendmail this way, it starts to complain about not having
access permissions, because it detects it was not started with the root user 
(getuid
!= 0). 

So, my original question was: can the Cygwin function 'getuid' be made to 
return '0'
if the program is running as the SYSTEM user? But because SYSTEM cannot be used
anymore, Corinna suggests to use 'cyg_server' instead and put checks for
administrator rights in the Sendmail source. 

In my reply to her in this thread, I rephrased my question: can the Cygwin 
function
'getuid' be made to return '0' if the program is running as the SYSTEM user or 
is
running with administrator rights?

Cincerely,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: The eternal uid issue

2014-07-24 Thread D. Boland
Hi Corinna,

Corinna Vinschen wrote:
> > But this only introduces a new function which she has to put into multiple 
> > locations
> > of the original code. So again, why not just modify the 'getuid' function in
> > cygwin1.dll to return '0' if the current user is actually SYSTEM or one of 
> > the
> > administrators?
> >
> > Then you have rock-solid emulation. I would not have to modify a single 
> > line of
> > code.
> 
> You're kidding, right?  

Haha. I must admit that I was not kidding. I got stuck with the idea that 
"there can
only be one". 

> What about code like this:
> 
>   struct stat st;
>   stat("foo", &st);
>   if (st.st_uid != getuid ())
> /*error*/
>   else
> /*do something*/
> 
> I'm not saying that this is overly elegant coding, but just as you
> expect that getuid() returns 0 for any admin, other applications will
> expect that getuid() reflects reality.
> 
> Why don't you just override getuid in your application to serve the
> applications needs?
> 
>   #ifdef __CYGWIN__
>   #define getuid()  CYG_getuid()
>   #endif
> 
>   [...]
> 
>   #ifdef __CYGWIN__
>   #undef getuid
>   uid_t
>   CYG_getuid ()
>   {
> /* Return 0 for any admin user. */
> if (/*getgroups() contains group 544*/)
>   return 0;
> return getuid ();
>   }
> 
> But be careful.  Just because there are multiple users with admin
> permissions, that doesn't mean they all want their mail in the same
> mailbox for user 0...

Thanks for the overloading code. I already tested it. Now I can leave the 
Sendmail
code (almost) unchanged. Thanks also for the time you put into this. I hope the
RedHat people pay you well.

I have Sendmail ready to be released, but only the 'crude' version (running as 
an
admin user). I'd like to go for the preferred solution (starting as admin, 
switching
to unprivileged). The uid issue is sorted. But to get it there, I have one final
problem to solve.

Sendmail checks if the user's home directories are group- or world writable. It 
does
this with 'stat'. If Sendmail is running in 'crude' mode (main program and 
children
running as the Sendmail 'smmsp' user, made admin), stat returns the right file 
mode
for my home directory (rwxr-xr-x). The email is delivered.

If I have Sendmail running in preferred mode (main program as cyg_server, 
children
running as 'smmsp', removed from admin group), stat returns the wrong mode
(rwxrwxrwx). As a consequence, Sendmail refuses to deliver email.

Can I do anything about this?

Cincerely,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: The eternal uid issue

2014-07-25 Thread D. Boland
Corinna Vinschen wrote:
> Oh, hang on.  Is this using the default setuid method 1 and is your
> home dir on a remote share, by any chance?

No. All file locations are local (C:\). I'll send you the output later on.


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: The deprecated uid issue: use caps

2014-07-26 Thread D. Boland
Hi Linda,

Linda Walsh wrote:
> 
> D. Boland wrote:
> > Linda Walsh wrote:
> >> D. Boland wrote:
> >>> But I had to compromise in some critical areas. One of them is the uid 
> >>> issue.
> >>>
> >>> * sendmail, procmail, mail.local assume that the id of the privileged 
> >>> user is '0'.
> >>>
> >>> Isn't it about time to make this our First Directive also?
> >>>
> >>>
> >> I thought sendmail used capabilities?
> >>
> >> Isn't it about time none of them used a fixed 'uid', but used capabilities?
> >>
> >> I thought hard coding a Uid was going out with the dodo bird?
> >
> > You didn't get the point. We create a kernel on which Linux software runs. 
> > We don't
> > dictate how software should be written.
> You are missing the point.
> 
> MS privilege model is the MS version of the linux capability model.
> 
> MS didn't get it wrong, linux has been slow to adopt, but MS had linux
> capabilities 10 years before linux did.
> 
> Several other people have tried to explain that the way to go is to use
> the "minimum priviledge model".
> 
> For example, almost ALL user have the "unreadable directory traversal"
> priv/capability.
> 
> To enforce it cost alot in execution time on Windows (as it would under
> cygwin).
> 
> Another priviledge is to "impersonate" another user; sendmail would
> likely need such a privilege.  Another is to ignore file-permissions.
> It would be questionable whether or not sendmail needed that.
> 
> Sendmail was using capabilities back in 2000 when I brought a basic
> "non-reciprocal action"  bug in the capability code to the attention
> of Ted Tso, he told me and others that I didn't know what I was talking
> about and they were following POSIX and my "find" was irrelevant under
> POSIX.
> About 10 days later there was a day-zero exploit involving the bug
> in the defective code using sendmail's capability usage as the vector.
> The result was kernel caps being disabled for the next few years until
> the cap-code could be reviewed by more eyes and knew what to look for.
> 
> So I'm pretty sure sendmail has had code to extensively run solely off
> of capabilities and has had it for some time.  I'd be surprised if it
> was removed.
> 
> Linux software that uses the capability model is likely to not have
> these problems.  But saying that any random linux software with security
> bugs
> from the past should work on cygwin, seems like a ridiculous stance to
> take.
> 
> You can set capabilities on files processes and network sockets. Linux file
> systems with "extended attributes" or "alternate data forks" (2 names
> for the
> same thing), can and do support "SETCAP" on linux files that works just
> like SETUID, but for capabilities.
> 
> MS only supports the capability model and uses it to implement their
> Admin or privileged user model.  They don't support the less secure setuid
> model that linux is moving away from.
> 
> Does this help clarify the issue ?

Thanks for disagreeing. You are completely right. Sendmail seems to demand a 
much
more restrictive impersonation policy than Windows offers. That's why I can't 
get
the thing to work. It constantly tests if certain actions are allowed and if 
so, it
just refuses to deliver e-mail.

I'll look into this capabilities thing, but I do not intend to change anything
significant  in the Sendmail code. Maybe the folks at Proofpoint will switch to 
it
one day. 

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: The eternal uid issue

2014-07-28 Thread D. Boland
Hi Corinna,

Corinna Vinschen wrote:
> 
> Still, are you using setuid method 1 or another method?  Is your home
> dir the default /home/$USER as created from inside the Cygwin
> environment?  Any chance your home dir has an unusual ACL?
> 
> Did you set up sshd as service?  If not, you might consider to do that
> so you can check what happens when switching to the smmsp account.  Run
> ssh-host-config as admin, install the service.  Create an authorized_keys
> file for the smmsp user (run ssh-user-config under smmsp for instance),
> then start the service.  Now login to the smmsp user account using
> public key authentication, admin-enabled vs. non-admin as above(*), and
> observe the permissions ls or stat show you for your home dir.  Are they
> really different?  If so, let's see the strace output again.

Argh! I checked the /home folder and it was indeed group and world writable. 
After
setting it to 0755 sendmail had no issues anymore. Sendmail checks permissions 
on
the entire path. I cannot remember setting it 0777, so something else must have 
set
it.

Regarding the suid method: You mean method 1, 2 and 3 in the "Using Windows 
security
in Cygwin" article, right? I have nothing special set up, so it uses the default
method 1.

As to the sshd, I had it set up as a service already.

Thanks again for your help. I will announce the Sendmail release soon.

Cincerely,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: The eternal uid issue

2014-07-29 Thread D. Boland
Corinna Vinschen wrote:
> The permissions of the home folder are set to 01777 by default (S_ISVTX
> bit!).  Since we can't rely on central administration for Cygwin, this
> allows a user to create her own homedir automatically at first start of
> a Cygwin shell.
> 
> You might consider to disable this full patch check in sendmail for
> Cygwin.  Is there some configuration flag, maybe?
> 

If I make the 'Users' group owner of the /home folder and remove the 
world-writable
bit, Sendmail doesn't complain anymore. I found out that everybody who is 
logged on,
will be put in the 'Users' group anyway. 

Regards,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: The eternal uid issue

2014-07-31 Thread D. Boland
Corinna Vinschen wrote:
> 
> On Jul 29 15:36, D. Boland wrote:
> > Corinna Vinschen wrote:
> > > The permissions of the home folder are set to 01777 by default (S_ISVTX
> > > bit!).  Since we can't rely on central administration for Cygwin, this
> > > allows a user to create her own homedir automatically at first start of
> > > a Cygwin shell.
> > >
> > > You might consider to disable this full patch check in sendmail for
> > > Cygwin.  Is there some configuration flag, maybe?
> > >
> >
> > If I make the 'Users' group owner of the /home folder and remove the 
> > world-writable
> > bit, Sendmail doesn't complain anymore. I found out that everybody who is 
> > logged on,
> > will be put in the 'Users' group anyway.
> 
> Uhm... that works for you, but you can't rely on that for a sendmail
> package.  You'd have to deal with the default 01777 /home as well.

Yes, yes, I know. Cygwin shouldn't want to lock their users out of their own 
system.
Sendmail is a real b&^ch with security. This project cost me 2 1/2 weeks 
straight,
trying to figure out a way to accomodate its strict impersonation rules on a 
system
which has multiple root users. But I did it. No hacking in the sendmail source 
code.

Anyway, today I tested it succesfully on my Win7 machine (32bit Cygwin), but no
complaining from Sendmail, even with a home folder which is group- and world
writable. Strange.

Cincerely,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Simplify AD integration?

2014-07-31 Thread D. Boland
Corinna Vinschen wrote:
> So I'd like to ask a few questions to which I'd like to have some brief
> answers, kind of like a poll, to get a better idea how we should
> proceed:
> 
> 1. Shall we remove the leading '+' from the builtin account names
>or shall we keep it?
> 
> 2. Shall we stick to '+' as the separator char or choose another one?
>If so, which one?
> 
> 3. Shall we keep the `db_prefix' variability or choose one of
>the prefixing methods and stick to it?  If so, which one, auto,
>primary, or always?

I'm a legacy man. So I would say keep the MS symbol and use it like this 
\daniel,
\SYSTEM, etc.

> 
> Bonus question:
> 
> 4. Should Cygwin downcase all usernames when generating the Cygwin
>username, so, if your Windows username is 'Ralph', your Cygwin
>username will be 'ralph'?
> 

When in the Cywin domain, do like Cygwin. So, downcasing.

Cheers,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Simplify AD integration?

2014-07-31 Thread D. Boland
Eric Blake wrote:
> 
> On 07/31/2014 07:26 AM, D. Boland wrote:
> > Corinna Vinschen wrote:
> >> So I'd like to ask a few questions to which I'd like to have some brief
> >> answers, kind of like a poll, to get a better idea how we should
> >> proceed:
> >>
> >> 1. Shall we remove the leading '+' from the builtin account names
> >>or shall we keep it?
> >>
> >> 2. Shall we stick to '+' as the separator char or choose another one?
> >>If so, which one?
> >>
> >> 3. Shall we keep the `db_prefix' variability or choose one of
> >>the prefixing methods and stick to it?  If so, which one, auto,
> >>primary, or always?
> >
> > I'm a legacy man. So I would say keep the MS symbol and use it like this 
> > \daniel,
> > \SYSTEM, etc.
> 
> But you'd have to write that as '\daniel' or \\daniel in the shell, and
> you also cripple tilde expansion.  That's why we already ruled out :, \,
> and / as non-starters, as mentioned elsewhere in this thread.

I am not only a man of legacy, but also a very opinionated one. So give me some
slack when I say: the whole thing is insane. This would mean that from now on, I
have to use constructs like ~+daniel ~+SYSTEM in a Linux shell?? Bizarre.

On the other hand, for the sake of progress, but keeping legacy there would be 
only
one acceptable solution: use the tilde symbol. A user could then be referred to 
as:
~daniel.

This already works in the shell and it is also done by the Apache webserver. If 
I
want to go my personal web space I can type:

http://localhost/~daniel/

Come to think of it: IMAP does this too! I have been coding for an IMAP 
project, and
if you want to fetch somebody's mail, you'd have to use ~corinna to display the
contents of her INBOX.

Cheers,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Simplify AD integration?

2014-08-01 Thread D. Boland
Andrey Repin wrote:
> 
> Greetings, D. Boland!
> 
> > I am not only a man of legacy, but also a very opinionated one. So give me 
> > some
> > slack when I say: the whole thing is insane. This would mean that from now 
> > on, I
> > have to use constructs like ~+daniel ~+SYSTEM in a Linux shell?? Bizarre.
> 
> No, you don't have. Default domain users are unprefixed, and the chance you
> would use internal accounts for something like shell access is exactly zero.
> 
> For the god's sake, read the thread before posting into it. Everything has
> been discussed no more than two days ago.

Yes, yes, I know. I wanted to react from the heart, without the intellectual 
baggage
of knowing the technical intricacies behind the problem.

D.


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



syslog function: Bad file descriptor

2014-08-05 Thread D. Boland
Hi group,

I'm still working on getting Sendmail working for Cygwin. I'm almost done, the 
devil
is in the details...

I'm getting the 'Bad file descriptor' system error after building the mail 
aliases
database. The building itself is done successful, but logging the event to the
system log fails with this message.

Somehow the two are connected. The alias database (aliases.db) is built from a 
plain
text file (aliases). If I leave the aliases file writable to the sendmail user, 
I
find that the error message strings have been put right into the alias 
text-file:

$ cat /etc/mail/aliases
<21>sendmail: PID 1848: alias database /etc/mail/aliases rebuilt by smmspsenet: 
root
news: root
webmaster: root
www: root
ftp: root
abuse: root
noc: root
security: root
root: SYSTEM
<22>sendmail: PID 1848: /etc/mail/aliases: 9 aliases, longest 6 bytes, 82 bytes
total

If I make the 'aliases' file read-only, then the file is not corrupted, but the
error occurs.

Cheers,
Daniel

Here's the strace output. I copied the lines between two subsequent calls to
'syslog':

strace /usr/sbin/sendmail -bi

syslog: Bad file descriptor
  145 16951672 [main] sendmail 1104 write: 28 = write(1, 0x2007EFB0, 28)
  131 16951803 [main] sendmail 1104 cygpsid::debug_print: get_sids_info: owner 
SID =
S-1-5-21-1659004503-813497703-854245398-1028
   56 16951859 [main] sendmail 1104 cygpsid::debug_print: get_sids_info: group 
SID =
S-1-5-21-1659004503-813497703-854245398-1029
   55 16951914 [main] sendmail 1104 get_info_from_sd: ACL 0x120, uid 1028, gid 
1029
   74 16951988 [main] sendmail 1104 fhandler_base::fstat_helper: 0 = fstat
(\??\C:\cygwin\etc\mail\aliases, 0x228A10) st_size=183, st_mode=0x8120,
st_ino=1970324837070571st_atim=53E0FB5C.120ACC80 st_ctim=53E0FB59.1859C3C0
st_mtim=53E0FB4E.205C2E00 st_birthtim=53DE6678.2B7D5340
   68 16952056 [main] sendmail 1104 fstat64: 0 = fstat(3, 0x228A10)
   76 16952132 [main] sendmail 1104 read: read(3, 0x2008EFB8, 65536) blocking
   73 16952205 [main] sendmail 1104 fhandler_base::read: returning 183, binary 
mode
   50 16952255 [main] sendmail 1104 read: 183 = read(3, 0x2008EFB8, 65536)
  333 16952588 [main] sendmail 1104 fhandler_disk_file::pread: 16384 =
pread(0x2004D9D4, 16384, 32768)
   63 16952651 [main] sendmail 1104 pread: 16384 = pread(6, 0x2004D9D4, 16384,
32768)
  345 16952996 [main] sendmail 1104 fhandler_disk_file::pread: 16384 =
pread(0x2009EFFC, 16384, 16384)
   58 16953054 [main] sendmail 1104 pread: 16384 = pread(6, 0x2009EFFC, 16384,
16384)
 2580 16955634 [main] sendmail 1104 read: read(3, 0x2008EFB8, 65536) blocking
   69 16955703 [main] sendmail 1104 fhandler_base::read: returning 0, binary 
mode
   48 16955751 [main] sendmail 1104 read: 0 = read(3, 0x2008EFB8, 65536)
/etc/mail/aliases: 13 aliases, longest 10 bytes, 144 bytes total
  196 16955947 [main] sendmail 1104 write: 65 = write(1, 0x2007EFB0, 65)
   53 16956000 [main] sendmail 1104 vsyslog: 0x6 %s
  243 16956243 [main] sendmail 1104 open: open(/dev/null, 0x10601)
   51 16956294 [main] sendmail 1104 normalize_posix_path: src /dev/null
   71 16956365 [main] sendmail 1104 normalize_posix_path: /dev/null =
normalize_posix_path (/dev/null)
   50 16956415 [main] sendmail 1104 mount_info::conv_to_win32_path:
conv_to_win32_path (/dev/null)
   48 16956463 [main] sendmail 1104 mount_info::conv_to_win32_path: src_path
/dev/null, dst \Device\Null, flags 0x2, rc 0
   64 16956527 [main] sendmail 1104 build_fh_pc: fh 0x612AEC2C, dev 00010003
   51 16956578 [main] sendmail 1104 fhandler_base::open: (\Device\Null, 0x18601)
   61 16956639 [main] sendmail 1104 fhandler_base::set_flags: flags 0x18601,
supplied_bin 0x1
   51 16956690 [main] sendmail 1104 fhandler_base::set_flags: O_TEXT/O_BINARY 
set in
flags 0x1
   50 16956740 [main] sendmail 1104 fhandler_base::set_flags: filemode set to 
binary
   48 16956788 [main] sendmail 1104 fhandler_base::open: 0x0 = NtCreateFile 
(0x60C,
0x40120080, \Device\Null, io, NULL, 0x0, 0x7, 0x3, 0x4020, NULL, 0)
   52 16956840 [main] sendmail 1104 fhandler_base::open: 1 =
fhandler_base::open(\Device\Null, 0x18601)
   51 16956891 [main] sendmail 1104 open: 7 = open(/dev/null, 0x18601)
  190 16957081 [main] sendmail 1104 _cygwin_istext_for_stdio: fd 7: opened as 
binary
 1045 16958126 [main] sendmail 1104 write: write(7, 0x227B50, 10)
   49 16958175 [main] sendmail 1104 write: 10 = write(7, 0x227B50, 10)
  169 16958344 [main] sendmail 1104 getpid: 1104 = getpid()
  555 16958899 [main] sendmail 1104 write: write(7, 0x227B50, 10)
   47 16958946 [main] sendmail 1104 write: 10 = write(7, 0x227B50, 10)
  688 16959634 [main] sendmail 1104 write: write(7, 0x227B70, 64)
   49 16959683 [main] sendmail 1104 write: 64 = write(7, 0x227B70, 64)
  256 16959939 [main] sendmail 1104 close: close(7)
  440 16960379 [main] sendmail 1104 fhandler_base::close: closing '/dev/null' 
handle
0x60C
   36 16960415 [main] sendmail 1104 close: 0 = close(7)
  616 16961031 [main] sendmail 1104 getpid: 1104 = getpid()
   51 16961082 [mai

Re: syslog function: Bad file descriptor

2014-08-05 Thread D. Boland
"Larry Hall (Cygwin)" wrote:
> 
> On 08/05/2014 12:28 PM, D. Boland wrote:
> > Hi group,
> >
> > I'm still working on getting Sendmail working for Cygwin. I'm almost done, 
> > the devil
> > is in the details...
> >
> > I'm getting the 'Bad file descriptor' system error after building the mail 
> > aliases
> > database. The building itself is done successful, but logging the event to 
> > the
> > system log fails with this message.
> 
> Did you mention whether you've installed and configured some syslog service?

I have syslogd running from the 'inetutils-server' package.

D.


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: syslog function: Bad file descriptor

2014-08-05 Thread D. Boland
Corinna Vinschen wrote:
>
> Can you produce another strace for the overwriting case (non-R/O aliases)
> for comparison?  Also, can you do the same strace with no syslogd running?
> 
> It might be necessary to create a few test versions of Cygwin with more
> debug output, but let's please see these straces first.

I attached all three of them in a zipped file.

By the way: my previous strace outputs where from an older version of 
cygwin1.dll. I
put a recent one in and did the attached traces:

CYGWIN_NT-5.1 dimension 1.7.31s(0.272/5/3) 20140716 11:15:29 i686 Cygwin

Daniel

sendmail-test.tar.gz
Description: GNU Zip compressed data
--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple

Re: syslog function: Bad file descriptor

2014-08-06 Thread D. Boland
Hi Corinna,

Corinna Vinschen wrote:
> 
> On Aug  5 22:35, D. Boland wrote:
> > Corinna Vinschen wrote:
> > >
> > > Can you produce another strace for the overwriting case (non-R/O aliases)
> > > for comparison?  Also, can you do the same strace with no syslogd running?
> > >
> > > It might be necessary to create a few test versions of Cygwin with more
> > > debug output, but let's please see these straces first.
> >
> > I attached all three of them in a zipped file.
> 
> Thanks.  I got it now.  AFAICS it's a bug in sendmail.  Take a look
> into your newaliases.strace.txt file.  Start at line 260 (stripping
> off timestamp, thread and process info):
> 
>   260:  normalize_posix_path: src /dev/log
> 
> Here the syslog() function tries to open a connection to a syslogd
> listening on /dev/log.
> 
>   282:  cygwin_socket: 3 = socket(1, 2 (flags 0x0), 0)
> 
> Socket created, file descriptor is 3.
> 
>   296:  connect_syslogd: found /dev/log, fd = 3, type = DGRAM
> 
> Yes, there's a listener on /dev/log.  Now Cygwin stores the info that fd
> 3 is the connection to the syslog daemon.
> 
>   332:  close: close(3)
> 
> And at line 332, a file descriptor close orgy starts.  sendmail closes
> all descriptors from 3 to 255.  This obviously closes fd 3, but how's
> Cygwin's syslog() function to know?
> 
>  2263:  open: 3 = open(/etc/mail/aliases, 0x8000)
> 
> Uh oh!  Now fd 3 is reused for the aliases file.  Things certainly go
> downhill.
> 
>  2651:  writev: -1 = writev(3, 0x2287F0, 2), errno 9
> 
> This is syslog trying to write the log to the descriptor it knows
> is connected to /dev/log.  Fortunately the aliases file is R/O at
> this point, but it's pretty much working as designed.  Syslog()
> doesn't know the application broke its connection to the syslog
> daemon.  It dutyfully writes to the syslog descriptor it knows
> about.
> 
> As for using a file descriptor inside of syslog, that's perfectly
> valid behaviour, see
> http://pubs.opengroup.org/onlinepubs/9699919799/functions/closelog.html:
> 
>   "The openlog() and syslog() functions may allocate a file descriptor."
> 
> Without looking into the sources, I'd assume there's a closelog()
> call missing prior to the descriptor close orgy.  This closelog()
> call should fix the problem.

It is exactly as you say. I found the close() orgy and put a closelog() prior 
to it.
Now it works perfectly without corrupting the aliases file (writable to 
sendmail).

I'm asking myself if this closing of 253 file descriptors is a sensible thing 
to do.
What would Sendmail be trying to accomplish there? It comments "Be shure we have
enough file descriptors". And: "in 4.4BSD, the table ([of fd's]) can be huge; 
impose
a reasonable limit". Bizarre.

Could it be that incoming e-mail is such a volatile process that previous opened
file descriptors are not closed quick enough? This feels like a crude hack.

Can you give your opinion on this?

Thanks for the quick response & the time you put into this.

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Impending ITP of Sendmail

2014-08-09 Thread D. Boland
Hi group,

I have the Sendmail port ready. I will anounce my intent to package it soon.

There is one thing, though. Sendmail relies heavily on the procmail program. The
problem is that the procmail package as it is now, is not "multiple root" 
aware. It
also is not able to do suid at the moment.

To accomplished this, procmail would have to be modified slightly. From the 
Cygwin
website, I can see that procmail is maintained bij Jason Tishler.

I need these modifications for Sendmail to work. I remember Corinna mentioning 
that
the package is old and needs to be updated. Maybe it is orphaned? In that case 
I'd
be happy to adopt it.

Cincerely,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Impending ITP of Sendmail

2014-08-11 Thread D. Boland
Jason Tishler wrote:
> 
> Daniel,
> 
> On Mon, Aug 11, 2014 at 12:46:54PM +0200, Corinna Vinschen wrote:
> > On Aug  9 22:41, D. Boland wrote:
> > > [snip]
> > > To accomplished this, procmail would have to be modified slightly.
> > > From the Cygwin website, I can see that procmail is maintained bij
> > > Jason Tishler.
> > >
> > > I need these modifications for Sendmail to work. I remember Corinna
> > > mentioning that the package is old and needs to be updated. Maybe it
> > > is orphaned? In that case I'd be happy to adopt it.
> >
> > Jason, ping?
> >
> > I already built procmail for x86_64 becasue Jason hadn't much time way
> > back when.  Dependent on his current workload he might be glad to hand
> > over procmail.
> 
> Yes, you are welcome to adopt procmail.
> 
> Thanks,
> Jason

Thank you, Jason. Now I can unleash the ancient, though awesome power of 
Sendmail
onto the Cygwin world. ;-)

Cheers,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Posting ITA/ITP

2014-08-14 Thread D. Boland
Hi group,

I'm trying to post to gmane.os.cygwin.applications, but I get an NNTP error: 
'gmane.os.cygwin.applications is unidirectional'

Should I post to another newsgroup?

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



cygport: keepdir directive doesn't work

2014-08-19 Thread D. Boland
Hi group,

When creating a package, I need some empty directories in the release, but 
cygport
install removes them.

I tried both 'keepdir' and 'keepdirs', but to no avail. I'm using version 
0.16.0-1.

Cheers,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: HEADSUP: OpenSSH 6.7 drops tcpwrapper support

2014-08-19 Thread D. Boland
Hi Corinna,

Corinna Vinschen wrote:
> 
> Hi folks,
> 
> Just a HEADSUP to all of you actively using the tcp_wrappers/libwrap
> functionality in sshd:
> 
> Starting with the next OpenSSH version 6.7, which will be released soon,
> upstream removed support for tcp_wrappers/libwrap from the sources.
> 
> While that's bad from a compatibility point of view, the upstream
> developers are adamant about this change for security reasons.

Can you point me to any documentation about this?

Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: cygport: keepdir directive doesn't work

2014-08-19 Thread D. Boland
Hi Achim,

Achim Gratz wrote:
> 
> D. Boland writes:
> > When creating a package, I need some empty directories in the release, but 
> > cygport
> > install removes them.
> >
> > I tried both 'keepdir' and 'keepdirs', but to no avail. I'm using version 
> > 0.16.0-1.
> 
> These need to specified with the path as installed, not as built.

Thanks, I was using relative paths and also tried the ${D} variable, but it's
absolute paths, like '/var/spool'

D.


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



The status of cygwin 1.7

2008-12-16 Thread d ma
Hello,

Is cygwin 1.7 stable and mature enough to use it instead of 1.5?
Is there a release schedule for cygwin 1.7?

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



OpenSSH_5.1p1 - Connection failed - xmalloc: zero size

2008-08-12 Thread d . choulette
Hi,

I recently upgraded my ssh ( to OpenSSH_5.1p1 )and I can no more connect to some
Solaris servers (SunOS 5.9).

The message I get is:
xmalloc: zero size
and the connection is closed.

I switched back to the previous version of Openssh (OpenSSH_5.0p1 ) and the
problem disappeared.

In both cases I use the same SSL version ( OpenSSL 0.9.8h ).

There is information about this problem on the net (or a problem with the same
symptoms).
But none of the listed solutions (about StrictHostKeyChecking no) worked for me.

Is this a bug or a new feature of OpenSSH_5.1p1 ?

Thanks,

Denis Choulette.

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: command line smtp client / command line email?

2014-09-28 Thread D. Boland
Hi Marilo,

Marilo wrote:
> 
> what are my options for a command line smtp client in cygwin?
> 
> I'd want to specify smtp server and from address. I'd like TLS/SSL to be 
> supported by the command
> 
> sendmail , doesn't look like it exists on cygwin and I know on *nix it shuts 
> down any postfix server so I guess it mighttry to shut down any smtp server I 
> have running.
> 
> heirloom mailx  looks good, but doesn't exist for cygwin.
> 
> I can't see anything for sending an email from/in cygwin

I almost finished porting Sendmail for Cygwin. It does not shut down Exim or
Postfix, but it needs an open port 25 to the outside. Most ISP's don't allow 
this.

The 'email' program can be configured to use the SMTPA (AUTH) port 465 of your 
ISP.
I've been using it for over a year now. No corrupt message body yet.

Cheers,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



[ANNOUNCEMENT] Updated Procmail 3.22-15

2014-11-15 Thread D. Boland
I updated the Procmail 3.22-14 package. The difference with the previous 
version:

* Split the postinstall.sh script into two parts. The second part is now 
contained
in the /usr/bin/procmail-config script.

* The new /usr/bin/procmail-config script contains installation steps for
automatically creating a new local group, called 'mail'.

* The config script also contains an option to create another group instead of 
the
default 'mail' group.

Cheers,
Daniel


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



error mounting smb shared with ~ in name

2012-03-30 Thread Daniel D

Howdy,

Is ~ allowed on a smb share name when mounting it? I keep getting errors 
while trying to mount //server/~foo via fstab.


If yes, can someone give me some tips for what to do to mount a share named 
\\server\~foo ?


Here’s what I already tried:
   - ls //server/~foo works – prints out the content for the dir
   - editing fstab, and adding
   //server/~foo /mnt/~foo smbfs binary,noacl 0 0
   then doing
   mount –a.
   This printed out
   mount: /mnt/~foo: Invalid argument
   - changing in fstab, from //server/~foo to //server/xyz  -- this worked. 
I.e. mount –a does not print out ‘mount: /mnt/~foo: Invalid argument’, and 
`ls /mnt/~foo` prints out the content of //server/xzy

   - mounting the smb share directly did not worked either. Running
   mount //server/~foo /mnt/foo
   also prints out the invalid argument error.
It looks like mount command does not like ~ in the smb share name, though it 
is fine with ~ in the the mount point name. Unfortunately changing the share 
name is not an easy task, and I prefer making this work rather than always 
using long paths with hard-coded remote hostnames.


TIA for any help. 



--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: error mounting smb shared with ~ in name

2012-04-01 Thread Daniel D
> Thorsten Kampe  thorstenkampe.de> writes:
> 
> > 
> > * Daniel D (Fri, 30 Mar 2012 21:52:35 -0700)
> > > 
> > > Is ~ allowed on a smb share name when mounting it? I keep getting errors 
> > > while trying to mount //server/~foo via fstab.
> > > 
> > > If yes, can someone give me some tips for what to do to mount a share
> > > named 
> > > \\server\~foo ?
> > > [...]
> > > It looks like mount command does not like ~ in the smb share name, 
> > though it 
> > > is fine with ~ in the the mount point name.
> > 
> That's a shell issue not a mount issue. ~foo refers to the home 
> directory of user foo. Either escape the ~ or quote the argument 
> containing the ~.

Hi Thorsten,

Thank you for the quick reply, however I still could not make it work:
mount //server/\176foo /mnt/foo
prints out no error, as if everything works out, however
ls /mnt/foo
errors out with 'no such file or directory'.
>From my experiments, the mount is not performed successfully in spite of
no errors printed out. The mount commands succeeds only because
//server/\176foo path is interpreted as //server/176foo; and since it is not
checked for existence, doing the subsequent ls /mnt/foo prints out
the error.

Moreover, in the same shell (bash/mintty), this works:
ls //server/~foo
(returns the right set of files), so if this is truly a shell issue,
why does ls work?
As a side note, ls //server/\176foo does not work (prints out 'No such file
or directory').

If you (or anyone else) have any other ideas, I would appreciate it.
Lastly, has anyone tried this and got it to work on their machine using the
current cygwin version? If yes, can you please post your exact 
fstab entry (or mount command)?

BTW, the mount version I'm using is 1.7.11 (I updated cygwin couple of days
ago).

TIA,
Daniel



--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



c++ header file for in which cygwin package?

2011-05-07 Thread ankur d

Hi,

Is anybody here knowing where exactly this c++  header file
exists in Cygwin package? Because I have downloaded all the packages under
development branch of cygwin. I can see other standard header files like
stdio.h, stdlib.h, etc. but this exception.h is not there. 

Thanks.
-- 
View this message in context: 
http://old.nabble.com/c%2B%2B-header-file-for-%3Cexception%3E-in-which-cygwin-package--tp31564589p31564589.html
Sent from the Cygwin list mailing list archive at Nabble.com.


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: c++ header file for in which cygwin package?

2011-05-07 Thread ankur d



Csaba Raduly-2 wrote:
> 
> On Sat, May 7, 2011 at 10:10 AM, ankur d  wrote:
>>
>> Hi,
>>
>> Is anybody here knowing where exactly this c++  header file
>> exists in Cygwin package? Because I have downloaded all the packages
>> under
>> development branch of cygwin. I can see other standard header files like
>> stdio.h, stdlib.h, etc. but this exception.h is not there.
>>
> 
> $ find /lib/gcc/i686-pc-cygwin/ -name exception
> /lib/gcc/i686-pc-cygwin/3.4.4/include/c++/exception
> /lib/gcc/i686-pc-cygwin/4.3.4/include/c++/exception
> 
> The C headers "belong" to to the system, so they are under /usr/include.
>  is a C++ header and as such it belongs to GCC (g++)
> 
> If you don't have the above files, then you don't have g++ installed.
> 
> See also
> 
> http://cygwin.com/cgi-bin2/package-grep.cgi?grep=exception%24
> 
> Hope this helps,
> Csaba
> -- 
> GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++
> The Tao of math: The numbers you can count are not the real numbers.
> Life is complex, with real and imaginary parts.
> "Ok, it boots. Which means it must be bug-free and perfect. " -- Linus
> Torvalds
> "People disagree with me. I just ignore them." -- Linus Torvalds
> 
> --
> Problem reports:   http://cygwin.com/problems.html
> FAQ:   http://cygwin.com/faq/
> Documentation: http://cygwin.com/docs.html
> Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
> 
> 
> 

Hey, 

Thanks for the reply. These packages were already installed, but I was
looking for exception header file under "\Cygwin\usr\include\" as other
headers mentioned above (stdio.h, stdlib.h, etc.) were present in this
directory.

Thanks.

-- 
View this message in context: 
http://old.nabble.com/c%2B%2B-header-file-for-%3Cexception%3E-comes-under-which-cygwin-package--tp31564589p31565339.html
Sent from the Cygwin list mailing list archive at Nabble.com.


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



  1   2   3   4   5   6   7   8   >