472,951 Members | 1,855 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,951 software developers and data experts.

Writing a program under GNU/Linux for MS Windows.

Hi, I'm trying to write a program for a friend of mine who uses
windows but I use GNU/Linux. I know you can use mingw and link to the
python dll, but is there a way to create a win32 service under Linux?
Jul 18 '08 #1
3 1600
If you're just writing Python code then it will run unmodified on his
Windows machine.

Are you planning on using other languages too?

-----Original Message-----
From: py**************************************@python.or g
[mailto:py**************************************@py thon.org] On Behalf
Of Levi Campbell
Sent: Friday, July 18, 2008 4:27 PM
To: py*********@python.org
Subject: Writing a program under GNU/Linux for MS Windows.

Hi, I'm trying to write a program for a friend of mine who uses
windows but I use GNU/Linux. I know you can use mingw and link to the
python dll, but is there a way to create a win32 service under Linux?
--
http://mail.python.org/mailman/listinfo/python-list
Jul 18 '08 #2
On Jul 18, 3:26*pm, Levi Campbell <levicc00...@gmail.comwrote:
Hi, I'm trying to write a program for a friend of mine who uses
windows but I use GNU/Linux. I know you can use mingw and link to the
python dll, but is there a way to create a win32 service under Linux?
Technically, you can probably write the code for the service in Linux,
but I doubt you could test it. Here are some links on the subject,
though:

http://essiene.blogspot.com/2005/04/...-services.html
http://agiletesting.blogspot.com/200...s-windows.html

Mike
Jul 18 '08 #3
On 7/18/08, Levi Campbell <le*********@gmail.comwrote:
Hi, I'm trying to write a program for a friend of mine who uses
windows but I use GNU/Linux. I know you can use mingw and link to the
python dll, but is there a way to create a win32 service under Linux?
--
http://mail.python.org/mailman/listinfo/python-list
Hi Levi

(First off, I apologise if I sound a bit incoherent, but I've got flu
and I'm on medication :( )

After having just completed a project where had to write a windows
service I can offer you some insight. Writing of a service on windows,
as opposed to a daemon on linux/unix in python - you will need to use
the pywin32 module (http://sourceforge.net/projects/pywin32/)

The libraries in the pywin32 package you will need to use are most
likely going to be the followowing:
1) win32service
2) win32serviceutil
3) win32api
4) win32con and
5) servicemanager

The fact that the pywin32 package is just an interface to the win32api
means (as far as I understand) that [sadly] you will need to develop
this in windows.

Some stuff you might want to check out:
1) http://agiletesting.blogspot.com/200...s-windows.html
(I don't recommend this one - a bit dated)
2) http://groups.google.com/group/comp....75b8265f1b220f
(this is the template for the win32 service i finally used.)

Also as an interesting alternative, something I recently came across -
you can create a windows service, using the web2py web framework
(http://mdp.cti.depaul.edu/AlterEgo/default/show/77). This could save
you some time, as all the libraries/modules are already set up for you
in the source download
(http://mdp.cti.depaul.edu/examples/default/download)

Hope this helps.

Regards

Nicolaas

--
Peesowt
Jul 20 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Kevin T. Ryan | last post by:
Hi All - I'm not sure, but I'm wondering if this is a bug, or maybe (more likely) I'm misunderstanding something...see below: >>> f = open('testfile', 'w') >>> f.write('kevin\n') >>>...
3
by: Abby | last post by:
I'm now using Cygwin as my compiler for C code. I use Dev-c++ as my editor. The reason why I chose Cygwin compiler instead of the compiler that came with Dev-C++ is that I believe it uses the same...
5
by: Jeong-Gun Lee | last post by:
I'm writing a code of writing a value to a specific memory address. ================================================================= #include <stdio.h> int main() { long air; long...
6
by: Abubakar | last post by:
Hi, we are finding out ways in which we could develop libraries that could be written in c++ in a way that we can use them in windows, linux, and mac os. We want to write portable code, so that it...
12
by: Von Clubusev | last post by:
I like Java just as much as I like C#, but the truth is that unless you absolutely need platform portability, DotNet is the way to go. This is becoming even more true with the release of Windows...
5
by: Richard Giuly | last post by:
Hello, I would like to write "portable" C++ code that could theoretically run on linux, windows, and other platforms, and I'd like to use VS as the editor/compiler/linker. The simplest thing...
6
by: Cybex | last post by:
I am taking a C++ class and would like to use a Linux based IDE vs C+ + .Net but I am a little lost in how to go about this. I think that the IDE and compilation tools are separate under Linux. I...
4
by: junky_fellow | last post by:
guys, I need to write a program that should work on both windows and linux systems. I have to do lot of file handling (file creation, checking access permissions etc) and have to use lots of...
9
by: tdahsu | last post by:
All, I have the following code: for fileTarget in dircache.listdir("directory"): (dirName, fileName) = os.path.split(fileTarget) f = open(fileTarget).readlines() copying = False for i in...
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
0
by: Mushico | last post by:
How to calculate date of retirement from date of birth
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...
0
by: Aliciasmith | last post by:
In an age dominated by smartphones, having a mobile app for your business is no longer an option; it's a necessity. Whether you're a startup or an established enterprise, finding the right mobile app...
0
tracyyun
by: tracyyun | last post by:
Hello everyone, I have a question and would like some advice on network connectivity. I have one computer connected to my router via WiFi, but I have two other computers that I want to be able to...
3
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be using a very simple database which has Form (clsForm) & Report (clsReport) classes that simply handle making the calling Form invisible until the Form, or all...
1
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
0
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be focusing on the Report (clsReport) class. This simply handles making the calling Form invisible until all of the Reports opened by it have been closed, when it...
0
isladogs
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.