Author Topic: Custom Makefile  (Read 5667 times)

Offline Knx

  • Multiple posting newcomer
  • *
  • Posts: 41
Custom Makefile
« on: November 19, 2007, 02:31:29 am »
Url
Quote
Q: My project should be compiled with a custom makefile. Is it possible with Code::Blocks?

A: Yes, you can. You need to change two different settings:

a) In "Compiler Settings", under the tab "Other", there's a setting called "Build Method". Choose "Work with makefiles".

b) In your project's Properties, you can choose to use a makefile. Check "This is a custom makefile" (WARNING! if you forget to check, the makefile will be OVERWRITTEN!)

And that's it! :)

a) It's disabled...
b) Couldn't proceed...

Why is it disabled?
Using:
• Code::Blocks SVN        • wxWidGets 2.8.6
• Windows XP SP2          • MinGW Latest  Wish List • Code folding (For wxSmith and more options like NetBeans)

Offline Knx

  • Multiple posting newcomer
  • *
  • Posts: 41
Re: Custom Makefile
« Reply #1 on: November 19, 2007, 02:54:07 am »
Doing only step b), I get this message:
Quote
mingw32-make.exe: *** No rule to make target `Release'.  Stop.
Using:
• Code::Blocks SVN        • wxWidGets 2.8.6
• Windows XP SP2          • MinGW Latest  Wish List • Code folding (For wxSmith and more options like NetBeans)

sylvia

  • Guest
Re: Custom Makefile
« Reply #2 on: December 04, 2007, 07:21:38 am »
I have the same problem.
Can anyone be kind to answer it?

Offline kisoft

  • Almost regular
  • **
  • Posts: 194
Re: Custom Makefile
« Reply #3 on: December 04, 2007, 08:45:04 am »
I have the same problem.
Can anyone be kind to answer it?

I doing used custom Makefile. I have no problems.

For example, create Makefile_my.
Set this name in project properties.
On compile, will called target Release. In my example target Release equ target all.
On CleanRelease, will called target clean.

Code
default:
@echo  ****************** Make DLL ******************
@make.CMD

Debug: all
Release: all

all :
@echo  ****************** Make DLL ******************
@make.CMD

cleanDebug: clean
cleanRelease: clean

clean:
@echo  ****************** Remove DLL ******************
@removeall.cmd

If you have questions, I ready to answer.

Good luck!
OS: WinXPSP3
wxWidgets: 2.8.12
CodeBlocks: Master github cbMakefileGen plugin:
https://github.com/kisoft/cbmakefilegen

sylvia

  • Guest
Re: Custom Makefile
« Reply #4 on: December 04, 2007, 10:38:53 am »
Thank you for your reply. I got it.  :D