New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Patch: Enable Mutex on Windows #483

Open
aspell-helper opened this Issue May 16, 2011 · 5 comments

Comments

Projects
None yet
1 participant
@aspell-helper
Collaborator

aspell-helper commented May 16, 2011

Stephen J. Muir <yadancer@sf> created a patch on 2011-05-16 10:11:06 UTC
(Orig. from https://sourceforge.net/p/aspell/patches/167)

When compiling on Windows without Posix mutexes, the Mutex lock/unlock methods do nothing.

The Windows equivalent of the Posix mutex is the critical section, and this patch uses this to implement the lock/unlock methods.

@aspell-helper

This comment has been minimized.

Show comment
Hide comment
@aspell-helper

aspell-helper May 18, 2011

Collaborator

Kevin Atkinson <kevina@sf> commented on 2011-05-18 00:02:50 UTC

Thanks. It would be really helpful if you could attach a real patch file like you did for the more recent reports. Please do it in this report. If for some reason you don't have permission to delete the old file I will.

Collaborator

aspell-helper commented May 18, 2011

Kevin Atkinson <kevina@sf> commented on 2011-05-18 00:02:50 UTC

Thanks. It would be really helpful if you could attach a real patch file like you did for the more recent reports. Please do it in this report. If for some reason you don't have permission to delete the old file I will.

@aspell-helper

This comment has been minimized.

Show comment
Hide comment
@aspell-helper

aspell-helper May 18, 2011

Collaborator

Stephen J. Muir <yadancer@sf> commented on 2011-05-18 09:30:39 UTC

windows_lock.patch

Collaborator

aspell-helper commented May 18, 2011

Stephen J. Muir <yadancer@sf> commented on 2011-05-18 09:30:39 UTC

windows_lock.patch

@aspell-helper

This comment has been minimized.

Show comment
Hide comment
@aspell-helper

aspell-helper May 18, 2011

Collaborator

Stephen J. Muir <yadancer@sf> commented on 2011-05-18 09:31:17 UTC

Replaced source with patch as requested.

Collaborator

aspell-helper commented May 18, 2011

Stephen J. Muir <yadancer@sf> commented on 2011-05-18 09:31:17 UTC

Replaced source with patch as requested.

@aspell-helper

This comment has been minimized.

Show comment
Hide comment
@aspell-helper

aspell-helper May 18, 2011

Collaborator

Kevin Atkinson <kevina@sf> commented on 2011-05-18 11:37:21 UTC

Thanks, I can see the changes more clearly now.

Is there a reason you do not what to include "Windows.h" in the "lock.hpp" header file? Is this some huge file which will not normally be included in a windows program?

Collaborator

aspell-helper commented May 18, 2011

Kevin Atkinson <kevina@sf> commented on 2011-05-18 11:37:21 UTC

Thanks, I can see the changes more clearly now.

Is there a reason you do not what to include "Windows.h" in the "lock.hpp" header file? Is this some huge file which will not normally be included in a windows program?

@aspell-helper

This comment has been minimized.

Show comment
Hide comment
@aspell-helper

aspell-helper May 18, 2011

Collaborator

Stephen J. Muir <yadancer@sf> commented on 2011-05-18 11:44:22 UTC

I couldn't get it to build with Windows.h in the header file because the compiler complains about duplicate definitiions between acommon::IOStream and Windows IOStream. It somehow thought that the Windows IOStream was in the acommon namespace even though I placed it before the namespace declaration.

I manually checked the pre-processed only .i file and came to the conclusion that it's a compiler bug because the .i file looked ok.

Collaborator

aspell-helper commented May 18, 2011

Stephen J. Muir <yadancer@sf> commented on 2011-05-18 11:44:22 UTC

I couldn't get it to build with Windows.h in the header file because the compiler complains about duplicate definitiions between acommon::IOStream and Windows IOStream. It somehow thought that the Windows IOStream was in the acommon namespace even though I placed it before the namespace declaration.

I manually checked the pre-processed only .i file and came to the conclusion that it's a compiler bug because the .i file looked ok.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment