VOGONS

Common searches


Mouse copy/paste support

Topic actions

Reply 40 of 151, by truth_deleted

User metadata

Since the clipboard patch requires a 3rd party library, it may be worthwhile to detect that library by the method in a previous post in this thread (edit to the configure.ac file). However, I didn't test it outside mingw. Also, before running configure it would be necessary to run "autogen.sh" (or the analog in VS).

In addition, the above could be accompanied by preprocessor directives so that the patch code is only compiled when the proper library is present:
#if C_CLIPBOARD
// Clipboard code
#endif

Reply 41 of 151, by Wengier

User metadata
Rank Member
Rank
Member
truth5678 wrote:
Since the clipboard patch requires a 3rd party library, it may be worthwhile to detect that library by the method in a previous […]
Show full quote

Since the clipboard patch requires a 3rd party library, it may be worthwhile to detect that library by the method in a previous post in this thread (edit to the configure.ac file). However, I didn't test it outside mingw. Also, before running configure it would be necessary to run "autogen.sh" (or the analog in VS).

In addition, the above could be accompanied by preprocessor directives so that the patch code is only compiled when the proper library is present:
#if C_CLIPBOARD
// Clipboard code
#endif

I have added preprocessor directives to the source files related to the clipboard. Source files related to this feature have been zipped and attached. I have also attached in diff format.

Attachments

  • Filename
    srcchgs.zip
    File size
    44.83 KiB
    Downloads
    54 downloads
    File license
    Fair use/fair dealing exception
  • Filename
    patch.diff
    File size
    59.69 KiB
    Downloads
    60 downloads
    File license
    Fair use/fair dealing exception

Reply 43 of 151, by emendelson

User metadata
Rank Oldbie
Rank
Oldbie

On OS X, using a build script supplied by Dominus some years ago, I can build DOSBox with Wengier's new copy/paste code, but I can't figure out how to get the curses library integrated, so the copy/paste function doesn't work.

This is probably the result of my ignorance, so I'll be grateful for any help. I tried compiling PDCurses, but it needs X on the system, and X isn't installed on recent OS X systems. I wasn't able to compile Ncurses, which may be the way to go. Has anyone got any further with this?

Reply 44 of 151, by Dominus

User metadata
Rank DOSBox Moderator
Rank
DOSBox Moderator

In the makefile you need to add pdcurses libs a file, but that doesn't matter if it doesn't compile.
Download and install xquartz maybe it will compile with that.
BUT if x is needed for the copy/paste you are not much better off than with gtk ;(
AND you will find yourself in OS X' dll hell if you want to maje your build available ;(
I haven't had time to test this myself yet...

Windows 3.1x guide for DOSBox
60 seconds guide to DOSBox
DOSBox SVN snapshot for macOS (10.4-11.x ppc/intel 32/64bit) notarized for gatekeeper

Reply 45 of 151, by emendelson

User metadata
Rank Oldbie
Rank
Oldbie

That's what I was afraid of...! I'm trying to avoid installing xquartz in my main system, in order to stop myself from distributing anything that needs it on the user's system. I'll try to experiment on a VMware setup later on, but will glad to know what you find out when you get a chance to try it.

Reply 46 of 151, by Wengier

User metadata
Rank Member
Rank
Member

I have re-checked the officially supported platforms of PDCurses, which are DOS, OS/2, Win32, X11 and SDL. Probably you should use PDCurses-SDL instead of PDCurses-X11 on Mac OS X. I don't have OS X to test it personally though.

Reply 48 of 151, by emendelson

User metadata
Rank Oldbie
Rank
Oldbie

I've tried to compile the sdl version of pdcurses under OS X, but get an error message about not finding sdl.h. I've installed sdl-config via Macports, but it didn't help. I hope someone who knows what he or she is doing (as I don't) might be able to help, but I'll keep trying in the meantime.

Reply 49 of 151, by Wengier

User metadata
Rank Member
Rank
Member
emendelson wrote:

I've tried to compile the sdl version of pdcurses under OS X, but get an error message about not finding sdl.h. I've installed sdl-config via Macports, but it didn't help. I hope someone who knows what he or she is doing (as I don't) might be able to help, but I'll keep trying in the meantime.

Maybe try some links relating to the sdl.h not found error below?

http://stackoverflow.com/questions/20277477/h … k-folder-in-mac
http://stackoverflow.com/questions/9350375/er … le-or-directory
http://www.linuxquestions.org/questions/progr … s-there-133384/

Last edited by Wengier on 2014-10-26, 18:13. Edited 1 time in total.

Reply 50 of 151, by Wengier

User metadata
Rank Member
Rank
Member

For people who prefer a different color style for the mouse selection, I have attached the Windows binary (along with all required DLLs, zipped), and the updated mouse.cpp file.

Attachments

  • Filename
    dosbox.zip
    File size
    1.76 MiB
    Downloads
    65 downloads
    File license
    Fair use/fair dealing exception
  • Filename
    mouse.cpp
    File size
    32.78 KiB
    Downloads
    58 downloads
    File license
    Fair use/fair dealing exception

Reply 51 of 151, by emendelson

User metadata
Rank Oldbie
Rank
Oldbie
Wengier wrote:
Maybe try some links relating to the sdl.h not found error below? […]
Show full quote
emendelson wrote:

I've tried to compile the sdl version of pdcurses under OS X, but get an error message about not finding sdl.h. I've installed sdl-config via Macports, but it didn't help. I hope someone who knows what he or she is doing (as I don't) might be able to help, but I'll keep trying in the meantime.

Maybe try some links relating to the sdl.h not found error below?

http://stackoverflow.com/questions/20277477/h … k-folder-in-mac
http://stackoverflow.com/questions/9350375/er … le-or-directory
http://www.linuxquestions.org/questions/progr … s-there-133384/

Thank you, Wengier! I should have figured that out for myself, but I didn't. In my case, because I installed SDL via MacPorts, the command line I needed to use was this:

make -I/opt/local/include/SDL/ -lSDL

Now I have to figure out how to get libpdcurses.a built into DOSBox under OS X...

EDIT: I've attached a copy of libpdcurses.a compiled under Mavericks.

Attachments

  • Filename
    libpdcurses.a.zip
    File size
    62.5 KiB
    Downloads
    54 downloads
    File comment
    libpdcurses.a compiled under Mavericks
    File license
    Fair use/fair dealing exception

Reply 52 of 151, by Wengier

User metadata
Rank Member
Rank
Member
emendelson wrote:
Thank you, Wengier! I should have figured that out for myself, but I didn't. In my case, because I installed SDL via MacPorts, t […]
Show full quote
Wengier wrote:
Maybe try some links relating to the sdl.h not found error below? […]
Show full quote
emendelson wrote:

I've tried to compile the sdl version of pdcurses under OS X, but get an error message about not finding sdl.h. I've installed sdl-config via Macports, but it didn't help. I hope someone who knows what he or she is doing (as I don't) might be able to help, but I'll keep trying in the meantime.

Maybe try some links relating to the sdl.h not found error below?

http://stackoverflow.com/questions/20277477/h … k-folder-in-mac
http://stackoverflow.com/questions/9350375/er … le-or-directory
http://www.linuxquestions.org/questions/progr … s-there-133384/

Thank you, Wengier! I should have figured that out for myself, but I didn't. In my case, because I installed SDL via MacPorts, the command line I needed to use was this:

make -I/opt/local/include/SDL/ -lSDL

Now I have to figure out how to get libpdcurses.a built into DOSBox under OS X...

EDIT: I've attached a copy of libpdcurses.a compiled under Mavericks.

For getting libpdcurses built into DOSBox, have you tried the method in truth5678's earlier post that makes change to the configure file and my earlier post that adds the preprocessor directive?

Reply 53 of 151, by emendelson

User metadata
Rank Oldbie
Rank
Oldbie

Hello Wengier,

I've tried both techniques, but I don't seem to have the syntax correct for modifying the makefile to add libpdcurses.a.

The real expert in this is Dominus, and I'll hope that he'll have time to think about this before long. I'm simply stumbling around, and everything I know about building DOSBox on the Mac is what Dominus told me earlier...

Meanwhile, Wengier, thank you again for your generosity with help and with these terrific patches.

Reply 55 of 151, by emendelson

User metadata
Rank Oldbie
Rank
Oldbie

I tried both methods, but without success. The OS X build seems to require a set of interlocking kludges that Dominus worked out, and since he understands these things (I don't), I'll hope he gives it a try someday.

Reply 57 of 151, by emendelson

User metadata
Rank Oldbie
Rank
Oldbie

OK, please keep in mind that I don't know what I'm doing, and that so far, I have done only what Dominus told me to do, using a build script based on his suggestions. In trying to apply the CopyPaste patch, I did the following:

1. Starting with current SVN, I substituted all of Wengier's "srschanges" files for the SVN files.

2. I built libpcurses.a following suggestions in Wengier's earlier message.

3. I modified the build script that Dominus helped me put together by making these two changes: I added --enable-clipboard to the configure line and added the references to libpdcurses.a to the sed lines that modify the makefiles.

The build script I use is completely non-portable, because it refers to directories on my system. But, thanks to Dominus, it works when building SVN. I've attached it here.

By the way, the reason my script has all these complicated additions is that I want to build an executable that can be used on other people's systems, not only my own, so various libraries have to be built in.

Attachments

Reply 59 of 151, by truth_deleted

User metadata

I don't see where you submitted the library name to the linker: -lpdcurses. Also, did you ensure that curses.h was copied to /opt/local/include?

Did you inspect the config.log file to see if curses.h and pdcurses were detected? This assumes that the configure script was formatted properly for pdcurses detection in osx.

Edit: I inadvertently posted this after Wengier's post. His request for an error message would answer the 2nd question above.