Page 1 of 2

Collecting all your DLLs?

Posted: Sun May 02, 2010 4:55 pm
by webfork
So I'm trying to save some space by putting duplicate DLLs all in one place and with good reason: here's just one screenshot of the hundreds of DLL files I've got in my portable collection:

Image

(click for larger image)

My idea:
  1. Put all the duplicate DLLs in that DLL subfolder (or maybe all the DLLs?)
  2. Run something like the below command to get everything in a "dll" subfolder

    @set path=%~dp0data\dll;%path%
Then can I delete all these space wasters and just dump all the DLL files in one unified folder? I know everyone here on the site could save some space in their collections that way. Thoughts?

Re: Collecting all your DLLs?

Posted: Sun May 02, 2010 9:15 pm
by guinness
I am intrigued, would this work though? I can imagine this will save MB's of space, I am always deleting unnecessary language files etc. Have you tested your idea?

Re: Collecting all your DLLs?

Posted: Sun May 02, 2010 9:59 pm
by Hydaral
That would have worked well a couple of years ago, it may not work so well now that Windows has Side by Side.

http://en.wikipedia.org/wiki/Side-by-side_assembly

Re: Collecting all your DLLs?

Posted: Mon May 03, 2010 3:13 am
by m^(2)
I use it for several years already.
Never had issues with SxS.
Had issues with GTK, I don't remember much about it except that I decided to keep it with applications.
Had issues with GhostScript, I didn't manage to use it portably.

Also, it's used by TC UP, though not to full extent.

Disclosure:
I'm a member of TC UP team.

Re: Collecting all your DLLs?

Posted: Mon May 03, 2010 2:45 pm
by webfork
Well that's good enough -- I'll give it a try over the next few weeks and report back. I'll start with common DLL files and then move on to more specialized ones. This process could easily save 50+ megs of space.

Re: Collecting all your DLLs?

Posted: Mon May 03, 2010 7:13 pm
by Hydaral
m^(2) wrote:Had issues with GhostScript, I didn't manage to use it portably.
Did you know that Ghostview comes with a portable executable?

http://www.portablefreeware.com/forums/ ... php?p=9475

See the third post by uksamo.

Re: Collecting all your DLLs?

Posted: Mon May 03, 2010 10:33 pm
by m^(2)
Hydaral wrote:
m^(2) wrote:Had issues with GhostScript, I didn't manage to use it portably.
Did you know that Ghostview comes with a portable executable?

http://www.portablefreeware.com/forums/ ... php?p=9475

See the third post by uksamo.
Thanks.

Re: Collecting all your DLLs?

Posted: Wed May 05, 2010 5:47 pm
by stanmarsh
hi webfork,

i would also like to do this to save space, have you tried using symbolic links? i just found out about it today here http://www.howtogeek.com/howto/16226/co ... -or-linux/. it looks like it can be an alternative way to save space.

Re: Collecting all your DLLs?

Posted: Wed May 05, 2010 10:28 pm
by m^(2)
stanmarsh wrote:hi webfork,

i would also like to do this to save space, have you tried using symbolic links? i just found out about it today here http://www.howtogeek.com/howto/16226/co ... -or-linux/. it looks like it can be an alternative way to save space.
Symlinks don't work on FAT file system, which is used by a majority of pendrives.
And actually I don't see how would you use it...

Re: Collecting all your DLLs?

Posted: Thu May 06, 2010 5:28 pm
by stanmarsh
hi m^(2),

i tested junction using the command line ln.exe by Hermann Schinagl and its working great! :)

this is just another alternative to save space, i was thinking of a common files(libraries) folder, similar to portableapps common files folder but we will use symlink/junction so that other program can use it aswell, here you put all your common files like dlls, java, gtk, or any file that other program may also use, this will minimize duplicates, saves space and you can centralize the updates for dlls, java and other common files.

i just use java as an example using junction, you can symlink specific dlls to apps as needed, haven't tested it though, but i think it should work.

Example for Java

Common Files/Common Libraries
-Java (size approx 86mb)

OpenofficePortable [portableapps]
-App
-Java [Junction] (- 86mb)

X-Jampal_1.23_rev7.zip [winpenpack]
-Bin
-Lib
-Java [Junction] (- 86mb)

Freemind [app that needs java to run]
-App
-Java [Junction] (- 86mb)

the problem with this approach is at first you have to replace files to symlink/junction.
it would be easier if it can be automated with a gui.


cheers

Re: Collecting all your DLLs?

Posted: Thu May 06, 2010 9:34 pm
by m^(2)
Oh, you're fixing inflexible portabilisations this way. I see.

Re: Collecting all your DLLs?

Posted: Wed May 19, 2010 2:36 pm
by webfork
So I tackled this issue again today...

Testing MSVCR71.DLL:
    1. Ran a search to find the DLLs
    2. Unfortunately there were two. One is 162k and the other 340k, both with the exact same name. The one I originally saved from the PortableFreeware "required files" one was 340k.
    3. I ran "Hash" on the 340k files to make sure they were the same and sure enough they all came out the same.
    Four programs use this DLL:
    • * WinMerge
      * Universal Viewer
      * Rainlendar
      * TaskCoach
    I deleted their DLLs, saving only ~1.3 megs of space. All four programs seemed to work fine. Looks like this one passed.

    Verdict: success

Testing GDIPLUS.DLL
  • This file is much larger and there are more of them so there's a much greater opportunity for saving space. Unfortunately every single version of this file had a different size, indicating different versions.
    • * Photoscape
      * Audioextractor
      * EraserDrop
      * TaskCoach
    All programs seemed to work fine so the different versions didn't seem to cause an issue.

    Space savings was about 5 megs.

    Verdict: success

    Note: There were two GDIPLUS files in OpenOffice but given the complexity of this program its possible components use it and not the actual program so it would be difficult to test if the lack of DLL immediately caused problems. Will leave those alone.
----

So far the DLL removal process looks promising. The three DLLs I removed caused no problems at all.

Coming up...
  • * Test "wholesale" and delete 100+ DLL files.
    * Test on a "clean" Windows XP install and see if there are similar problems.

Re: Collecting all your DLLs?

Posted: Mon May 31, 2010 1:00 pm
by guinness
Any news?

Re: Collecting all your DLLs?

Posted: Mon May 31, 2010 3:40 pm
by webfork
Nothing yet -- I've been tackling a few other problems of late before the DLL one. A lot of software testing for GPG4USB and playing with project management and mindmap / visio-style apps. Productivity stuff.

Re: Collecting all your DLLs?

Posted: Wed Feb 13, 2013 12:57 am
by Marc
What about using hard links in order to link the required dlls to the application folder.
Also I'm not sure if I recap correctly, but this reminds me of some kind of optimization for the libraries of linux portable apps.

Edit: That may not work for FAT32, it might otherwise be suitable for external hard drives.

Edit2: Missed earlier posts, fast reading and tiredness to blame.