Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'core/org.eclipse.cdt.core.win32/library')
-rw-r--r--core/org.eclipse.cdt.core.win32/library/Makefile22
-rw-r--r--core/org.eclipse.cdt.core.win32/library/nmake.mak18
-rw-r--r--core/org.eclipse.cdt.core.win32/library/winreg.cpp4
3 files changed, 15 insertions, 29 deletions
diff --git a/core/org.eclipse.cdt.core.win32/library/Makefile b/core/org.eclipse.cdt.core.win32/library/Makefile
index 9f05e23b7c2..c00aa7f93e6 100644
--- a/core/org.eclipse.cdt.core.win32/library/Makefile
+++ b/core/org.eclipse.cdt.core.win32/library/Makefile
@@ -8,12 +8,13 @@ endif
OS = win32
ARCH = x86
-JDK_INCLUDES= $(JAVA_HOME)/include
-JDK_OS_INCLUDES= $(JAVA_HOME)/include/$(OS)
+JDK_INCLUDES= "$(JAVA_HOME)/include"
+JDK_OS_INCLUDES= "$(JAVA_HOME)/include/$(OS)"
CC=gcc
-CPPFLAGS = -I. -I$(JDK_INCLUDES) -I$(JDK_OS_INCLUDES)
-CFLAGS += -D_UNICODE -Dwchar_t=short
+CFLAGS = -DUNICODE -I$(JDK_INCLUDES) -I$(JDK_OS_INCLUDES)
+CXX=g++
+CXXFLAGS=$(CFLAGS)
INSTALL_DIR = ../os/$(OS)/$(ARCH)
@@ -21,15 +22,18 @@ LIB_NAME_SPAWNER = spawner.dll
LIB_NAME_FULL_SPAWNER = $(INSTALL_DIR)/spawner.dll
OBJS_SPAWNER=StdAfx.o Win32ProcessEx.o iostream.o raise.o spawner.o
-OBJS = $(OBJS_SPAWNER)
+WINREG = $(INSTALL_DIR)/winreg.dll
+OBJS_WINREG = winreg.o
-all: $(LIB_NAME_FULL_SPAWNER)
+all: $(LIB_NAME_FULL_SPAWNER) $(WINREG)
rebuild: clean all
$(LIB_NAME_FULL_SPAWNER) : $(OBJS_SPAWNER)
- mkdir -p $(INSTALL_DIR)
- $(CC) -Wl,--kill-at -g -shared -o $(LIB_NAME_FULL_SPAWNER) $(OBJS_SPAWNER)
+ $(CC) -Wl,--kill-at -shared -o $(LIB_NAME_FULL_SPAWNER) $(OBJS_SPAWNER)
clean :
- $(RM) $(OBJS_SPAWNER) $(LIB_NAME_FULL_SPAWNER)
+ $(RM) $(OBJS_SPAWNER) $(LIB_NAME_FULL_SPAWNER) $(OBJS_WINREG) $(WINREG)
+
+$(WINREG) : $(OBJS_WINREG)
+ $(CXX) -Wl,--kill-at -shared -o $(WINREG) $(OBJS_WINREG)
diff --git a/core/org.eclipse.cdt.core.win32/library/nmake.mak b/core/org.eclipse.cdt.core.win32/library/nmake.mak
deleted file mode 100644
index 16a16f92538..00000000000
--- a/core/org.eclipse.cdt.core.win32/library/nmake.mak
+++ /dev/null
@@ -1,18 +0,0 @@
-#*******************************************************************************
-# Copyright (c) 2005, 2006 QNX Software Systems
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# QNX Software Systems - initial API and implementation
-#*******************************************************************************
-TARGET = ..\os\win32\x86\winreg.dll
-
-OBJS = winreg.obj
-
-CPPFLAGS = /nologo /I C:\Java\jdk1.5.0_06\include /I C:\Java\jdk1.5.0_06\include\win32 /DUNICODE
-
-$(TARGET): $(OBJS)
- link /nologo /dll /out:$(TARGET) $(OBJS) advapi32.lib user32.lib
diff --git a/core/org.eclipse.cdt.core.win32/library/winreg.cpp b/core/org.eclipse.cdt.core.win32/library/winreg.cpp
index 2b06ad12966..81367b9e47c 100644
--- a/core/org.eclipse.cdt.core.win32/library/winreg.cpp
+++ b/core/org.eclipse.cdt.core.win32/library/winreg.cpp
@@ -13,7 +13,7 @@
#include <string.h>
extern "C"
-JNIEXPORT jstring Java_org_eclipse_cdt_utils_WindowsRegistry_getLocalMachineValue(
+JNIEXPORT jstring JNICALL Java_org_eclipse_cdt_utils_WindowsRegistry_getLocalMachineValue(
JNIEnv * env, jobject obj, jstring subkey, jstring name)
{
const jchar * csubkey = env->GetStringChars(subkey, NULL);
@@ -46,7 +46,7 @@ JNIEXPORT jstring Java_org_eclipse_cdt_utils_WindowsRegistry_getLocalMachineValu
*/
extern "C"
-JNIEXPORT jstring Java_org_eclipse_cdt_utils_WindowsRegistry_getLocalMachineValueName(
+JNIEXPORT jstring JNICALL Java_org_eclipse_cdt_utils_WindowsRegistry_getLocalMachineValueName(
JNIEnv * env, jobject obj, jstring subkey, jint index)
{
const jchar * csubkey = env->GetStringChars(subkey, NULL);

Back to the top