📄 readme
字号:
README for the TinyOS Make Systemcreated on 7 Jan 2004written by Cory Sharp <cssharp@eecs.berkeley.edu>updated on 16 Apr 2004 by Cory SharpTo describe new TOSMAKE_INCLUDE variable for user make subdirectories.$Id: README,v 1.6 2004/08/30 21:53:54 scipio Exp $----------------------------------------------------------------------------Introduction----------------------------------------------------------------------------This is a new make system. It's nicer than the old apps/Makerules,especially for adding new targets and platforms. Basically, new featurescan be added without getting in the way of existing make platforms andrules.----------------------------------------------------------------------------Quick Start----------------------------------------------------------------------------To use this build system, GNU Make 3.80 or greater is required; check with"make --version". Then, set MAKERULES, find an application, and try makeexport MAKERULES=`ncc -print-tosdir`/../tools/make/Makerulescd `ncc -print-tosdir`/../apps/Blink #or any app dirmake telos helpThe end of this document has a few notes on some issues that can arise withGNU Make 3.80.----------------------------------------------------------------------------Directory Structure and Naming Conventions----------------------------------------------------------------------------The root of the make system is the make/ directory in which this README islocated. You'll find two main types of files with the extensions .targetand .extra. Both types of files define valid make goals. A target filemust define a valid make target of the same name. An extra fileautomatically has a dummy target created for it, making it useful fordefining extra make variables given a particular goal on the command line.There are also subdirectories in make/, such as make/avr/ and make/hc08/.Files in these directories are not exposed to the current build unlessimported from another goal. For instance, the mica2 target imports the avr/directory with the command "$(call TOSMake_include_platform,avr)", whichfurther exposes the target and extra files in the avr subdirectory as validgoals for the current build. The TOSMake_include_platform function expectsto find a .rules file of the same name as the directory, such asavr/avr.rules.It is expected that the primary build behavior occurs in aplatform/platform.rules file (such as avr/avr.rules). Further target andextra goals in that platform make directory should augment the behavior ofthe rules file. Then, platform build targets are globally exposed bycreating a simple .target file in the make/ root. Overall, this structuregives a lot of opportunity to change the behavior of a build given goals onthe command line with few or no ifdef's in the makefiles. And, each makebehavior is localized to a single file, which I think should be pretty nice.There's also a make/Makerules file. Do not edit make/Makerules. No newbuild features should ever be exposed via make/Makerules, but rather thoughthe .rules, .target, and .extra files. Let me repeat, do not editmake/Makerules, add new features elsewhere. make/Makerules is the frontendthat defines the structure and behavior on those special file extensions.----------------------------------------------------------------------------User make/ directories----------------------------------------------------------------------------I've added a new variable TOSMAKE_PATH that allows you to define additionalroot directories for the TinyOS Make System that behave just like the primary make/ directory. In one of your own make files, just add one ormore directories to TOSMAKE_PATH sometime before make/Makerules is included: TOSMAKE_PATH += $(TOSDIR)/../contrib/eyes/makeThat's all you need, and you're in business. Enjoy.----------------------------------------------------------------------------make 3.80----------------------------------------------------------------------------The standard version of GNU Make 3.80 (based on October 2002 source) hasa bug which this make system can trigger. If a make variable is longer than200 bytes (characters), then make will report that it has run out ofvirtual memory and exit. This can happen if, for example, your applicationdepends on a lot of Java/mig message classes, which are BUILD_EXTRA_DEPS.The only way to fix this problem is to use a newer, patched version ofmake 3.80. All TinyOS releases after 1.1.8 should have a patchedversion, and will work properly. Pre-1.1.7 versions, however, may runinto this problem; you can either upgrade to >= 1.1.8, or download themake source, apply the patch 'eval-crash.diff' in this directory, andcompile then install the patched version.----------------------------------------------------------------------------Go go go----------------------------------------------------------------------------... okay, hopefully that's enough head's up that you can poke around thisdirectory tree and add new targets, extras, and platforms. Good luck, andholler if you want more documentation.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -