Package: atlas
Version: 3.8.3-21
Hi
The cpufrequtils test loop that is part of the 'custom' rule fails due
to the bash-tastic for-loop syntax. I have replaced it with a while
loop in the attached patch. I've tested it and it works fine.
A less important 'gotcha' is that running the custom rule means that
build dependency checks are bypassed. If the uninstalled dependency is
say lapack-dev, then a 20+ minute compile is a long time to waitto
discover it is borked. (I am sighing from personal experience).
The following test works ($$deps would be the list of build-dep
packages). I am, however, unsure how one would get $$deps from within
the rules makefile.
if test -n "$$(dpkg-query -W $$deps 2>&1 > /dev/null)"; then\
echo "build dependencies are not fully installed";\
echo "aborting";\
exit 1;\
fi
--- debian/rules 2010-05-03 09:02:33.624063782 +1200
+++ debian/rules.edit 2010-05-03 09:00:41.570399790 +1200
@@ -110,14 +110,17 @@
custom-stamp:
rm -f configure-stamp
- ncpu=$$(LANG=C cpufreq-info | grep "analyzing CPU" -c); \
- for (( cpu=0 ; cpu < $$ncpu ; cpu++)); do \
- if test $$(cpufreq-info -p 2>&1 > /dev/null; echo $$?) -eq 0 -a -z "$$(LANG=C cpufreq-info -p -c $$cpu | grep performance)" ; then \
- echo "frequency governor on cpu=$$cpu is not set to 'performance'"; \
+ ncpu=$$(LANG=C cpufreq-info | grep "analyzing CPU" -c);\
+ cpu=0;\
+ while test $$cpu -lt $$ncpu ; do\
+ if test $$(cpufreq-info -p 2>&1 > /dev/null; echo $$?) \
+ -eq 0 -a -z "$$(LANG=C cpufreq-info -p -c $$cpu | grep performance)" ; then \
+ echo "frequency governor on cpu=$$ncpu is not set to 'performance'"; \
echo "run: 'sudo cpufreq-set -g performance -c cpu#' for each cpu"; \
echo "aborting atlas build"; \
exit 1; \
fi; \
+ cpu=$$((cpu+1)) ;\
done
# Here, the trick is pretty simple: