Go Back   Winamp Forums > Developer Center > NSIS Discussion

Reply
Thread Tools Search this Thread Display Modes
Old 12th January 2008, 10:39   #1
zoranlazarevic
Junior Member
 
Join Date: Sep 2004
Posts: 11
Installer enabling DSP plugins for Single User and Multi User Installations

Does anyone have a script for detecting whether Winamp is installed in a single-user or multi-user configuration?

I have an old installer that enables a Winamp DSP plugin by writing to "Winamp.ini"

code:
WriteINIStr "$4\Winamp.ini" "Winamp" "dspplugin_name" "dsp_MY_PLUGIN.dll"


However, Winamp can now be installed in multi-user setup, so "Winamp.ini" can actually be in the user's "Documents and Settings" folder, not in "Program Files/Winamp". Now my installer modifies wrong "Winamp.ini" and does not enable the plugin. How can I enable the plugin whether the Winamp installation is single or multi-user?

Thanks,

Zoran
zoranlazarevic is offline   Reply With Quote
Old 12th January 2008, 10:51   #2
Anders
Moderator
 
Anders's Avatar
 
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 2,784
check (for) paths.ini first maybe

IntOp $PostCount $PostCount + 1
Anders is offline   Reply With Quote
Old 27th January 2008, 05:37   #3
zoranlazarevic
Junior Member
 
Join Date: Sep 2004
Posts: 11
After tinkering with NSIS, here is th solution to an installer that enables/activates a Winamp DSP plugin in both machine-wide and multi-user Winamp installations.
  • The installer looks for Winamp.ini (computer-wide Winamp installation).
    Failing that it looks for Paths.ini.
    Then it reads Paths.ini for determine the location of user-specific Winamp.ini.
    Finally, it updates Winamp.ini to activate the DSP plugin.

Laza
Attached Files
File Type: nsi installer_that_enables_dsp_plugin.nsi (9.5 KB, 68 views)
zoranlazarevic is offline   Reply With Quote
Reply
Go Back   Winamp 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