Code::Blocks Forums

User forums => Using Code::Blocks => Topic started by: JerryKc0kk on June 28, 2018, 10:05:59 pm

Title: how do i deploy my program to others?
Post by: JerryKc0kk on June 28, 2018, 10:05:59 pm
hi

i wrote a program on my windows pc using codeblocks and gcc c++.

what is the easiest way to package and deploy the program to my users so they can install and run the program on their windows pc?

i found no solution in the manual or on the internet

jerry .. wa0h
Title: Re: how do i deploy my program to others?
Post by: sodev on June 28, 2018, 10:15:36 pm
i found no solution in the manual or on the internet

Not even the internet knows, how shall we know?!? :P

Although this is beyond the scope of this forum, how about https://en.wikipedia.org/wiki/List_of_installation_software (https://en.wikipedia.org/wiki/List_of_installation_software)? I would go with NSIS or Inno.
Title: Re: how do i deploy my program to others?
Post by: raynebc on June 29, 2018, 07:01:57 pm
I just provide the binary and resource files to my users as a zip file.
Title: Re: how do i deploy my program to others?
Post by: JerryKc0kk on July 01, 2018, 05:00:16 pm
i apologize, i should have been more specific.

when i asked (how do i deploy to another pc) i should have asked .. in codeblocks, how do i find the libraries and dlls that need to be included in the deploy package?

i built the program in release mode and copied the release .exe to the new pc but nothing happened when i tried to run it.

jerry
Title: Re: how do i deploy my program to others?
Post by: oBFusCATed on July 01, 2018, 06:31:01 pm
C::B doesn't provide such tools. You have to use tools like depends.exe or similar to find what is the minimal set of dlls you have to ship.
Title: Re: how do i deploy my program to others?
Post by: gd_on on July 01, 2018, 06:31:38 pm
You can try to use something as "Dependancy Walker".
An other solution is to make your soft static (no dll dependancies).
gd_on
Title: Re: how do i deploy my program to others?
Post by: raynebc on July 01, 2018, 07:15:51 pm
I did it the unsophisticated way:  Bring the program to another computer and note each DLL file it complained was missing when I tried to execute it.  Bring over each relevant file from the development computer (ie. from the compiler's bin folder) until the program does run without error.  After I knew the full set of needed files was assembled, I packaged them together and it's ready to distribute.
Title: Re: how do i deploy my program to others?
Post by: oBFusCATed on July 01, 2018, 09:17:48 pm
@raynebc: This is not reliable. You need to do this on a clean operating system, just after installation.
Title: Re: how do i deploy my program to others?
Post by: raynebc on July 02, 2018, 09:36:45 pm
I did that testing with a PC that had no development software on it.  The second step is to monitor user feedback for error dialogs regarding missing library files, which happened on rare occasion when I did something like change compilers.