summaryrefslogtreecommitdiffstats
path: root/win/vncconfig
diff options
context:
space:
mode:
authorAdam Tkac <atkac@redhat.com>2009-10-12 15:54:59 +0000
committerAdam Tkac <atkac@redhat.com>2009-10-12 15:54:59 +0000
commit934f63cba1bf9646e3fd40b9575930e8c3371853 (patch)
tree92da01c0baccbb4182f656e0a541d6663291606b /win/vncconfig
parent8517ea56a741f728ef290f54b77d736251f04b22 (diff)
downloadtigervnc-934f63cba1bf9646e3fd40b9575930e8c3371853.tar.gz
tigervnc-934f63cba1bf9646e3fd40b9575930e8c3371853.zip
Make winvnc4 and Windows vncconfig compilable via MinGW.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@3913 3789f03b-4d11-0410-bbf8-ca57d06f2519
Diffstat (limited to 'win/vncconfig')
-rw-r--r--win/vncconfig/Connections.h6
-rw-r--r--win/vncconfig/Desktop.h4
-rw-r--r--win/vncconfig/Legacy.cxx2
-rw-r--r--win/vncconfig/Makefile.am20
4 files changed, 26 insertions, 6 deletions
diff --git a/win/vncconfig/Connections.h b/win/vncconfig/Connections.h
index 7512cc65..209e4fd8 100644
--- a/win/vncconfig/Connections.h
+++ b/win/vncconfig/Connections.h
@@ -62,7 +62,7 @@ namespace rfb {
pattern.replaceBuf(0);
}
bool onOk() {
- TCharArray host = getItemString(IDC_HOST_PATTERN);
+ TCharArray host(getItemString(IDC_HOST_PATTERN));
TCharArray newPat(_tcslen(host.buf)+2);
if (isItemChecked(IDC_ALLOW))
newPat.buf[0] = _T('+');
@@ -248,8 +248,8 @@ namespace rfb {
}
bool isChanged() {
try {
- CharArray new_hosts = getHosts();
- CharArray old_hosts = hosts.getData();
+ CharArray new_hosts(getHosts());
+ CharArray old_hosts(hosts.getData());
return (strcmp(new_hosts.buf, old_hosts.buf) != 0) ||
(localHost != isItemChecked(IDC_LOCALHOST)) ||
(port_number != getItemInt(IDC_PORT)) ||
diff --git a/win/vncconfig/Desktop.h b/win/vncconfig/Desktop.h
index 164269a2..6479cb26 100644
--- a/win/vncconfig/Desktop.h
+++ b/win/vncconfig/Desktop.h
@@ -32,7 +32,7 @@ namespace rfb {
DesktopPage(const RegKey& rk)
: PropSheetPage(GetModuleHandle(0), MAKEINTRESOURCE(IDD_DESKTOP)), regKey(rk) {}
void initDialog() {
- CharArray action = rfb::win32::SDisplay::disconnectAction.getData();
+ CharArray action(rfb::win32::SDisplay::disconnectAction.getData());
bool disconnectLock = stricmp(action.buf, "Lock") == 0;
bool disconnectLogoff = stricmp(action.buf, "Logoff") == 0;
typedef BOOL (WINAPI *_LockWorkStation_proto)();
@@ -59,7 +59,7 @@ namespace rfb {
case IDC_REMOVE_WALLPAPER:
case IDC_REMOVE_PATTERN:
case IDC_DISABLE_EFFECTS:
- CharArray action = rfb::win32::SDisplay::disconnectAction.getData();
+ CharArray action(rfb::win32::SDisplay::disconnectAction.getData());
bool disconnectLock = stricmp(action.buf, "Lock") == 0;
bool disconnectLogoff = stricmp(action.buf, "Logoff") == 0;
setChanged((disconnectLogoff != isItemChecked(IDC_DISCONNECT_LOGOFF)) ||
diff --git a/win/vncconfig/Legacy.cxx b/win/vncconfig/Legacy.cxx
index ae5d7166..f8c20280 100644
--- a/win/vncconfig/Legacy.cxx
+++ b/win/vncconfig/Legacy.cxx
@@ -71,7 +71,7 @@ void LegacyPage::LoadPrefs()
// Reformat AuthHosts to Hosts. Wish I'd left the format the same. :( :( :(
try {
- CharArray tmp = strDup(authHosts.buf);
+ CharArray tmp(authHosts.buf);
while (tmp.buf) {
// Split the AuthHosts string into patterns to match
diff --git a/win/vncconfig/Makefile.am b/win/vncconfig/Makefile.am
new file mode 100644
index 00000000..17420b0b
--- /dev/null
+++ b/win/vncconfig/Makefile.am
@@ -0,0 +1,20 @@
+bin_PROGRAMS = vncconfig
+
+HDRS = Authentication.h Connections.h Desktop.h Hooking.h Inputs.h Legacy.h \
+ PasswordDialog.h resource.h Sharing.h
+
+vncconfig_SOURCES = $(HDRS) Legacy.cxx PasswordDialog.cxx vncconfig.cxx
+
+vncconfig_CPPFLAGS = -I$(top_srcdir)/win -I$(top_srcdir)/common
+
+vncconfig_LDADD = $(top_srcdir)/win/rfb_win32/librfb_win32.la \
+ $(top_srcdir)/common/rfb/librfb.la \
+ $(top_srcdir)/common/Xregion/libXregion.la \
+ $(top_srcdir)/common/network/libnetwork.la \
+ $(top_srcdir)/common/rdr/librdr.la -lws2_32 -lgdi32 -lversion -lole32 \
+ -lcomctl32 resources.o
+
+EXTRA_DIST = connected.ico vncconfig.ico vncconfig.rc vncconfig.exe.manifest
+
+resources.o: vncconfig.rc
+ $(WINDRES) $^ -o $@