--- q_a/samples/resdll/makefile 2018/08/09 18:29:28 1.1.1.2 +++ q_a/samples/resdll/makefile 2018/08/09 18:30:20 1.1.1.4 @@ -1,10 +1,12 @@ -# Nmake macros for building Windows 32-Bit apps - !include -all: main.exe the_dll.dll +!if "$(CPU)" == "i386" +noentry = /NOENTRY +!else +noentry = +!endif -# Update the object files if necessary +all: main.exe the_dll.dll main.obj: main.c $(cc) $(cdebug) $(cflags) $(cvars) main.c @@ -13,19 +15,13 @@ the_dll.rbj: the_dll.rc the_dll.bmp the_ rc -r -fo the_dll.res the_dll.rc cvtres -$(CPU) the_dll.res -o the_dll.rbj -# Update the dynamic link library - the_dll.dll: the_dll.def the_dll.rbj - $(link) $(linkdebug) \ - -base:0x1C000000 \ + $(link) \ -dll \ + $(noentry) \ -out:the_dll.dll \ - the_dll.rbj $(guilibs) - - -# Update the executable file if necessary. -# If so, add the resource back in. + -subsystem:windows \ + the_dll.rbj main.exe: main.obj main.def - $(cvtobj) $(cvtdebug) *.obj - $(link) $(linkdebug) $(guiflags) -out:main.exe main.obj $(guilibs) + $(link) $(linkdebug) $(guiflags) -out:main.exe main.obj $(guilibsdll)