View | Details | Raw Unified | Return to bug 19959
Collapse All | Expand All

(-)make.1 (+4 lines)
Lines 595-600 Link Here
595
Replaces each word in the variable with its suffix.
595
Replaces each word in the variable with its suffix.
596
.It Cm H
596
.It Cm H
597
Replaces each word in the variable with everything but the last component.
597
Replaces each word in the variable with everything but the last component.
598
.It Cm L
599
Converts variable to lower-case letters.
598
.It Cm M Ns Ar pattern
600
.It Cm M Ns Ar pattern
599
Select only those words that match the rest of the modifier.
601
Select only those words that match the rest of the modifier.
600
The standard shell wildcard characters
602
The standard shell wildcard characters
Lines 684-689 Link Here
684
.Ar old_string
686
.Ar old_string
685
to be replaced in
687
to be replaced in
686
.Ar new_string
688
.Ar new_string
689
.It Cm U
690
Converts variable to upper-case letters.
687
.El
691
.El
688
.Sh DIRECTIVES, CONDITIONALS, AND FOR LOOPS
692
.Sh DIRECTIVES, CONDITIONALS, AND FOR LOOPS
689
Directives, conditionals, and for loops reminiscent
693
Directives, conditionals, and for loops reminiscent
(-)var.c (-1 / +40 lines)
Lines 1428-1433 Link Here
1428
     *  	  	    	(pathname minus the suffix).
1428
     *  	  	    	(pathname minus the suffix).
1429
     *	    	  :lhs=rhs  	Like :S, but the rhs goes to the end of
1429
     *	    	  :lhs=rhs  	Like :S, but the rhs goes to the end of
1430
     *	    	    	    	the invocation.
1430
     *	    	    	    	the invocation.
1431
     *            :Q		Quotes every shell meta-character in the
1432
     * 		 	        variable
1433
     *  	  :U		Converts variable to UPPER-CASE
1434
     *            :L		Converts variable to lower-case
1431
     */
1435
     */
1432
    if ((str != (char *)NULL) && haveModifier) {
1436
    if ((str != (char *)NULL) && haveModifier) {
1433
	/*
1437
	/*
Lines 1442-1447 Link Here
1442
		printf("Applying :%c to \"%s\"\n", *tstr, str);
1446
		printf("Applying :%c to \"%s\"\n", *tstr, str);
1443
	    }
1447
	    }
1444
	    switch (*tstr) {
1448
	    switch (*tstr) {
1449
		case 'U': 
1450
		    if (tstr[1] == endc || tstr[1] == ':') {
1451
		    /* XXX are there more effective way of doing the 
1452
			   same thing ?*/
1453
		    Buffer        buf;
1454
    		    buf = Buf_Init (MAKE_BSIZE);
1455
		    for (cp = str; *cp; cp++)
1456
        		Buf_AddByte(buf, (Byte)toupper(*cp));
1457
1458
    		    Buf_AddByte(buf, (Byte) '\0');
1459
    		    newStr = (char *)Buf_GetAll (buf, (int *)NULL);
1460
    		    Buf_Destroy (buf, FALSE);
1461
1462
   		    cp = tstr + 1;
1463
		    termc = *cp;
1464
		    break;
1465
		}
1466
		/*FALLTHRU*/
1467
		case 'L': 
1468
		    if (tstr[1] == endc || tstr[1] == ':') {
1469
		    /* XXX are there more effective way of doing the 
1470
			   same thing ?*/
1471
		    Buffer        buf;
1472
    		    buf = Buf_Init (MAKE_BSIZE);
1473
		    for (cp = str; *cp; cp++)
1474
        		Buf_AddByte(buf, (Byte)tolower(*cp));
1475
1476
    		    Buf_AddByte(buf, (Byte) '\0');
1477
    		    newStr = (char *)Buf_GetAll (buf, (int *)NULL);
1478
    		    Buf_Destroy (buf, FALSE);
1479
1480
   		    cp = tstr + 1;
1481
		    termc = *cp;
1482
		    break;
1483
		}
1484
		/*FALLTHRU*/
1445
		case 'N':
1485
		case 'N':
1446
		case 'M':
1486
		case 'M':
1447
		{
1487
		{
1448
-cutline--

Return to bug 19959