Permalink
Browse files

mesa-lib: make configure messages appear only when unconfigured

At the moment these messages also appear when installing
a module that depends on mesa-lib (and mesa-lib is already installed),
because the CONFIGURE file is parsed.
  • Loading branch information...
1 parent 3e669d1 commit 8602a3e07a669b1ca736d85262f13bcddaa82492 @v4hn committed Nov 14, 2012
Showing with 14 additions and 12 deletions.
  1. +14 −12 lib/mesa-lib/CONFIGURE
@@ -53,18 +53,20 @@ if ! grep -q "MESADRIVER=" $MODULE_CONFIG; then
set_module_config MESADRIVER "$MESADRIVER"
fi
-message "${MESSAGE_COLOR}Gallium is an alternative to DRI and needed to do 3D acceleration on"
-message "nouveau, radeon(-hd), ati or Intel GMA (Poulsbo/Cedar Trail). However, Gallium is not"
-message "performing on Intel GENX graphics (Any onboard Corei3/5/7, G25/33/45, pinetrail gfx"
-message ""
-message "Open Source Drivers:"
-message "If you build for Intel DRI-based hardware, disable Gallium, llvm and enable libva, xvmc."
-message "If you build for Intel CedarTrail or Poulsbo, enable Gallium, llvm, xvmc, vdpau."
-message "If you build for NVidia or Ati hardware, enable Gallium, llvm, xvmc, vdpau."
-message ""
-message "Binary / Proprietary Drivers:"
-message "If building the NVIDIA/fglrx binary driver, disable gallium, llvm, vdpau, xvmc."
-message "${DEFAULT_COLOR}"
+if [[ -z "`get_module_config GALLIUM`" ]]; then
+ message "${MESSAGE_COLOR}Gallium is an alternative to DRI and needed to do 3D acceleration on"
+ message "nouveau, radeon(-hd), ati or Intel GMA (Poulsbo/Cedar Trail). However, Gallium is not"
+ message "performing on Intel GENX graphics (Any onboard Corei3/5/7, G25/33/45, pinetrail gfx"
+ message ""
+ message "Open Source Drivers:"
+ message "If you build for Intel DRI-based hardware, disable Gallium, llvm and enable libva, xvmc."
+ message "If you build for Intel CedarTrail or Poulsbo, enable Gallium, llvm, xvmc, vdpau."
+ message "If you build for NVidia or Ati hardware, enable Gallium, llvm, xvmc, vdpau."
+ message ""
+ message "Binary / Proprietary Drivers:"
+ message "If building the NVIDIA/fglrx binary driver, disable gallium, llvm, vdpau, xvmc."
+ message "${DEFAULT_COLOR}"
+fi
mquery GALLIUM "Enable Gallium llvm renderer?" y "--enable-gallium-llvm" "--disable-gallium-llvm"

1 comment on commit 8602a3e

@sofar
sofar commented on 8602a3e Nov 16, 2012

This will break if someone renames GALLIUM and forgets this. I like the change, but the trigger needs to be a different method.

Perhaps do what e2fsprogs does ->

if [ -z "$(get_module_config CONFIGURED)" ]; then
...
fi
set_module_config CONFIGURED y

Please sign in to comment.