Lazarus

Miscellaneous => Suggestions => Topic started by: ca70du on August 21, 2018, 09:25:44 pm

Title: Build Release
Post by: ca70du on August 21, 2018, 09:25:44 pm
Hello!

I'd like to suggest a new menu item: "Build Release" under "Execute". Action: build a release executable, without any or with minimum debug info. I think it's a more intelligent way than the current "build mode". The IDE may always build debug mode, except under "Build Release".

Also, in "Project Options", under "Compiler Options", a new item: "Release", with release-specific options, such as an optional "Release path" to store release builds, and the option to include version number to executable's file name. So the "Build modes" may be excluded.

Att.,
Carlos E. S. M.
Curitiba / ParanĂ¡ / Brazil

Title: Re: Build Release
Post by: lucamar on August 21, 2018, 10:08:01 pm
People use "buld modes" for much more than a simple Debug/Release dichotomy: cross compilation, for example, or building various executales with different options/defines, etc.

So you see how your proposal would basically constraint everyone for little, if any, gain: it's so easy to change modes! And you can do almost everything you want through mode-specific options so ... what's the point?

My 2 cents. :)
Title: Re: Build Release
Post by: ASBzone on August 21, 2018, 10:16:04 pm
I'd like to suggest a new menu item: "Build Release" under "Execute". Action: build a release executable, without any or with minimum debug info. I think it's a more intelligent way than the current "build mode". The IDE may always build debug mode, except under "Build Release".

You seem to be asking for a pre-built "build mode".

It seems to me that you can achieve what you desire by using the Build Modes, in combination with "Run --> Compile many Modes..."

I started using that recently to build x32 and x64 Windows executables in a single selection.    I also used it on a test program to generate 4 executables (main, main-mini, main64, main64-mini) with differing configuration, so that I could quickly validate changes.

If I could set a default for which of the checkboxes in "Compile many Modes..." were selected by default, I would be ecstatic, but an extra click or two hasn't killed me yet...
Title: Re: Build Release
Post by: Martin_fr on August 21, 2018, 10:53:43 pm
You can set a diff output directory in each build mode. So that is solvable.
You can also set the build modes as defaults for all new projects.

There may be a point, to have those defaults pre-configured in new lazarus installs.
Title: Re: Build Release
Post by: Leledumbo on August 22, 2018, 04:17:39 pm
There may be a point, to have those defaults pre-configured in new lazarus installs.
Kinda agree with this one, sometimes we're too advanced that we think everything is as intuitive as it can be for everyone.
Attached is my style, might not fit everyone's standard as I like to make the directory layout somewhat more organized:
Code: [Select]
project.lpi
src
+ here lies your .pas / .pp, may be broken further down into plain unit files, forms, libraries, whatever according to your taste
lib
+ debug
  + <fpctarget>
    + here lies your .ppu / .o / .rst / .res, etc. files using debug options
+ release
  + <fpctarget>
    + here lies your .ppu / .o / .rst / .res, etc. files using release options
bin
+ debug
  + here lies the executable using debug options
+ release
  + here lies the executable using release options
Title: Re: Build Release
Post by: ca70du on August 29, 2018, 11:28:02 pm
I don't like to redo the same task every time. This is not laziness. I do not think it is intelligent, it is counter-productive. Not only per project, also every time someone do a clean install.

How about include one step during install to ask what modes will be default? Think about the people who are new in Lazarus, that would be easier to begin. More people using it, more interest, more new ideas.

I suggested "Release Build" as a "final product generator", ready for distribution, after debugging and testing. If there is a button to create "debug and release" modes, why not to make them default?
Title: Re: Build Release
Post by: JimD on August 30, 2018, 06:11:19 am
I don't like to redo the same tasks either.

Until your recommendations are implemented, you may be interested in LazCopyOptions here:
http://forum.lazarus.freepascal.org/index.php/topic,42258.0.html

In summary, you setup your build modes the first time, then you can copy to existing or new projects.
Title: Re: Build Release
Post by: Leledumbo on September 03, 2018, 11:01:46 am
In summary, you setup your build modes the first time, then you can copy to existing or new projects.
No need to copy for new projects, just check that box in the attached image after setting up the build modes.
TinyPortal © 2005-2018