diff options
| author | ruki <[email protected]> | 2022-10-08 18:22:31 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2022-10-08 18:22:31 +0800 |
| commit | 5bad2ec0a57cf58fc7ead66de9cd4e68a322875c (patch) | |
| tree | 1cab175b95989c3697633299558456a5431be65f /xmake/core/project/package.lua | |
| parent | 9de38bc4d90718d6430e1126a80de3c9ad21f253 (diff) | |
add some warings
Diffstat (limited to 'xmake/core/project/package.lua')
| -rw-r--r-- | xmake/core/project/package.lua | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/xmake/core/project/package.lua b/xmake/core/project/package.lua index 6c9155daf..18bd7bea6 100644 --- a/xmake/core/project/package.lua +++ b/xmake/core/project/package.lua @@ -197,6 +197,12 @@ function _instance:rules() for rulename, ruleinfo in pairs(ruleinfos) do rulename = "@" .. self:name() .. "/" .. rulename local instance = rule.new(rulename, ruleinfo, {package = self}) + if instance:script("load") then + utils.warning("we cannot add `on_load()` in package rule(%s), please use `on_config()` instead of it!", rulename) + end + if instance:script("load_after") then + utils.warning("we cannot add `after_load()` in package rule(%s), please use `on_config()` instead of it!", rulename) + end rules[rulename] = instance end self._RULES = rules |
