Old 15th February 2005, 12:47   #1
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
About Plugins

Hello

I know that these are questions too generals but ...

a)Is better to do the plugins with c or with c++ or is indiferent ?

b)The plugins in plugins/contrib have the files *.dsp and *.dsw . I think that these are files of Visual C++ . Is better to use it?

c)Whats compiler is better to use ? Dev-c++, lcc32, visual c++ ...?

Thanks in advance
kike_velez is offline   Reply With Quote
Old 15th February 2005, 14:09   #2
Joel
Debian user
(Forum King)
 
Joel's Avatar
 
Join Date: Jan 2003
Location: Arch land
Posts: 4,917
a) Whatever, dude .... but if you are in c++, remember to add the extern "C" thingy...

b) Visual Studio 4 and up (even .NET) can handle them... I think Dev-C++ use it as project converter...

c) Most of the source code are in Visual Studio 6 nor .NET. but you can open the the files (.c, .cpp, .h) in other IDEs and change whatever you need to change.... of course you need to know the syntax of the compiler.... for example MinGW, which comes in DEv-C++,isn't 100% compatible with the Visual C++ syntax.... <_<


* PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux-i686 with MATE.
* Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Archlinux-x86-64 with MATE.
Joel is offline   Reply With Quote
Old 15th February 2005, 19:25   #3
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
The Microsoft compiler produces smaller executables. You can use the new free toolkit in combination with the Platform SDK.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 16th February 2005, 07:44   #4
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
Thanks a lot

@kichik :: Your second link don´t work . Can you attach the link again? Thanks

BTW , The free toolkit can work with projects ? I thought that it can work only with a simple file (a limitation).


Thanks in advance
kike_velez is offline   Reply With Quote
Old 16th February 2005, 07:49   #5
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Platform SDK - http://www.microsoft.com/msdownload/...sdk/sdkupdate/

I don't know if the toolkit works with project files, but nothing stops you from calling cl.exe on your own. cl.exe accepts more than one file.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 16th February 2005, 07:57   #6
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
Thanks Kichik

You starts to work early

Best Regards
kike_velez is offline   Reply With Quote
Old 16th February 2005, 08:13   #7
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
Hello again

I see the link and there´s "Windows XP SP2 Platform SDK" but this not talk about win95,win98,.. That would to say that if I do a plugin with this sdk this plugin wouldn´t be compatible with the others operative sistems (win95,win98)?.

Thanks in advance

Note :: Sorry if this is an trivial question
kike_velez is offline   Reply With Quote
Old 16th February 2005, 08:17   #8
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
No, it doesn't mean it won't work on versions other than XP SP2. It simply means it contains the tools required to build applications that take advantage of the new features XP SP2 has to offer.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 16th February 2005, 08:23   #9
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
Thanks a lot
kike_velez is offline   Reply With Quote
Old 17th March 2005, 12:45   #10
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
Hello

I install the Visual C++ Toolkit 2003 and the SDK.
The configuration of the shortcut is:
PHP Code:
Set PATH=C:\Archivos de programa\Microsoft Visual C++ Toolkit 2003\bin;%PATH%
Set INCLUDE=C:\Archivos de programa\Microsoft Visual C++ Toolkit 2003\include;%INCLUDE%
Set INCLUDE=%INCLUDE%;C:\Archivos de programa\Microsoft Platform SDK for Windows XP SP2\Include
Set LIB=C:\Archivos de programa\Microsoft Visual C++ Toolkit 2003\lib;%LIB%
Set LIB=%LIB%;C:\Archivos de programa\Microsoft Platform SDK for Windows XP SP2\lib 
But when I compile the exdll.c (with the exdll.h) I see this error:

With this sentence Cl exdll.c /LD

PHP Code:
/out:exdll.dll
/dll
/implib:exdll.lib
exdll
.obj
   Creating library exdll
.lib and object exdll.exp
exdll
.obj error LNK2019unresolved external symbol _
renced in 
function _myFunction
exdll
.obj error LNK2019unresolved external symbol _
d in 
function _myFunction
exdll
.dll fatal error LNK11202 unresolved externals 
a) What I am doing wrong?

b) The sentence is the correct? What´s the sentence to do the dll more fast, little and good?

The help of cl.exe (cl /?) is (see file attached).

Thanks in advance
Attached Files
File Type: txt clhelp.txt (5.2 KB, 240 views)
kike_velez is offline   Reply With Quote
Old 17th March 2005, 17:34   #11
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
The error messages got trimmed, but according to the posted command line you've used, it seems you forgot to include a list of libraries to link to. In ExDLL's case, only kernel32.lib is needed. More complicated plug-ins may require more libraries.

To get the smallest plug-in possible you need some more switches. Below is an example of compiling the UserInfo plug-in with these switches:

cl /O1 UserInfo.c /LD kernel32.lib advapi32.lib /link /OPT:NOWIN98 /NODEFAULTLIB /ENTRY:DllMain

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 18th March 2005, 08:29   #12
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
Thanks for your reply but the errors continues .
With this sentence :

cl /O1 exdll.c /LD kernel32.lib

The errors are :

PHP Code:
/out:exdll.dll
/dll
/implib:exdll.lib
exdll
.obj
kernel32
.lib
   Creating library exdll
.lib and object exdll.exp
exdll
.obj error LNK2019unresolved external symbol __imp__MessageBoxA@16 refe
renced in 
function _myFunction
exdll
.obj error LNK2019unresolved external symbol __imp__wsprintfA reference
d in 
function _myFunction
exdll
.dll fatal error LNK11202 unresolved externals 
Thanks in advance
kike_velez is offline   Reply With Quote
Old 18th March 2005, 11:36   #13
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Use user32.lib too. For each error like that, go to MSDN and look for the "missing" API function. On the very bottom of the MSDN page, it says which library is required.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 18th March 2005, 11:58   #14
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
That works ¡¡¡

The correct sentece is :

cl /O1 exdll.c /LD /link kernel32.lib user32.lib

And creates a exdll.dll with 40kb. Is a normal size?

Thanks
kike_velez is offline   Reply With Quote
Old 18th March 2005, 12:01   #15
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
No, it's way too big. Use the extra command line options I mentioned above.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 18th March 2005, 12:21   #16
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
This works¡¡¡

cl /O1 exdll.c /LD /link kernel32.lib user32.lib /
OPT:NOWIN98 /NODEFAULTLIB /ENTRYllMain


And now have only 3kb¡¡¡

Thanks a lot
kike_velez is offline   Reply With Quote
Old 18th March 2005, 12:28   #17
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
This works¡¡¡

And now have only 3kb¡¡¡

cl /O1 exdll.c /LD /link kernel32.lib user32.lib /
OPT:NOWIN98 /NODEFAULTLIB /ENTRY:DllMain


Thanks a lot
kike_velez is offline   Reply With Quote
Old 14th May 2005, 02:14   #18
Joel
Debian user
(Forum King)
 
Joel's Avatar
 
Join Date: Jan 2003
Location: Arch land
Posts: 4,917
I also recomment C::B is an IDE for the Toolkit and is Open Source

I'm testing it know and seems to working OK


* PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux-i686 with MATE.
* Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Archlinux-x86-64 with MATE.
Joel is offline   Reply With Quote
Old 17th May 2005, 09:15   #19
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
Quote:
I also recomment C::B is an IDE for the Toolkit and is Open Source
I use Eclipse vith the toolkit but i have not a debugger.
What about with C::B ?
kike_velez is offline   Reply With Quote
Old 17th May 2005, 14:22   #20
Joel
Debian user
(Forum King)
 
Joel's Avatar
 
Join Date: Jan 2003
Location: Arch land
Posts: 4,917
Yes


* PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux-i686 with MATE.
* Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Archlinux-x86-64 with MATE.
Joel is offline   Reply With Quote
Old 24th August 2005, 12:57   #21
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
plugins for Windows and Linux

Hello

I know that the NSIS is port to Linux and BSD (I think).
Are there recomendations when we do plugins for that these can be useful on Windows or Linux machines ?

Best Regards
kike_velez is offline   Reply With Quote
Old 24th August 2005, 16:41   #22
onad
Senior Member
 
onad's Avatar
 
Join Date: Dec 2004
Location: Turkey
Posts: 447
Exclamation

For your understanding, you can make ,as in produce, a WINDOWS installer (SETUP.EXE) via makensis on a POSIX system, e.g. Linux.

This is very handy if you do a nightly build of a Windows Installer on a POSIX system.

So, NSIS is NOT used for creating runnable installers which target the Linux client PC.

For a working makensis on Linux, see screenshots on Suse 9.3.

Yes, if you look closly the finished build installer runs, but under WINE, that's why
Attached Images
File Type: jpg snapshot1.jpg (64.0 KB, 237 views)

"Just do it"
onad is offline   Reply With Quote
Old 25th August 2005, 08:48   #23
kike_velez
Member
 
Join Date: Jun 2004
Location: Barcelona
Posts: 57
Thanks
kike_velez is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump