Skip to content

Commit 5d373d6

Browse files
akaveltike
authored andcommitted
builds in mingw, but doesn't work
1 parent 8ad76f3 commit 5d373d6

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

GOnpp/goCommands/goCommand.cpp

+3-2
Original file line numberDiff line numberDiff line change
@@ -169,16 +169,17 @@ BOOL goCommand::initializeGoVals(void){
169169
return FALSE;
170170
}
171171

172-
dir = _tcstok_s(dir, pathSep, &pkg);
172+
dir = _tcstok(dir, pathSep);
173173
_tcsncpy(this->goPath, dir, _tcslen(dir)+1);
174174
while(dir != NULL){
175+
pkg = dir + _tcslen(dir) + 1;
175176
if (_tcscmp(dir, TEXT("src")) == 0){
176177
_tcsncpy(this->goPkg, pkg, _tcslen(pkg)+1);
177178
free(start_address);
178179
return TRUE;
179180
}
180181
PathAppend(this->goPath, dir);
181-
dir = _tcstok_s(NULL, pathSep, &pkg);
182+
dir = _tcstok(NULL, pathSep);
182183
}
183184
free(start_address);
184185
return FALSE;

makefile

+4-4
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ WINDRES = windres -O coff
3838
CFLAGS = -O2 -mtune=i686 -DBUILD_DLL -W -Wall -gstabs -mwindows \
3939
$(foreach dir,$(SRC_DIRS),-I$(dir)) \
4040
-DUNICODE -D_UNICODE
41-
LIBS = -lws2_32 -lz -lm -Wl,-Map,$@.map,--cref -static-libgcc
42-
LDFLAGS = -Wl,--out-implib,$(TARGET) -shared -lshlwapi $(CFLAGS)
41+
LIBS = -lws2_32 -lm -Wl,-Map,$@.map,--cref -static-libgcc -lshlwapi
42+
LDFLAGS = -Wl,--out-implib,$(TARGET) -shared $(CFLAGS)
4343
OBJDIR = .objs
4444

4545
#INSTALL_PATH = "C:\\Program Files\\Notepad++\\plugins\\"
@@ -92,9 +92,9 @@ $(OBJDIR)/%.o: %.cpp
9292

9393
$(TARGET): $(OBJS)
9494
@echo Linking $@
95-
@$(CC) -o $@ $(LDFLAGS) $(OBJS) $(LIBS)
95+
@$(CXX) -o $@ $(LDFLAGS) $(OBJS) $(LIBS)
9696

97-
$(OBJDIR)/%.res: %.rc %.ico %.h
97+
$(OBJDIR)/GOnpp/DockingFeature/goLine.res: GOnpp/DockingFeature/goLine.rc GOnpp/DockingFeature/resource.h
9898
@$(call MKDIR-P,$(call dirname,$@))
9999
@$(WINDRES) -o $@ $<
100100

0 commit comments

Comments
 (0)