526 ^ Smalltalk classNamed:className |
526 ^ Smalltalk classNamed:className |
527 |
527 |
528 "Created: / 26-07-2012 / 10:21:27 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
528 "Created: / 26-07-2012 / 10:21:27 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
529 ! ! |
529 ! ! |
530 |
530 |
|
531 !ProjectProblem::ClassProblem methodsFor:'fixing'! |
|
532 |
|
533 doUpdateAllProjectDefinitions |
|
534 "full update the project definition class; |
|
535 will do a rescan to add all missing items" |
|
536 |
|
537 | def | |
|
538 |
|
539 def := self packageDefinitionClass. |
|
540 def isNil ifTrue:[ ^ false ]. |
|
541 |
|
542 def |
|
543 updateMethodsCodeUsingCompiler:Compiler |
|
544 ignoreOldDefinition:false. |
|
545 |
|
546 UserNotification notify: ('Project definitions updated. Do not forget to check in build support files!!'). |
|
547 ^true |
|
548 ! ! |
|
549 |
531 !ProjectProblem::InconsistentProjectDefinition methodsFor:'fixes'! |
550 !ProjectProblem::InconsistentProjectDefinition methodsFor:'fixes'! |
532 |
551 |
533 fixes |
552 fixes |
534 |
553 |
535 ^Array |
554 ^Array |
536 with: (Array with: 'Regenerate specs in ProjectDefinitions' with: [ self regenerateProjectDefinition ]) |
555 with: (Array with: 'Full update of the project definitions (rescan)' with: [ self doUpdateAllProjectDefinitions ]) |
537 ! |
|
538 |
|
539 regenerateProjectDefinition |
|
540 |defClass| |
|
541 |
|
542 defClass := self packageDefinitionClass. |
|
543 Class packageQuerySignal |
|
544 answer:defClass package |
|
545 do:[ |
|
546 defClass theNonMetaclass |
|
547 forEachContentsMethodsCodeToCompileDo: |
|
548 [:code :category | |
|
549 Compiler |
|
550 compile:code |
|
551 forClass:defClass theMetaclass |
|
552 inCategory:category. |
|
553 ] |
|
554 ignoreOldDefinition:false |
|
555 ]. |
|
556 ! ! |
556 ! ! |
557 |
557 |
558 !ProjectProblem::ClassListedButDoesNotExist methodsFor:'accessing'! |
558 !ProjectProblem::ClassListedButDoesNotExist methodsFor:'accessing'! |
559 |
559 |
560 severity |
560 severity |
672 ! |
672 ! |
673 |
673 |
674 fixes |
674 fixes |
675 |
675 |
676 ^Array |
676 ^Array |
677 with: (Array with: 'Include in project' with: [ self doIncludeInProject ]) |
677 with: (Array with: 'Include in project' with: [ self doIncludeInProject ]) |
678 with: (Array with: 'Include in project as autoloaded' with: [ self doIncludeInProjectAsAutoloaded ]) |
678 with: (Array with: 'Include in project as autoloaded' with: [ self doIncludeInProjectAsAutoloaded ]) |
|
679 with: (Array with: 'Full update of the project definitions (rescan)' with: [ self doUpdateAllProjectDefinitions ]) |
679 |
680 |
680 "Created: / 26-07-2012 / 10:41:18 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
681 "Created: / 26-07-2012 / 10:41:18 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
681 ! ! |
682 ! ! |
682 |
683 |
683 !ProjectProblem::ClassListedBeforeItsPool methodsFor:'accessing'! |
684 !ProjectProblem::ClassListedBeforeItsPool methodsFor:'accessing'! |
1452 |
1454 |
1453 description |
1455 description |
1454 "Return a (HTML) describing the problem." |
1456 "Return a (HTML) describing the problem." |
1455 |
1457 |
1456 package = 'stx' ifTrue:[ |
1458 package = 'stx' ifTrue:[ |
1457 ^ |
1459 ^ |
1458 'Move your code to another package. |
1460 'Move your code to another package. |
1459 <br>The package named "stx" is reserveed for exept''s ST/X development.' |
1461 <br>The package name "stx" is reserveed for exept''s ST/X development.' |
1460 ]. |
1462 ]. |
1461 |
1463 |
1462 ^ |
1464 ^ |
1463 'A project definition class for package "%1" does not exist. |
1465 'A project definition class for package "%1" does not exist. |
1464 <br>Project definition classes keep the meta information of a package, |
1466 <br>Project definition classes keep the meta information of a package, |
1465 such as contents and build parameters. |
1467 such as contents and build parameters. |
1466 You <b>must</b> create it, otherwise package management won''t work.' |
1468 You <b>must</b> create it, otherwise package management won''t work, |
|
1469 and the package cannot be compiled to a binary dll.' |
1467 bindWith: package |
1470 bindWith: package |
1468 |
1471 |
1469 "Modified: / 23-02-2012 / 13:29:01 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
1472 "Modified: / 23-02-2012 / 13:29:01 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
1470 ! |
1473 ! |
1471 |
1474 |
1476 ! ! |
1479 ! ! |
1477 |
1480 |
1478 !ProjectProblem::ProjectDefinitionDoesNotExist methodsFor:'fixing'! |
1481 !ProjectProblem::ProjectDefinitionDoesNotExist methodsFor:'fixing'! |
1479 |
1482 |
1480 doCreateAs:whatType |
1483 doCreateAs:whatType |
1481 ProjectDefinition |
1484 |prjDef| |
1482 definitionClassForPackage:package |
1485 |
1483 projectType: whatType |
1486 prjDef := ProjectDefinition |
1484 createIfAbsent:true. |
1487 definitionClassForPackage:package |
|
1488 projectType: whatType |
|
1489 createIfAbsent:true. |
|
1490 |
|
1491 prjDef |
|
1492 updateMethodsCodeUsingCompiler:Compiler |
|
1493 ignoreOldDefinition:true |
1485 ! |
1494 ! |
1486 |
1495 |
1487 doCreateAsGUIApplication |
1496 doCreateAsGUIApplication |
1488 self doCreateAs:ProjectDefinition guiApplicationType |
1497 self doCreateAs:ProjectDefinition guiApplicationType |
1489 ! |
1498 ! |
1506 ! ! |
1515 ! ! |
1507 |
1516 |
1508 !ProjectProblem class methodsFor:'documentation'! |
1517 !ProjectProblem class methodsFor:'documentation'! |
1509 |
1518 |
1510 version |
1519 version |
1511 ^ '$Header: /cvs/stx/stx/libbasic3/ProjectProblem.st,v 1.17 2013-03-30 21:02:36 cg Exp $' |
1520 ^ '$Header: /cvs/stx/stx/libbasic3/ProjectProblem.st,v 1.18 2013-04-03 18:38:43 cg Exp $' |
1512 ! |
1521 ! |
1513 |
1522 |
1514 version_CVS |
1523 version_CVS |
1515 ^ '$Header: /cvs/stx/stx/libbasic3/ProjectProblem.st,v 1.17 2013-03-30 21:02:36 cg Exp $' |
1524 ^ '$Header: /cvs/stx/stx/libbasic3/ProjectProblem.st,v 1.18 2013-04-03 18:38:43 cg Exp $' |
1516 ! |
1525 ! |
1517 |
1526 |
1518 version_SVN |
1527 version_SVN |
1519 ^ '§Id: ProjectProblem.st 1962 2012-09-10 10:34:08Z vranyj1 §' |
1528 ^ '§Id: ProjectProblem.st 1962 2012-09-10 10:34:08Z vranyj1 §' |
1520 ! ! |
1529 ! ! |