Niels Thykier pisze: Hi, > > Thanks for your suggestion. > > However, I must admit I am not entirely convinced about the idea. I > sort of see where you are coming from, but I do not see why this cannot > trivially be solved by the current interface and make target dependencies.
Yes, one can do something like in debian/rules: install-common: ... override_dh_auto_install-arch: install-common ... override_dh_auto_install-indep: install-common ... but this has the disadvantage of install-common being run twice, which obviously can be work-arounded by using timestamp file: install-common: install-common-stamp install-common-stamp: ... touch "$@" which in turn prevents usage `debuild -nc -b', unless the time-stamp file is manually removed. (BTW. I have a local version of debuild which calls `rm -vf debian/*.debhelper.log debian/files' when it's run with `-nc'). > > Part of my reason to be conservative is that if we change this, we also > have to think about the "order" in which things are run. There are > almost certainly arguments for running "-common" before *AND* after the > regular "-indep/-arch" targets (though hopefully not both at the same > time). We do not have this problem currently since "-indep" and "-arch" > are disjointed in their purpose. Yes, you're right the order is important. In my opinion running -common *before* -arch and -indep seems to be more natural: in such an order -arch and -indep can safely relay on things done in -common. The reverse order would lead to subtle errors, for example -common might try to use a file built by -indep, while the build is arch-only (or opposite, which might be worse since arch:all packages are usually not built by auto-builders). > > Alternatively, are you asking for something like this? > > """ > if building arch-dep AND arch-indep, then > make -f d/rules override_X-common > elif builing arch-dep then > make -f d/rules override_X-arch > else > make -f d/rules override_X-indep > """ > > I.e. the "-common" target would replace -arch and -indep plus *only* be > run when building arch-dep and arch-indep at the same time? No, it does not make sense to me, as this most probably would mean duplicating -arch and -indep work into -common. I'm asking for: if building arch-dep AND arch-indep, then make -f d/rules override_X-common make -f d/rules override_X-arch make -f d/rules override_X-indep elif builing arch-dep then make -f d/rules override_X-common make -f d/rules override_X-arch else make -f d/rules override_X-common make -f d/rules override_X-indep fi Regards, robert -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org