⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 makerules.4

📁 创建一个符合iso-9660标准的iso文件系统
💻 4
📖 第 1 页 / 共 2 页
字号:
.B \-O_ARCH as a central part.On some operating systems e.g. .B SunOSand.B DG\-UXit is necessary to distinguish between .B "SunOS 4.xand.B "SunOS 5.xor.B "DG\-UX 3.xand .B "DG\-UX 4.x..PPThe next file to be included from.B RULES/rules.topis.BR Defaults .It defines the macros.B DEFCCOM,.B DEFINCDIRS,.B LDPATH,.B RUNPATH,.B INS_BASEand .BR INS_KBASE .If the definitions have to be different ondifferent systems, this file may contain a line int the form:.sp.BI include  " $(SRCROOT)" /Defaults. $(O_ARCH).spThe actual definitions then have to be moved intothese files..PPNext, after setting up some internal defaults,.B RULES/rules.topincludes the compiler configuration file withthe name:.sp.I $(SRCROOT)/$(RULESDIR)/$(XARCH).rul.spThis file contains all necessary .B system dependent stuff that is needed to configure the C-compiler on the appropriate system.It is a bad idea to create a new one from scratch.Have a look at the other compiler configurationfiles and modify a similar file for your needs.Note that there are basically two criterias tothat are important in a compiler configuration file.One is whether the system uses the.I ELFheader format or not. The other is whether the system uses.I shared librariesor not..SH "The Structure Of The Application Specific Rules.PPThe application specific rule files are designed insuch a way that they include all necessary stuff thatis needed for that specific task. The application specificrule files are:.TP 25$(RULES)/rules.auxRules for installing non localized auxiliary files..TP$(RULES)/rules.cmdRules for commands like .I sh..TP$(RULES)/rules.dirRules for sub directories..TP$(RULES)/rules.drvRules for lodable drivers..TP$(RULES)/rules.libRules for static libraries..TP$(RULES)/rules.locRules for installing localized auxiliary files..TP$(RULES)/rules.manRules for installing localized manual pages..TP$(RULES)/rules.mksRules for sub makefiles..TP$(RULES)/rules.modRules for lodable stream modules..TP$(RULES)/rules.scrRules for installing localized shell scripts..TP$(RULES)/rules.shlRules for shared libraries..SH "Understanding The Structure Of The Make Rule System.PPTo understand the structure of the .B "make rulesystem while doing changes, try to use the .B \-xMflagin the.B smakeprogram.This flag will print out the include dependency list(i.e. a list that tell you which make rules is includedfrom which other rule)..PPNote that some of the rules are make program dependent.If you want to make changes to these rules you may need toplace the definitions into separate rule fileseach for the appropriate make program.Have a look into the.B RULESdirectoryfor some examples..SH FILES\&.\|.\|./RULES/*.br\&.\|.\|./DEFAULTS/*.br\&.\|.\|./TARGETS/*.br\&.\|.\|./TEMPLATES/*.SH "SEE ALSO".BR makefiles (4),.BR make (1),.BR gmake (1),.BR smake (1)..SH DIAGNOSTICSDiagnostic messages depend on the make program.Have a look at the appropriate man page..SH NOTES.PPThe make rulescan be used with .IR "Sunpro make" ", " "Gnu make"and .IR smake .Although Gnu make runs on many platforms, it has no useful debugoutput..PPUse.IR "Sunpro make" " or " "smake"if you have problems with a makefile..IR "Sunpro make" " and " "smake" ,both have a \-D flag, that allows you to watch the makefilesafter the first expansion. Use this option, if you are in doubtif your makefile gets expanded the right way and if the rightrules are included.There is also a \-d option that gives debugging output while make is running. If you want more output, use \-dd, \-ddd and so on..PP.I Smakehas an option \-xM that shows you the include dependency formake rules..SH BUGS.SH "Source Tree Hierarchy.LPThe following outline gives a quick tour through a typicalsource hierarchy:.LP.na.nh.PD 0.TP.B .../root directory of the source tree..RS.TP.B Makefilethe top Makefile.TP.B Defaultsdefault definitions for that source tree. System dependentdefinitions are in .B .../DEFAULTS/.TP.B Targetdirsa file containing a list of directories that are neededfor that project.If the system needs different target lists dependingon the target system architecture , use target specific files in.B .../TARGETS/.TP\&.\|.\|..RE..TP.B .../RULES/the location of makefiles (included rules)..RS.TP.B rules.topthe mandatory include rules (needed to setup basic rules).TP.B rules.auxrules needed to install a non localized auxiliary file.TP.B rules.cmdrules needed to make an ordinary command (like /bin/sh).TP.B rules.drvrules needed to make a device driver.TP.B rules.librules needed to make a standard (nonshared) library.TP.B rules.locrules needed to install a localized auxiliary file.TP.B rules.manrules needed to install a localized manual page.TP.B rules.scrrules needed to install a localized shell script.TP.B rules.shlrules needed to make a shared library.TP.B rules.mksrules needed to make more than one target in a specific directory.TP.B rules.dirrules needed to make targets that are located in sub directoriesto the current directory.TP\&.\|.\|..RE..TP.B .../DEFAULTS/default definitions for various target architectures arelocated in this directory. Templates for some architectures canbe found in the.I .../TEMPLATES/directory..TP.B .../TARGETS/target list definitions for various target architectures arelocated in this directory..TP.B .../TEMPLATES/templates that should be used inside the project(rename to Makefile, if it is the only makefile on that directory, rename to.I target.mk,if there is more than one target in that directory)..RS.TP.B DefaultsDefaults file for the source root directory.TP.B Defaults.linuxDefaults file for .IR linux .This sould be installed in the .B .../DEFAULTS/directory..TP.B Makefile.rootMakefile for the source root directory.TP.B Makefile.auxMakefile for a non localized auxiliary file.TP.B Makefile.cmdMakefile for an ordinary command (like /bin/sh).TP.B Makefile.libMakefile for a standard (nonshared) library.TP.B Makefile.locMakefile for a localized auxiliary file.TP.B Makefile.manMakefile for a localized manual page.TP.B Makefile_de.manMakefile for a localized manual page in the german locale.TP.B Makefile.scrMakefile for a localized shell script.TP.B Makefile.shlMakefile for a shared library.TP.B Makefile.drvMakefile for a device driver.TP.B Makefile.mksMakefile for more than one target in a specific directory.TP.B Makefile.dirMakefile for targets that are located in sub directoriesto the current directory.TP\&.\|.\|..RE..TP.B .../cmd/source tree for normal commands..RS.TP.B Makefilethe makefile for the .I cmd sub directory.TP.B Targetdirs.sun4ma file containing a list of directories like .I myprog (see below) that are neededfor that specific architecture..TP.B myprog/directory where the sources for a specific command are located..RS.TPMakefilemakefile for.I myprog.TPMakefile.manmakefile for the manual page of.I myprog.TPmprog.csource for myprog.TPmprog.trtroff source for the manual page of myprog.TP.B OBJ/directory where system specific sub directories are located..RS.TP.B sparc\-sunos5\-cc/directory for binaries that belong to a specific system.TP\&.\|.\|..RE.TP\&.\|.\|..RE.br.TP\&.\|.\|..RE.br.ne 5.TP.B .../lib/directory where the sources for a libraries are located..RS.TP.B Makefilethe makefile for the .I lib sub directory.TP.B Targetdirs.sun4ma file containing a list of directories like .I libfoo(see below) that are neededfor that specific architecture..TP.B libfoo/directory where all source files for libfoo are located.TP\&.\|.\|..RE..TP.B .../kerneldirectory for kernel modules..RS.TP.B Makefilethe makefile for the .I kernelsub directory.TP.B Targetdirs.sun4ma file containing a list of directories like .I drv (see below) that are neededfor that specific architecture..TP.B drv/directory where drivers are located..RS.TP.B Makefilethe makefile for the .I drvsub directory.TP.B Targetdirs.sun4ma file containing a list of directories like .I mydrv(see below) that are neededfor that specific architecture..TP.B mydrv/source for a specific driver.TP\&.\|.\|..RE..TP\&.\|.\|..RE..TP.B .../includedirectory for global include files that are used in that project..TP.B .../binsdirectory for binary programs that are created/needed while compilingthe project.RS.TP.B sparc\-sunos5\-cc/directory for binaries that belong to a specific system.TP\&.\|.\|..RE..TP.B .../libsdirectory for libraries that are created/needed while compilingthe project.RS.TP.B sparc\-sunos5\-cc/directory for libraries that belong to a specific system.TP\&.\|.\|..RE..TP.B .../incsdirectory for include files that are created/needed while compilingthe project.RS.TP.B sparc\-sunos5\-cc/directory for include files that belong to a specific system.TP\&.\|.\|..RE.TP\&.\|.\|..RE..ad.PD.SH AUTHOR.nfJ\*org SchillingSeestr. 110D-13353 BerlinGermany.fi.PPMail bugs and suggestions to:.PP.Bjoerg@schily.isdn.cs.tu-berlin.deor.Bjs@cs.tu-berlin.deor.Bjes@fokus.gmd.de

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -