On 4 December 2012 19:04, Felix Fietkau <n...@openwrt.org> wrote:
>
> On 2012-11-27 2:28 PM, Roman Yeryomin wrote:
> > On 20 November 2012 21:45, Roman Yeryomin <leroi.li...@gmail.com
> > <mailto:leroi.li...@gmail.com>> wrote:
> >
> >     When developing/debugging a package I would like to make
> >     change/compile/try cycle to be shorter.
> >     Of cause you can do something like:
> >     - edit/save the code
> >     - cd build_dir/target_something/package
> >     - make clean
> >     - rm -f .built*
> >     - cd -
> >     - make package/name/compile
> >
> >     but this looks and feels much nicer and shorter:
> >     - edit/save the code
> >     - make package/name/cleansrc
> >     - make package/name/compile
> >
> >
> > Use $(STAMP_BUILT) variable. Cleans some trailing spaces.
> On packages with reasonably sane build systems, there shouldn't be a
> need to run make clean for change/compile/try cycles, just use quilt and
> you won't need to remove the .built stamp (as every /compile call will
> trigger a configure+build).

Using quilt looks to me as much longer way to go.

> I'm worried about this having a default implementation that might be
> incomplete or defunct for many packages that overwrite the Build/Compile
> template, and this codepath is not going to be tested by many people.
>
> Wouldn't it be better to have a default implementation that is
> reasonably safe by removing all object files, libraries, etc. from the
> build tree?

Well, I think that if someone is doing his own Build/Compile target he
should take care of cleaning too.
Also, in my opinion, if source code has a Makefile and doesn't
implement clean target or it is implemented but breaks something then
something is wrong with the source, not build system, and it should be
fixed anyway.

> What packages do you have in mind where this could be useful?
> For me the need to use make clean is extremely rare. Almost all of the
> times where I needed to clean the source tree, recreating it from
> scratch was a better choice anyway, as 'make clean' is unreliable with
> many packages

I mostly use it (together with this one
http://patchwork.openwrt.org/patch/2940/) for my own packages and find
these 2 patches extremely useful, especially when using
package-version-override.mk features.
But I know other people using it (actually both of them), e.g. for
net-snmp. And, even more, originally it was their question - "how do
we do that?".

Regards,
Roman
_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel

Reply via email to