Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

NT Services

0 views
Skip to first unread message

Radamanthe

unread,
Feb 2, 2007, 3:48:28 PM2/2/07
to
Hi everyone.

I have been unable to find a good starting point for developping
softwares intended to be used as "services" (deamons) on Windows NT
platforms (in C/C++). Can someone give me a link or something about
"services" ? This is a very common word, you know...

More specifically, is it possible to development such services with
open-source tools like Mingw without too much drawbacks (and without
using Visual Studio) ?

--
R.N.

PJ Naughter

unread,
Feb 2, 2007, 4:44:43 PM2/2/07
to

Not sure if it is exactly what you want, but there is an open source
MFC C++ library for developing NT Services on my web site at
www.naughter.com/serv.html. It will require Visual Studio to compile
but even so, you can use it as a reference for how to write a service
in C++. It also include some references for further research.

Regards,
PJ Naughter

Naughter Software
Mail: pjna at naughter.com
Web: www.naughter.com
Hotmail/MSN Messenger: pjnaughter at hotmail.com

It is finally on the shelves... the book from Joseph Gama and I:

http://www.amazon.com/Super-SQL-Server-Systems-Performance/dp/0976157322

Radamanthe

unread,
Feb 2, 2007, 4:55:39 PM2/2/07
to
PJ Naughter wrote:
> Not sure if it is exactly what you want, but there is an open source
> MFC C++ library for developing NT Services on my web site at
> www.naughter.com/serv.html. It will require Visual Studio to compile
> but even so, you can use it as a reference for how to write a service
> in C++. It also include some references for further research.

Thanks, I'll check that. I certainly won't use it because of MFC, but
it will be of great help !


--
R.N.

matevzb

unread,
Feb 2, 2007, 4:56:12 PM2/2/07
to
On Feb 2, 9:48 pm, Radamanthe <tek...@free.deleteme.fr> wrote:
> Hi everyone.
>
> I have been unable to find a good starting point for developping
> softwares intended to be used as "services" (deamons) on Windows NT
> platforms (in C/C++). Can someone give me a link or something about
> "services" ? This is a very common word, you know...
Service functions are at http://msdn2.microsoft.com/en-us/library/
ms685942.aspx.
Generally, any Windows specific search is best tried at http://
msdn.microsoft.com, especially those with common words.

> More specifically, is it possible to development such services with
> open-source tools like Mingw without too much drawbacks (and without
> using Visual Studio) ?
Yes, I've had no problems with mingw, it works in both C and C++.
--
WYCIWYG - what you C is what you get

Radamanthe

unread,
Feb 2, 2007, 5:30:46 PM2/2/07
to
matevzb wrote:
> On Feb 2, 9:48 pm, Radamanthe <tek...@free.deleteme.fr> wrote:
>> Hi everyone.
>>
>> I have been unable to find a good starting point for developping
>> softwares intended to be used as "services" (deamons) on Windows NT
>> platforms (in C/C++). Can someone give me a link or something about
>> "services" ? This is a very common word, you know...
> Service functions are at http://msdn2.microsoft.com/en-us/library/
> ms685942.aspx.
> Generally, any Windows specific search is best tried at http://
> msdn.microsoft.com, especially those with common words.

I did, but typing "services" in MSDN was not much help either :) But
"CreateService" was pretty more handy to reach the right subject without
browsing tons of pages (I'm in Europe and Microsoft's site tends to be
slow). By the way, is it possible to download those documents for local
browsing ?

Thank you anyway for pointing this out.

>> More specifically, is it possible to development such services with
>> open-source tools like Mingw without too much drawbacks (and without
>> using Visual Studio) ?
> Yes, I've had no problems with mingw, it works in both C and C++.

Thanks, I'm happy to hear that.


--
R.N.

matevzb

unread,
Feb 2, 2007, 6:22:36 PM2/2/07
to
On Feb 2, 11:30 pm, Radamanthe <tek...@free.deleteme.fr> wrote:
> matevzb wrote:
> > On Feb 2, 9:48 pm, Radamanthe <tek...@free.deleteme.fr> wrote:
> >> Hi everyone.
>
> >> I have been unable to find a good starting point for developping
> >> softwares intended to be used as "services" (deamons) on Windows NT
> >> platforms (in C/C++). Can someone give me a link or something about
> >> "services" ? This is a very common word, you know...
> > Service functions are athttp://msdn2.microsoft.com/en-us/library/

> > ms685942.aspx.
> > Generally, any Windows specific search is best tried at http://
> > msdn.microsoft.com, especially those with common words.
>
> I did, but typing "services" in MSDN was not much help either :) But
> "CreateService" was pretty more handy to reach the right subject without
> browsing tons of pages (I'm in Europe and Microsoft's site tends to be
> slow). By the way, is it possible to download those documents for local
> browsing ?
There's an Express edition of Visual Studio 2005 C++ (free!) which
includes MSDN Express. I think it contains _some_ of the
documentation, unfortunately it's been more focused on .NET lately.
You can find the download at http://msdn.microsoft.com/vstudio/express/
support/install.
I'm also in Europe but I'm not sure whether the slowness come from
(just) that, it's probably generic =)

xbunny

unread,
Feb 2, 2007, 7:05:03 PM2/2/07
to
Radamanthe wrote:

Download the platform SDK and look at the sample in
psdk\samples\winbase\service its written in C and should compile with
mingw, possibly the current psdk may not be compatable with mingw
however the sample uses no overly modern API's so I expect the windows
headers with mingw would be fine. The sample can easily be reused as all
you need to compile in service.c and implement ServiceStart and
ServiceStop in your application.

Bunny

0 new messages