adding flag PROFILE to the DETAILS file

Auke Kok sofar at foo-projects.org
Thu Oct 26 16:17:59 CEST 2006


Samuel Verstraete wrote:
> The attached patch will allow defining a PROFILE variable in the
> DETAILS file of profile modules like XOrg7, xfce4-profile etc etc... so
> users are no longer confronted with a warning that makes no sense. 
> 
> both "WARNING: module does not call prepare_install or installs zero
> files" and the "! Problem detected" will be removed if the module is a
> profile.
> 
> Adding hackish messages to the BUILD file like i did now with XOrg7
> should then be a thing of the past (i did this because already 2 times
> users complained that they thought XOrg7 was not installed correctly
> due to this error)
> 
> Just add PROFILE=yes in the DETAILS file and try the patch.

for a hack this is rather elegant, I'll think I'll take it :)

Auke


> 
> gr,S.
> 
> 
> 
> ~/lunar # svn diff
> Index: var/lib/lunar/functions/build.lunar
> ===================================================================
> --- var/lib/lunar/functions/build.lunar (revision 21942)
> +++ var/lib/lunar/functions/build.lunar (working copy)
> @@ -272,7 +272,7 @@
>  default_post_build() {
>    debug_msg "default_post_build ($@)"
>  
> -  if [ $(wc -l $INSTALLWATCHFILE | awk '{print$1}') == "0" ]; then
> +  if [ $(wc -l $INSTALLWATCHFILE | awk '{print$1}') == "0" ] &&
> [ "$PROFILE" != "yes" ] ; then message "${PROBLEM_COLOR}WARNING:
> ${DEFAULT_COLOR}${FILE_COLOR}BUILD${DEFAULT_COLOR}${PROBLEM_COLOR} does
> not call prepare_install or installs zero files!${DEFAULT_COLOR}" fi 
> Index: var/lib/lunar/functions/main.lunar
> ===================================================================
> --- var/lib/lunar/functions/main.lunar  (revision 21942)
> +++ var/lib/lunar/functions/main.lunar  (working copy)
> @@ -343,7 +343,7 @@
>      sound SUCCESS               &&
>      activity_log  "lin"  "$MODULE"  "$VERSION"  "success"
>  
> -    if [ "$?" != 0 ] ; then
> +    if [ "$?" != 0 ] && [ "$PROFILE" != "yes" ] ; then
>        sound FAILURE
>        message "${PROBLEM_COLOR}! Problem detected${DEFAULT_COLOR}"
>        rm -f $linING
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Lunar-dev mailing list
> Lunar-dev at lunar-linux.org
> http://foo-projects.org/mailman/listinfo/lunar-dev


More information about the Lunar-dev mailing list