Forum > Options

Additions and Overrides: default Target dir; custom option for a platform

(1/2) > >>

Jungle:
1. I want to set default* Target file name to

--- Code: Pascal  [+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i < x.length; i++) { x[i].style.maxHeight='none'; x[i].style.height = Math.min(x[i].clientHeight+15,306)+'px'; x[i].style.resize = "vertical";}};} ---bin\$(TargetCPU)-$(TargetOS)\$(BuildMode)\$NameOnly($(ProjFile))I've tried setting IDE Macro ProjOutDir, but it doesn't work.

2. I want to set -X9 custom option only for linux platform by default*.

I've tried setting Custom for target linux in Compiler Options > Additions and Overrides, but it doesn't work.

How can it be done?

*Default == for every new and existing project, it's inconvenient to change these settings manually for every project.

P.S. Lazarus 2.0.12

MarkMLl:
Does the "Set compiler options as default" checkbox help?

I prefer the same sort of thing, but haven't got round to investigating the checkbox. Also in my case I prefer to also have the widgetset name in there, which might be problematic for console-mode programs.

MarkMLl

Jungle:

--- Quote from: MarkMLl on April 07, 2021, 09:18:41 am ---Does the "Set compiler options as default" checkbox help?
--- End quote ---
No

Martin_fr:
"Options > Additions and Overrides, "

The "Target" is the name of any package (LCL, TaChart, ...) or #project  (there is a wiki page that has more details.

While I have not done that myself, if you look at the page "Custom Options" you will see in the "conditionals" sections

--- Code: ---// example for adding linker options on Mac OS X
//if TargetOS='darwin' then
//  LinkerOptions := ' -framework OpenGL';
--- End code ---

https://wiki.lazarus.freepascal.org/IDE_Window:_Compiler_Options#Custom_Options

There is a checkbox at the bottom of the form, that saves current settings as new default.

Jungle:

--- Quote from: Martin_fr on April 08, 2021, 05:01:40 pm ---if you look at the page "Custom Options" you will see in the "conditionals" sections

--- Code: ---// example for adding linker options on Mac OS X
//if TargetOS='darwin' then
//  LinkerOptions := ' -framework OpenGL';
--- End code ---

https://wiki.lazarus.freepascal.org/IDE_Window:_Compiler_Options#Custom_Options

There is a checkbox at the bottom of the form, that saves current settings as new default.
--- End quote ---

When I set -X9 in Custom options, it works. When I write


--- Code: ---if TargetOS='Linux' then
  LinkerOptions := ' -X9';
--- End code ---

in Conditionals, it doesn't work

"Set compiler options as default" works for new projects, but doesn't work for existing ones.

Navigation

[0] Message Index

[#] Next page

Go to full version