JP2008003841A - Build processing method, device and program - Google Patents

Build processing method, device and program Download PDF

Info

Publication number
JP2008003841A
JP2008003841A JP2006172638A JP2006172638A JP2008003841A JP 2008003841 A JP2008003841 A JP 2008003841A JP 2006172638 A JP2006172638 A JP 2006172638A JP 2006172638 A JP2006172638 A JP 2006172638A JP 2008003841 A JP2008003841 A JP 2008003841A
Authority
JP
Japan
Prior art keywords
build
description
module
file
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2006172638A
Other languages
Japanese (ja)
Inventor
Akiya Nakai
晶也 中井
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Canon Inc
Original Assignee
Canon Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Canon Inc filed Critical Canon Inc
Priority to JP2006172638A priority Critical patent/JP2008003841A/en
Publication of JP2008003841A publication Critical patent/JP2008003841A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Devices For Executing Special Programs (AREA)
  • Stored Programmes (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a build processing method that can simply respond to changes of targets and its methods. <P>SOLUTION: A build processing device has a plurality of module configuration description parts 106 to 109 each for describing source files constituting a module in software by identification information on the source files, module link description parts 103 and 104 each for describing modules to be linked by identification information identifying a plurality of module configuration description parts, and build processing description parts 114 and 118 each for describing a building method in association with identification information on the module configuration description parts and module link description parts. <P>COPYRIGHT: (C)2008,JPO&INPIT

Description

本発明は、ソースコードに基づいて実行可能なプログラムを生成するためのビルド処理技術に関する。   The present invention relates to a build processing technique for generating an executable program based on source code.

従来、大規模なソフトウェアを開発する場合に、全体のソフトウェアを独立して設計可能な小さな単位のモジュールに分割し、モジュール毎にソースコードを記述してソースファイルとして保存している。そして、このソースファイルを他のソフトウェアで共通に利用できるようにしている。   Conventionally, when developing large-scale software, the entire software is divided into small units of modules that can be designed independently, and the source code is described for each module and stored as a source file. This source file can be shared by other software.

このようなモジュールに係るソースファイルに対してコンパイル、リンクなどを行うことによりビルド処理して、実際に動作するプログラムを生成する場合には、次のような情報をコンピュータに指定する必要がある。この指定情報としては、ビルド処理(コンパイル/リンク)対象のソースファイルのファイル名、それらソースファイルに対するビルド処理のルールや詳細な処理方法がある。ここで、ビルド処理のルールとは、どのような処理を行なうかを示すルールである。また、詳細な処理方法とは、最適化コンパイルや、インクルードパスなどである。   In order to generate a program that actually operates by performing a build process by compiling and linking a source file related to such a module, it is necessary to specify the following information to the computer. As this designation information, there are the file name of the source file to be built (compiled / linked), the rules of the build process for these source files and the detailed processing method. Here, the rule of the build process is a rule indicating what kind of process is performed. Further, the detailed processing method includes optimization compilation, include path, and the like.

このようなビルド処理に関する情報をコンピュータに指定する方法として、Makeコマンドを用いる方法が一般に知られている。   As a method for designating information relating to such a build process to a computer, a method using a Make command is generally known.

このmakeコマンドは、図10に例示したような内容のMakefileを参照してビルドを行うものである。なお、図10において、行頭に示した「1.」等の数字は、説明のために付した行番号である(図11も同様)。   This make command is used to build with reference to a Makefile having the contents illustrated in FIG. In FIG. 10, numbers such as “1.” shown at the beginning of the line are line numbers given for explanation (the same applies to FIG. 11).

図10の例では、9行目に処理対象のファイルのファイル名が記述され、1〜3行目、5〜8行目にビルド処理のルールが記述され、4行目に詳細な処理方法が記述されている。   In the example of FIG. 10, the file name of the processing target file is described in the 9th line, the rules of the build process are described in the 1st to 3rd lines and the 5th to 8th lines, and the detailed processing method is described in the 4th line. is described.

このようなmakeコマンドを利用してモジュール毎に設計/実装を行う場合、一般に、1つのモジュールに対して1つのディレクトリを作成する。そして、そのディレクトリにモジュールを構成する全ソースファイルと1つのMakefileを配置する。このMakefileでは、モジュールの全ソースファイルを処理するように記述する。   When designing / implementing each module using such a make command, one directory is generally created for one module. Then, all source files constituting the module and one Makefile are arranged in the directory. In this Makefile, it is described that all source files of the module are processed.

ところで、ソフトウェア開発において、1つのモジュールに対して複数のビルド処理の仕方を指定したい場合がある。例えば、機器制御の組込みソフトウェア開発においては、同じモジュールに係るソースファイルを、旧製品CPU用、新製品CPU用、開発PC用等の複数のターゲットシステム向きにコンパイルする場合である。以下、「ターゲットシステム」を単に「ターゲット」と記述する。また、ターゲットとは、ビルド処理により生成すべき一連のプログラムという意味も包含する。   By the way, in software development, there are cases where it is desired to specify a plurality of build processing methods for one module. For example, in device control embedded software development, a source file related to the same module is compiled for a plurality of target systems such as an old product CPU, a new product CPU, and a development PC. Hereinafter, “target system” is simply referred to as “target”. The target also includes the meaning of a series of programs to be generated by the build process.

しかしながら、前述のMakefileでは、ビルド処理の仕方を1通りしか記述できない。このため、所定のモジュールに係るソースファイルを複数のターゲット向きにコンパイルする場合は、そのモジュールに対してターゲット毎の複数のMakefileを用意する必要がある。   However, the above-described Makefile can describe only one way of build processing. For this reason, when compiling a source file related to a predetermined module for a plurality of targets, it is necessary to prepare a plurality of makefiles for each target for the module.

また、複数のMakefileを用意したとしても、以下のような問題がある。第1に、それら複数のMakefileにおいて処理対象のファイルは一致している必要がある。従って、ソースファイルを追加する場合は、全てのMakefileに対して同じソースファイルを追加する必要がある。   Even if a plurality of makefiles are prepared, there are the following problems. First, the files to be processed in the plurality of Makefiles must match. Therefore, when adding a source file, it is necessary to add the same source file to all Makefiles.

第2に、同じターゲット用のMakefileにおいては、各モジュール間でビルド処理の仕方の記述を統一しておく必要がある。この統一化は、人手を介して行うことになり、煩雑であるとともに誤りが混入する危険性がある。   Secondly, in the Makefile for the same target, it is necessary to unify the description of the build processing method among the modules. This unification is performed manually, which is complicated and has a risk of introducing errors.

さらに、アセンブリソースコードなど、ターゲットのCPUに依存したソースコードも存在する。このようなターゲットの種別に依存するソースコードは、ターゲットの種別ごとに別のソースファイルに記述される。Makefileに記述する際には、それらのソースファイルは、ターゲット毎に異なるファイル名を記述する必要があり、この記述も人手を介して行うことになり、煩雑であるとともに誤りが混入する危険性がある。   Furthermore, there are also source codes that depend on the target CPU, such as assembly source code. The source code depending on the target type is described in a separate source file for each target type. When describing in Makefile, it is necessary to describe different file names for each source of each source file. This description is also done manually, and there is a risk of being complicated and introducing errors. is there.

また、複数のモジュールに分割して、それらモジュール毎にMakefileを作成し、それらの各モジュールを結合して1つのプログラムを作成する場合には、また別の問題がある。   Further, when dividing a plurality of modules, creating a Makefile for each module, and combining these modules to create one program, there is another problem.

図11(A)〜(C)は、そのような場合のMakefileの例である。ここでは、モジュール毎にディレクトリを用意し、ディレクトリ毎にソースファイルとMakefileを持つ場合を想定している。図11(A)は、AaaモジュールのMakefileを示している。このMakefileのファイルパス名は、Aaa/Makefileとなっている。図11(B)は、BbbモジュールのMakefileを示している。このMakefileのファイルパス名は、Bbb/Makefileとなっている。   FIGS. 11A to 11C are examples of Makefiles in such a case. Here, it is assumed that a directory is prepared for each module, and each directory has a source file and a Makefile. FIG. 11A shows the Makefile of the Aaa module. The file path name of this Makefile is Aaa / Makefile. FIG. 11B shows the Makefile of the Bbb module. The file path name of this Makefile is Bbb / Makefile.

また、図11(C)は、AaaとBbbの2つのモジュールに係るオブジェクトファイルを纏めるべくリンクさせるためのMakefileを示している。図11(C)のMakefileでは、Aaa,Bbbの2つのモジュールに係るオブジェクトファイルをリンクさせる。そのために、それらモジュールのビルド処理の結果として、どのようなオブジェクトファイルが在るかを記述する必要がある(図11(C)の2行目の記述)。   FIG. 11C shows a Makefile for linking object files related to two modules Aaa and Bbb. In the Makefile in FIG. 11C, object files related to two modules Aaa and Bbb are linked. Therefore, it is necessary to describe what kind of object file exists as a result of the build processing of those modules (description on the second line in FIG. 11C).

また、各モジュールの内部がどのようなファイルで構成されているかの詳細は、そのモジュール内で閉じた情報として管理されている。従って、それらモジュールを下位のモジュールとして利用する図11(C)のMakefile等の上位のMakefileでは、本来、それら下位モジュールの内部構成を意識すべきではない。しかしながら、Makefileでは、モジュールの構成を外部に知らせることができないため、下位モジュールの内部構成を上位モジュールに係るMakefileに記述せざるを得なくなってしまっている。   Further, the details of what kind of file the inside of each module is configured is managed as information closed within the module. Therefore, in the higher-level Makefile such as the Makefile in FIG. 11C that uses these modules as lower-level modules, the internal configuration of these lower-level modules should not be conscious. However, in Makefile, the module configuration cannot be notified to the outside, so the internal configuration of the lower module must be described in the Makefile related to the upper module.

さらに、複数のモジュールの結合からなる大規模なプログラムを複数のターゲット用にビルド処理する方法が、下記の特許文献1に開示されている。しかし、この特許文献1に係る方法では、使用すべきモジュールを選択するだけでなく、ターゲット毎に人手により多数のデータを入力する必要があり、誤りが混入する危険性がある。また、使用すべきモジュールの追加や変更がある毎に上記の入力操作を行う必要がある。
特開2000−235444
Further, a method for building a large-scale program composed of a combination of a plurality of modules for a plurality of targets is disclosed in Patent Document 1 below. However, in the method according to Patent Document 1, it is necessary not only to select a module to be used, but also to input a large amount of data manually for each target, and there is a risk of errors being mixed. Further, it is necessary to perform the above input operation every time a module to be used is added or changed.
JP 2000-235444 A

本発明は、このような背景の下になされたもので、その目的は、ターゲットやビルド処理の仕方の変更に簡単に対処し得るビルド処理方法を提供することにある。   The present invention has been made under such a background, and an object thereof is to provide a build processing method that can easily cope with a change in a target and a method of the build processing.

上記目的を達成するため、本発明は、ソフトウェアにおける各モジュールを構成するソースファイルの識別情報をモジュール毎に記述する複数のモジュール構成記述部と、前記複数のモジュール構成記述部を識別する識別情報を用いて、結合すべき前記モジュールを記述するモジュール結合記述部と、各ターゲットに対して、前記モジュール構成記述部または前記ソースファイルの識別情報と関連付けてビルド処理の仕方を記述するビルド処理記述部とを参照するビルド処理方法において、前記ターゲット及び前記モジュール結合記述部の指定を受け付ける工程と、指定された前記ターゲットに対応する前記ビルド処理記述部の内容を読み込む工程と、指定された前記モジュール結合記述部で記述された結合すべき前記複数のモジュール構成記述部の内容を読み込む工程と、読み込まれた前記ビルド処理記述部の内容及び前記複数のモジュール構成記述部の内容に基づいてビルド処理を実行する工程とを有することを特徴とする。   In order to achieve the above object, the present invention provides a plurality of module configuration description portions for describing identification information of source files constituting each module in software for each module, and identification information for identifying the plurality of module configuration description portions. A module combination description unit that describes the modules to be combined, and a build process description unit that describes how to perform a build process in association with identification information of the module configuration description unit or the source file for each target; In the build processing method that refers to: a step of accepting designation of the target and the module combination description part, a step of reading the contents of the build process description part corresponding to the designated target, and the designated module combination description The plurality of module configurations to be combined described in the section And having a step of reading the contents of the predicate, and a step of executing a build process based on the content and the content of said plurality of module configuration description part of the build process description part loaded.

本発明によれば、ターゲットやビルド処理の仕方の変更に簡単に対処し得るビルド処理方法を提供することが可能となる。   According to the present invention, it is possible to provide a build processing method that can easily cope with changes in the target and the way of the build processing.

以下、本発明を実施するための最良の形態を、図面に基づいて説明する。   The best mode for carrying out the present invention will be described below with reference to the drawings.

図12は、本発明の実施の形態に係るコンピュータのハードウェア構成を示すブロック図である。このコンピュータは、CPU1201、情報を表示する表示装置1202、キーボードやマウスなどの入力装置1203、RAMなどの一次記憶装置1204、HDDなどの二次記憶装置1205、通信装置1206を有している。以下では、一次記憶装置1204は単にメモリ1204とも称する。また、これらデバイスは、相互に通信可能にバスライン1207を介して接続されている。CPU1201は各部を制御し、後述する処理手順に対応するプログラムを実行する。このプログラムは二次記憶装置1205から一次記憶装置1204に読み出されて実行される。   FIG. 12 is a block diagram showing a hardware configuration of the computer according to the embodiment of the present invention. This computer includes a CPU 1201, a display device 1202 for displaying information, an input device 1203 such as a keyboard and a mouse, a primary storage device 1204 such as a RAM, a secondary storage device 1205 such as an HDD, and a communication device 1206. Hereinafter, the primary storage device 1204 is also simply referred to as a memory 1204. These devices are connected via a bus line 1207 so that they can communicate with each other. The CPU 1201 controls each unit and executes a program corresponding to a processing procedure described later. This program is read from the secondary storage device 1205 to the primary storage device 1204 and executed.

図1は、本発明の実施の形態に係るビルド処理方法を示す図である。図1のビルド処理方法に係る記述内容は、例えば、図12に示したコンピュータ内で二次記憶装置1205のハードディスク等の記憶媒体に記憶されている。   FIG. 1 is a diagram showing a build processing method according to an embodiment of the present invention. The description content related to the build processing method of FIG. 1 is stored in a storage medium such as a hard disk of the secondary storage device 1205 in the computer shown in FIG.

図1に示したように、ビルド指令情報101は、ビルド対象物記述部110とターゲット記述部102とを用いて、所望のビルド対象物と所望のターゲットのためのビルド処理方法を指定している。なお、ビルド指令情報101における具体的なビルド処理方法の指定の仕方は、後述する。   As shown in FIG. 1, the build command information 101 uses the build object description unit 110 and the target description unit 102 to specify a build process method for a desired build object and a desired target. . A specific method of specifying the build processing method in the build command information 101 will be described later.

ビルド対象物記述部110は、モジュール構成記述部106〜109とモジュール結合記述部103,104とにより構成されている。また、ターゲット記述部102は、複数のビルド処理記述部114,118により構成されている。   The build object description unit 110 includes module configuration description units 106 to 109 and module combination description units 103 and 104. The target description unit 102 includes a plurality of build process description units 114 and 118.

ビルド対象物記述部110のモジュール構成記述部106〜109では、ビルド処理に使用される各モジュールそれ自体が記述されることはなく、それらモジュールを構成するビルド対象物の識別情報(ソースファイルの名称など)だけが記述されている。また、モジュール結合記述部103,104は、どのモジュールを結合して実行プログラムを作成すべきかを記述する部分である。このモジュール結合記述部103,104においても、モジュール構成記述部106〜109の識別情報、すなわちモジュール構成記述部106〜109の名称だけが記述されている。   The module configuration description units 106 to 109 of the build target object description unit 110 do not describe each module itself used in the build process, but identify identification information (names of source files) of the build target objects constituting the modules. Only). The module combination description units 103 and 104 are parts that describe which modules should be combined to create an execution program. Also in the module combination description units 103 and 104, only the identification information of the module configuration description units 106 to 109, that is, the names of the module configuration description units 106 to 109 are described.

ターゲット記述部102は、各ターゲットに1対1に対応するビルド処理記述部114,118を有している。これらビルド処理記述部114,118は、それぞれビルド処理プログラム記述部111,115、ビルド処理適用ルール記述部112,116、ビルド処理パラメータ記述部113,117により構成されている。   The target description unit 102 includes build process description units 114 and 118 corresponding to each target in a one-to-one manner. These build process description units 114 and 118 are configured by build process program description units 111 and 115, build process application rule description units 112 and 116, and build process parameter description units 113 and 117, respectively.

ビルド処理プログラム記述部111,115には、ビルド処理(コンパイルなど)を行うプログラムの所在を示す情報、例えば実際にコンパイルを行なうコンパイラのパス名などが含まれている。また、ビルド処理適用ルール記述部112,116には、ビルド対象物記述部110に記述されているビルド対象物の特徴に応じて、実際のビルド処理において入力ファイルや出力ファイルを特定する方法、ビルド処理を行なうコンパイラを特定する方法が記述されている。また、ビルド処理パラメータ記述部113,117には、実際のビルド処理においてビルド処理を行うコンパイラに対して指定する情報、例えば最適化オプションやマクロ定義などの情報が記述されている。   The build process program description units 111 and 115 include information indicating the location of a program that performs a build process (compilation or the like), for example, a path name of a compiler that actually compiles. In addition, the build process application rule description units 112 and 116 include a method for specifying an input file and an output file in an actual build process according to the characteristics of the build object described in the build object description unit 110, and a build. A method for specifying a compiler to perform processing is described. Also, in the build process parameter description sections 113 and 117, information specified for the compiler that performs the build process in the actual build process, for example, information such as optimization options and macro definitions is described.

前述のように、ビルド処理記述部114,118は、ターゲットごとに用意されるものである。また、ターゲット記述部102においては、それらターゲット毎に、そのターゲット名称とそのターゲットに対して適用すべきビルド処理記述部114,118の名称とを対で記憶している。   As described above, the build process description units 114 and 118 are prepared for each target. Further, the target description unit 102 stores, for each target, a pair of the target name and the names of the build processing description units 114 and 118 to be applied to the target.

このような構成に基づいて、所望のターゲットのためのビルド指令情報101としては、ビルド対象物記述部110のモジュール結合記述部103,104と、ターゲット記述部102に記述されているターゲット名称との組を指定するようにしている。   Based on such a configuration, as the build command information 101 for a desired target, the module combination description units 103 and 104 of the build target object description unit 110 and the target names described in the target description unit 102 A set is specified.

従って、或るモジュールの内部構成が変化した場合は、モジュール構成記述部106〜109の記述を変更するだけで対処することができる。また、或るターゲットのビルド処理方法が変化した場合は、そのターゲットに対応するビルド処理記述部114,118の記述を変更するだけで対処することができる。さらに、ターゲットが追加された場合は、新たにビルド処理記述部を記述し、ターゲット記述部102に、そのターゲットと新たなビルド処理記述部の名称を記述すればよい。   Therefore, when the internal configuration of a certain module changes, it can be dealt with only by changing the description of the module configuration description units 106-109. Further, when the build processing method of a certain target changes, it can be dealt with only by changing the description of the build processing description sections 114 and 118 corresponding to the target. Furthermore, when a target is added, a new build process description part may be described, and the target and the name of the new build process description part may be described in the target description part 102.

このように、モジュールの内部構成やターゲットのビルド処理方法の変化、ターゲットの追加が発生したとしても、必要最小限の記述変更で対処することが可能となる。また、ターゲット毎に異なるソースファイルが存在していても、所望のターゲットに係るソースファイルを指定することができる。   As described above, even if the internal configuration of the module, the build processing method of the target, or the addition of the target occurs, it is possible to cope with the minimum necessary description change. Moreover, even if a different source file exists for each target, a source file related to a desired target can be designated.

次に、図1に示した各ブロックの具体的な内容を、図2〜図9を用いて説明する。
なお、図2〜図4に示した「1.」等の数字は、説明のために付した行番号である。
Next, the specific contents of each block shown in FIG. 1 will be described with reference to FIGS.
The numbers such as “1.” shown in FIGS. 2 to 4 are line numbers given for explanation.

[ビルド処理記述部の記述例]
まず、ビルド処理記述部114,118の具体例を説明する。本実施の形態で例示する各記述内容は、図5に示すような階層ディレクトリ構成の中に配置されたテキストファイルとして保管する。なお、図5において記号「/」が行末に付加されているシンボルは、ディレクトリ名を表し、記号「/」が行末に付加されていないシンボルは、ファイル名を表している。また、図5に示した作業ディレクトリには、ビルド処理記述に係るファイル以外に、ソースファイル、コンパイラ/アセンブラに係るファイルのファイル名も記述されている。
[Example of build process description]
First, a specific example of the build process description units 114 and 118 will be described. Each description content exemplified in the present embodiment is stored as a text file arranged in a hierarchical directory structure as shown in FIG. In FIG. 5, a symbol with a symbol “/” added to the end of a line represents a directory name, and a symbol without a symbol “/” added to the end of a line represents a file name. Further, in the working directory shown in FIG. 5, in addition to the file related to the build process description, the file names of the source file and the file related to the compiler / assembler are also described.

なお、ビルド処理の設定内容は、上記の例のように個別のファイルに分割して保管しても、或いはデータベースとして保管してもよい。以下、このようなビルド処理に係る設定ファイルの内容例を説明する。   The setting contents of the build process may be divided into individual files and stored as in the above example, or may be stored as a database. Hereinafter, an example of contents of a setting file related to such a build process will be described.

ターゲット記述部102は、図5に示したファイル「config/target.conf」として構成され、このファイル「config/target.conf」は、図2に示すような形で記述されている。図2において、1行目には、ターゲット名称として「win32pc」が記述されている。その2行目以降には、「win32pc」という名称のターゲットに係るビルド処理記述を指定するためのファイル名が記述されている。   The target description unit 102 is configured as a file “config / target.conf” illustrated in FIG. 5, and the file “config / target.conf” is described in a form illustrated in FIG. 2. In FIG. 2, “win32pc” is described as the target name in the first line. In the second and subsequent lines, a file name for designating a build process description relating to a target named “win32pc” is described.

すなわち、2行目には、ビルド処理プログラム記述部114,118に係るファイルのファイル名として、「config/win32pc/program.conf」が記述されている。また、3行目には、ビルド処理適用ルール記述部112,116に係るファイルのファイル名として、「config/win32pc/rule.conf」が記述されている。さらに、4行目には、ビルド処理パラメータ記述部113,117に係るファイルのファイル名として、「config/win32pc/parameter.conf」が記述されている。   That is, in the second line, “config / win32pc / program.conf” is described as the file name of the files related to the build processing program description units 114 and 118. In the third line, “config / win32pc / rule.conf” is described as the file name of the file related to the build process application rule description units 112 and 116. Further, in the fourth line, “config / win32pc / parameter.conf” is described as the file name of the file related to the build processing parameter description units 113 and 117.

なお、5行〜8行目には、1〜4行とは異なるターゲット「h8−2600N」に係る同様のターゲット記述がなされている。   In the fifth to eighth lines, the same target description relating to the target “h8-2600N” different from the first to fourth lines is described.

図3(A)は、ビルド処理プログラム記述部111,115に係るファイルの内容例を示している。この図3(A)に示したファイルにおける記述は、図5における「config/win32pc/program.conf」に相当するものである。   FIG. 3A shows an example of the contents of a file related to the build processing program description units 111 and 115. The description in the file shown in FIG. 3A corresponds to “config / win32pc / program.conf” in FIG.

図3(A)のファイルでは、1行目に「environmentvariable」というシンボルが記述され、このシンボルにより、2行目以降の記述がビルドプログラム実行の際に必要な環境変数の設定情報であることが示されている。   In the file of FIG. 3A, a symbol “environment variable” is described on the first line, and the description on the second line and thereafter is environment variable setting information necessary for executing the build program. It is shown.

2行目には、「PATH」という名称の環境変数をどのように設定すべきかが記述されている。3行目には、「program」というシンボルが記述され、このシンボルにより、4行目以降の記述がビルド処理実行の際に使用すべきプログラムの指定情報であることが示されている。   The second line describes how the environment variable named “PATH” should be set. In the third line, a symbol “program” is described, and this symbol indicates that the description in the fourth and subsequent lines is program designation information to be used when executing the build process.

4行目には、「COMPILER」というシンボルに係るプログラムを実行する際には、「gcc.exe」というプログラムファイルを起動するということが記述されている。5行〜6行目には、同様に、「ASSEMBLER」、「LINKER」というシンボルに係るプログラムには、それぞれ「as.exe」、「ld.exe」というプログラムファイルが対応することが記述されている。   The fourth line describes that when a program related to the symbol “COMPILER” is executed, a program file “gcc.exe” is started. Similarly, the 5th to 6th lines describe that the programs relating to the symbols “ASSEMBLE” and “LINKER” correspond to the program files “as.exe” and “ld.exe”, respectively. Yes.

図3(B)は、ビルド処理適用ルール記述部112,116に係るファイルの内容例を示している。この図3(B)に示したファイルは、図5における「config/win32pc/rule.conf」に相当するものである。   FIG. 3B shows an example of the contents of a file related to the build process application rule description units 112 and 116. The file shown in FIG. 3B corresponds to “config / win32pc / rule.conf” in FIG.

図3(B)のファイルでは、1行目に「src*/*.target.c」という記述がなされている。この記述は、後述するモジュール結合記述部103,104およびモジュール構成記述部106〜109の中に現れるビルド対象の記述と一致させる文字列パターンを表している。そして、2行目〜4行目には、1行目の文字列パターンに一致したビルド対象に対して適用されるルールが記述されている。   In the file of FIG. 3B, the description “src * / *. Target.c” is described on the first line. This description represents a character string pattern that matches a description of a build target that appears in module combination description units 103 and 104 and module configuration description units 106 to 109 described later. In the second to fourth lines, rules to be applied to the build target that matches the character string pattern in the first line are described.

すなわち、2行目には、1行目の文字列パターンに一致したビルド対象の記述、すなわち、ビルド処理対象の入力ファイルのファイル名が「*1/*2.win32pc.c」であることが示されている。なお、このファイル名における「*1」、「*2」のような記述は、1行目の文字列パターンに一致した際に、「*」に対応する文字列に置換されて展開される。   That is, on the second line, the description of the build target that matches the character string pattern on the first line, that is, the file name of the input file to be built is “* 1 / * 2.win32pc.c”. It is shown. It should be noted that descriptions such as “* 1” and “* 2” in this file name are expanded by being replaced with a character string corresponding to “*” when they match the character string pattern on the first line.

3行目には、ビルド処理の出力ファイル名が、入力ファイル名と同様の形式で記述されている。4行目には、ビルド処理に使用するプログラムが記述されている。なお、4行目に記述されている「COMPILER」というシンボルは、図3(A)の4行目に記述されたシンボルと一致しており、実際のビルド処理に際しては、「gcc.exe」というプログラムファイルが起動される。   On the third line, the output file name of the build process is described in the same format as the input file name. The fourth line describes a program used for the build process. Note that the symbol “COMPILER” described in the fourth line matches the symbol described in the fourth line in FIG. 3A, and “gcc.exe” is used in the actual build process. The program file is started.

5行〜8行目、9行〜12行目、13行〜16行目にも、1行〜4行目と同様に、他の文字列パターンに一致するビルド対象に対し、実際にビルド処理する際の入力ファイル名、出力ファイル名、プログラム名が記述されている。なお、14行目に記述されている「@」は、1行〜13行目に係るビルド処理で出力された全ての出力ファイル名を総称するものである。   In the 5th to 8th lines, the 9th to 12th lines, and the 13th to 16th lines, as with the 1st to 4th lines, the actual build processing is performed for the build target that matches other character string patterns. The input file name, output file name, and program name are described. Note that “@” described in the 14th line is a generic name for all output file names output in the build process related to the 1st to 13th lines.

図3(C)は、ビルド処理パラメータ記述部113,117に係るファイルの内容例を示している。この図3(C)に示したファイルは、図5における「config/win32pc/parameter.conf」に相当するものである。   FIG. 3C shows an example of the contents of a file related to the build process parameter description units 113 and 117. The file shown in FIG. 3C corresponds to “config / win32pc / parameter.conf” in FIG.

図3(C)のファイルでは、1行目に「COMPILER」という、ビルド処理を行うプログラムのシンボルが指定されている。ここで指示されている「COMPILER」というシンボルは、図3(B)の4行目、8行目のシンボルと一致しており、実際のビルド処理に際しては、「gcc.exe」というプログラムファイルが起動される。   In the file of FIG. 3C, the symbol of the program for performing the build process, “COMPILER”, is specified on the first line. The symbol “COMPILER” indicated here matches the symbols in the fourth and eighth lines in FIG. 3B, and the program file “gcc.exe” is included in the actual build process. It is activated.

2行目には、1行目のプログラムに対して、どのような条件の場合にどのような詳細パラメータを渡すべきかが記述されている。なお、2行目の「$(INPUT)」、「$(OUTPUT)」という記述は、それぞれ、このビルド処理の際に指示される入力ファイルおよび出力ファイルのファイル名に置換されて解釈すべきことを意味する。2行目の記述における「$(INPUT)=〜ModuleA/*.c」は、入力ファイル名が「ModuleA/*.c」に一致する場合には、1行目に記述したプログラムに対して、「:」以降の文字列を詳細なパラメータとして渡すべきであることを意味する。   The second line describes what detailed parameters should be passed to the program on the first line under what conditions. Note that the description of “$ (INPUT)” and “$ (OUTPUT)” on the second line should be interpreted by replacing the input file name and output file name specified in this build process, respectively. Means. “$ (INPUT) = ˜ModuleA / *. C” in the description on the second line is the same as the program described on the first line when the input file name matches “ModuleA / *. C”. This means that the character string after “:” should be passed as a detailed parameter.

3行目には、入力ファイル名が2行目の条件に一致せず3行目の条件に一致した場合の詳細パラメータが記述されている。4行〜5行目、6行〜7行目には、それぞれ図3(B)の「ASSEMBLER」、「LINKER」に係るビルド処理の詳細なパラメータが記述されている。   The third line describes detailed parameters when the input file name does not match the condition of the second line but matches the condition of the third line. In the 4th to 5th lines and the 6th to 7th lines, detailed parameters of the build processing related to “ASSEMBLE” and “LINKER” in FIG. 3B are described, respectively.

なお、本実施の形態では、ビルド処理記述部114,118の記述内容を図3(A)〜(C)のように3つのファイルに分けて記述しているが、各記述をどのように分割してファイル化するかは任意であり、例えば、各記述を1つのファイルに纏めて記述することも可能である。   In this embodiment, the description contents of the build process description sections 114 and 118 are described in three files as shown in FIGS. 3A to 3C, but how each description is divided. It is arbitrary whether to make a file, for example, it is also possible to describe each description collectively in one file.

[ビルド対象物記述部の記述例]
次に、ビルド対象物記述部110の具体例を説明する。ビルド対象物記述部110の記述内容は、ビルド処理記述部114,118と同様に、図5に示したようなディレクトリに配置されたテキストファイルの形で保存される。
[Example of description in the build object description section]
Next, a specific example of the build target object description unit 110 will be described. Similar to the build process description units 114 and 118, the description content of the build target object description unit 110 is saved in the form of a text file arranged in a directory as shown in FIG.

図4(A)、(B)は、モジュール構成記述部106〜109に係るファイルの内容例を示している。図4(A)に示したファイルにおける記述は、図5における「ModuleA/ModuleA.mod」に相当するものである。   4A and 4B show examples of file contents related to the module configuration description units 106 to 109. FIG. The description in the file shown in FIG. 4A corresponds to “Module A / Module A. mod” in FIG.

図4(A)の記述は、図5に示したモジュール「ModuleA/ModuleA.mod」を構成するビルド対象物として、「Afunc.c」、「Alogic.s」という名称の2つのモジュールが存在することを示している。   In the description of FIG. 4A, there are two modules named “Afunc.c” and “Alogic.s” as build objects constituting the module “ModuleA / ModuleA.mod” shown in FIG. It is shown that.

図4(B)に示したファイルにおける記述は、図5における「ModuleB/Moduleb.mod」に相当するものである。この図4(B)の記述は、モジュール「ModuleA/ModuleA.mod」を構成するビルド対象物として、「Bfunc.c」、「Bsub.target.c」というという名称の2つのモジュールが存在することを示している。   The description in the file shown in FIG. 4B corresponds to “Module B / Module b. Mod” in FIG. In the description of FIG. 4B, there are two modules named “Bfunc.c” and “Bsub.target.c” as build objects constituting the module “ModuleA / ModuleA.mod”. Is shown.

図4(C)は、モジュール結合記述部103,104に係るファイルの内容例を示している。図4(C)に示したファイルにおける記述は、図5における「Build/win32pc.mod」に相当するものである。図4(C)において、1行目と2行目には、結合すべきモジュール(モジュール構成記述部)のファイル名が記述されている。3行目には、モジュール構成記述部での記述と同様に、ビルド対象物として「win32pc−main.c」という名称のモジュールが存在することが記述されている。4行目には、ビルド対象物として「ProgramAB.exe」という名称のプログラムが存在することが記述されている。   FIG. 4C shows an example of the contents of a file related to the module combination description units 103 and 104. The description in the file shown in FIG. 4C corresponds to “Build / win32pc.mod” in FIG. In FIG. 4C, the first and second lines describe the file names of modules (module configuration description units) to be combined. The third line describes that there is a module named “win32pc-main.c” as a build target, similar to the description in the module configuration description section. The fourth line describes that there is a program named “ProgramAB.exe” as a build target.

次に、上記のビルド処理記述部114,118とビルド対象物記述部110の記述に基づく実際のビルド処理を、図6〜図8に従って説明する。この図6〜図8のビルド処理に係るプログラムは、二次記憶装置1205のハードディスク上に保存されており、メモリ1204に展開されてCPU1201により実行される。なお、図5に示した、ビルド処理記述部114,118とビルド対象記述部110に係るファイルと、ソースファイルやコンパイラプログラムも、同じハードディスクに保存されている。   Next, an actual build process based on the descriptions of the build process description units 114 and 118 and the build object description unit 110 will be described with reference to FIGS. The programs related to the build processing in FIGS. 6 to 8 are stored on the hard disk of the secondary storage device 1205, expanded in the memory 1204, and executed by the CPU 1201. The files related to the build process description units 114 and 118 and the build target description unit 110, the source file, and the compiler program shown in FIG. 5 are also stored in the same hard disk.

操作者は、例えばビルド指令を行なうためのウインドウを表示装置1202上で開き、そのウインドウ上で、ターゲット名称、ビルド対象を示すモジュール結合記述部103,104に係るファイル叉はモジュール構成記述部106〜109に係るファイルの名称を入力装置1203を用いて入力する。これら入力されたビルド指令情報は、CPU1201により読み込まれる(ステップS601)。ここでは、ターゲット名称として「win32pc」、ビルド対象を示すファイルとして「Build/win32pc.mod」が指定されたものとして説明する。   For example, the operator opens a window for executing a build command on the display device 1202, and the file or module configuration description unit 106 to the module combination description units 103 and 104 indicating the target name and the build target are displayed on the window. The name of the file according to 109 is input using the input device 1203. The input build command information is read by the CPU 1201 (step S601). Here, it is assumed that “win32pc” is designated as the target name and “Build / win32pc.mod” is designated as the file indicating the build target.

次に、CPUはターゲット記述ファイル(上記した図2のconfig/target.conf)を読み込む。更に、CPU1201は、ステップS601で読み込んだターゲット名称に対するビルド処理プログラム記述ファイル名、ビルド処理適用ルール記述ファイル名、ビルド処理パラメータ記述ファイル名で示されるファイル内容を読み込む(ステップS602)。   Next, the CPU reads the target description file (config / target.conf in FIG. 2 described above). Further, the CPU 1201 reads the file contents indicated by the build processing program description file name, the build processing application rule description file name, and the build processing parameter description file name for the target name read in step S601 (step S602).

上記のように、ターゲット名称「win32pc」が指定された場合は、具体的には、ビルド処理プログラム記述に係るファイルである「config/win32pc/program.conf」の内容(図3の(A))を読み込む。また、ビルド処理適用ルール記述に係るファイルである「config/win32pc/rule.conf」の内容(図3の(B))を読み込む。さらに、ビルド処理パラメータ記述に係るファイルである「config/win32pc/parameter.conf」の内容(図3の(C))を読み込む。そして、CPUは、これら読み込んだファイルの内容をメモリ1204に保持しておく。   As described above, when the target name “win32pc” is specified, specifically, the contents of “config / win32pc / program.conf” that is a file related to the build processing program description ((A) in FIG. 3). Is read. Further, the contents of “config / win32pc / rule.conf” ((B) in FIG. 3), which is a file related to the build process application rule description, are read. Furthermore, the contents of “config / win32pc / parameter.conf” ((C) in FIG. 3), which is a file related to the build processing parameter description, are read. Then, the CPU holds the contents of these read files in the memory 1204.

次に、CPUは、ステップS601で指定されたビルド対象を示すファイル名「Build/win32pc.mod」に基づいて、そのファイルの内容(図4の(C))、すなわちビルド対象記述を読み込む(ステップS603)。そして、CPU1201は、指定されたターゲット用のビルド処理を実行する(ステップS604)。なお、ステップS603,S604の処理の詳細は、後述する。   Next, based on the file name “Build / win32pc.mod” indicating the build target specified in step S601, the CPU reads the contents of the file (FIG. 4C), that is, the build target description (step). S603). Then, the CPU 1201 executes a build process for the designated target (step S604). Details of the processes in steps S603 and S604 will be described later.

なお、上記の例では、ステップS601〜S603の処理により、図9に示すデータが得られてメモリ1204に保存される。   In the above example, the data shown in FIG. 9 is obtained and stored in the memory 1204 by the processes in steps S601 to S603.

次に、図6のステップS603におけるビルド対象記述の読み込み処理の詳細を、図7のフローチャートに基づいて説明する。   Next, details of the build target description reading process in step S603 of FIG. 6 will be described based on the flowchart of FIG.

ビルド対象記述の読み込み処理では、CPUは、まず、与えられたファイル名のファイルを1行目から順に1行を読み込む(ステップS701)。上記の指定例の場合は、最初に、図4の(C)に示すファイル「Build/win32pc.mod」の1行目を読み込むことになる。   In the process of reading the build target description, the CPU first reads one line from the first line of the file with the given file name (step S701). In the case of the above specification example, first, the first line of the file “Build / win32pc.mod” shown in FIG.

次に、CPU1201は、行判定を行う(ステップS702)。この行判定では、行を読むことができたか(エンドオブファイルに達していなかったか)、或いは、「src」、又は「output」で始まる行を読み込んだのか、「module」で始まる行を読み込んだのかを判定する。   Next, the CPU 1201 performs row determination (step S702). In this line determination, whether the line could be read (has not reached the end-of-file), or whether the line starting with “src” or “output” was read, or whether the line starting with “module” was read Determine.

上記の指定例では、1行目の内容である「module../../ModuleA/ModuleA.mod」という内容を読み込んでいるため、「module」で始まる行を読み込んだと判定する。このように「module」で始まる行を読み込んだと判定した場合は、CPU1201は、処理をステップS704に進める。   In the above specification example, since the content “module... / Module A / Module A. mod”, which is the content of the first line, is read, it is determined that the line starting with “module” has been read. When it is determined that the line starting with “module” has been read in this way, the CPU 1201 advances the process to step S704.

このステップS704では、CPU1201は、「../../ModuleA/ModuleA.mod」、すなわち、「ModuleA/ModuleA.mod」というファイルを読み込むことになる。このステップS704の処理を行った後は、CPU1201は、ステップS701に戻り、与えられたファイル名のファイルの次の行を読み込んで、ステップS702にて、その読み込み行について、上記の行判定を行う。   In step S704, the CPU 1201 reads a file “../../Module A / Module A. mod”, that is, a file “Module A / Module A. mod”. After performing the process of step S704, the CPU 1201 returns to step S701, reads the next line of the file with the given file name, and performs the above line determination for the read line in step S702. .

CPU1201は、ステップS702にて、ステップS701で読み込んだ行が「src」、又は「output」で始まる行であると判定した場合は、ステップS703の入出力・処理決定を行う。例えば、図4の(A)に示すファイル「ModuleA/ModuleA.mod」の1行目の「src Afunc.c」等の行を読み込んだ場合は、ステップS703の入出力・処理決定が行われる。   If the CPU 1201 determines in step S702 that the line read in step S701 is a line starting with “src” or “output”, the CPU 1201 performs input / output / processing determination in step S703. For example, when a line such as “src Afunc.c” in the first line of the file “Module A / Module A. mod” shown in FIG. 4A is read, the input / output / processing determination in step S703 is performed.

この入出力・処理決定では、CPU1201は、ビルド対象物のビルド処理の仕方として、ビルド処理の入力ファイル、出力ファイル、処理プログラムと、その処理プログラムに与える詳細な指定情報を生成して保存する。   In this input / output / process determination, the CPU 1201 generates and stores a build process input file, an output file, a processing program, and detailed designation information to be given to the processing program as a build processing method of the build target.

このステップS703における入出力・処理決定の詳細を、図8のフローチャートに基づいて説明する。   Details of the input / output / processing determination in step S703 will be described with reference to the flowchart of FIG.

CPU1201は、入出力・処理決定では、まず、図6のステップS602で読み込んで保持しておいたビルド処理記述の情報を参照して、図7のステップS701で読み込んだ行が、ビルド処理適用ルール記述(図3の(B))のうちのどのルールに一致するかを判定する(ステップS801)。   In the input / output / process determination, the CPU 1201 first refers to the build process description information read and held in step S602 in FIG. 6, and the line read in step S701 in FIG. It is determined which rule of the description (FIG. 3B) matches (step S801).

例えば、図7のステップS701でファイル「ModuleA/ModuleA.mod」の1行目を読み込んだ場合に、その1行目が「src Afunc.c」であったとする。この場合、図3(B)に示したように、「src Afunc.c」というパターンは、ファイル「config/win32pc/rule.conf」の5行目のパターン(src*/*.c)に一致する。従って、この1行目で示しているビルド対象に対するビルド処理の入力ファイル、出力ファイル、処理プログラムとしては、当該ファイル「config/win32pc/rule.conf」の6〜8行目に記述されているものに決定する。   For example, when the first line of the file “Module A / Module A. mod” is read in step S701 in FIG. 7, the first line is “src Afunc. C”. In this case, as shown in FIG. 3B, the pattern “src Afunc.c” matches the pattern (src * / *. C) on the fifth line of the file “config / win32pc / rule.conf”. To do. Therefore, the input file, output file, and processing program of the build process for the build target shown in the first line are those described in the sixth to eighth lines of the file “config / win32pc / rule.conf”. To decide.

次に、CPU1201は、ビルド処理適用ルール記述における「input=」、「output=」の記述に基づいて、実際の入出力ファイル名を決定する(ステップS802)。例えば上記の例では、「src Afunc.c」というパターンは、図3(B)のファイル「config/win32pc/rule.conf」の5行目のパターンに一致している。従って、6行目の「input=*1/*2.c」、7行目の「outpu=*1/win32pc/*2.o」の「*」を、「Afunc」に置換することで、実際に使用する入出力ファイル名を決定する。   Next, the CPU 1201 determines an actual input / output file name based on the descriptions “input =” and “output =” in the build process application rule description (step S802). For example, in the above example, the pattern “src Afunc.c” matches the pattern in the fifth line of the file “config / win32pc / rule.conf” in FIG. Therefore, by replacing “*” in “input = * 1 / * 2.c” on the sixth line and “output = * 1 / win32pc / * 2.o” on the seventh line with “Afunc”, Determine the actual input / output file name to be used.

なお、ビルド処理適用ルール記述の中に「@」が含まれている場合は、CPU1201は、それまでに出現した全てのビルド処理の出力ファイル名を羅列するような形で上記の置換を行う。   If “@” is included in the build process application rule description, the CPU 1201 performs the above replacement in a form that lists output file names of all the build processes that have appeared so far.

次に、CPU1201は、下記のようにして処理方法を決定する(ステップS803)。すなわち、CPU1201は、ビルド処理適用ルール記述における「program=」の記述に基づいて、処理プログラムを示すシンボルを取得すると共に、ビルド処理プログラム記述の内容(図3の(A))を介して、実際の処理プログラム名を取得する。さらに、CPU1201は、処理プログラムを示すシンボルと、ステップS802で決定した入出力ファイル名に基づいて、ビルド処理パラメータ記述(図3の(C))の設定を参照して、処理プログラムに渡すパラメータを決定する。   Next, the CPU 1201 determines a processing method as follows (step S803). That is, the CPU 1201 obtains a symbol indicating a processing program based on the description of “program =” in the build processing application rule description, and actually uses the contents of the build processing program description ((A) in FIG. 3). Get the name of the processing program. Further, the CPU 1201 refers to the setting of the build processing parameter description ((C) in FIG. 3) based on the symbol indicating the processing program and the input / output file name determined in step S802, and sets parameters to be passed to the processing program. decide.

次に、CPU1201は、決定した入出力、及び処理方法に関するデータをメモリ1204に記録する(ステップS804)。この処理では、CPU1201は、ステップS802,S803で決定したビルド処理の入力ファイル名、出力ファイル名、処理プログラム名、処理プログラムに渡すパラメータ、そのビルド処理対象が記述されていたファイル名を、一組のデータとしてメモリ1204に保持する。   Next, the CPU 1201 records data on the determined input / output and processing method in the memory 1204 (step S804). In this processing, the CPU 1201 sets a set of input file names, output file names, processing program names, parameters to be passed to the processing programs, and file names in which the build processing targets are described, determined in steps S802 and S803. Is stored in the memory 1204 as data.

すなわち、CPU1201は、まず、図6のステップS602で読み込んで保持しておいたビルド処理記述の情報から、環境変数設定の情報を抽出して設定する。例えば、上記の例では、図5に示した作業ディレクトリにおけるファイル「config/win32pc/program.confの’einvironmentvariable」の項目に記述されていた「PATH」というパラメータを設定する。   That is, the CPU 1201 first extracts and sets environment variable setting information from the build process description information read and held in step S602 of FIG. For example, in the above example, the parameter “PATH” described in the item “einventive variable of file“ config / win32pc / program.conf ”in the working directory shown in FIG. 5 is set.

さらに、CPU1201は、図6のステップS601〜S603の処理で得られた図9に示すデータを、上から1行ずつ実行していく。この際、カレントワーキングディレクトリは、図9に示した「ビルド処理対象記述ファイル」の存在するディレクトリとなる。   Further, the CPU 1201 executes the data shown in FIG. 9 obtained by the processing in steps S601 to S603 in FIG. 6 line by line from the top. At this time, the current working directory is a directory in which the “build process target description file” shown in FIG. 9 exists.

そして、図9に示した「処理プログラム」は、図9の「処理プログラムに渡すパラメータ」に依拠して実行される。すなわち、図3(C)に示した2,3,5,7行目の「$(INPUT)=」、「$(OUTPUT)=」における「*」は、図9に示した項目「入力ファイル」、「出力ファイル」のファイル名に置換される。この置換されたファイル名は、カレントワーキングディレクトリの相対ファイル名として機能する。   The “processing program” shown in FIG. 9 is executed depending on the “parameters passed to the processing program” in FIG. That is, “*” in “$ (INPUT) =” and “$ (OUTPUT) =” in the second, third, fifth, and seventh lines shown in FIG. 3C indicates the item “input file” shown in FIG. ”And“ output file ”. This replaced file name functions as a relative file name of the current working directory.

以上の入出力・処理決定は、図7においてステップS703に移行する毎に行われ、その都度、上記の一組のデータがメモリ1204に追加されていく。このようにして、指定されたターゲット用のビルド処理が実行される。   The above input / output / process determination is performed every time the process proceeds to step S703 in FIG. 7, and the set of data is added to the memory 1204 each time. In this way, the build process for the specified target is executed.

なお、本発明は、上記の実施の形態に限定されることなく、例えば、ターゲット用のビルド処理以外のソースコード処理についても適用することが可能である。   The present invention is not limited to the above-described embodiment, and can be applied to, for example, source code processing other than target build processing.

例えば、ビルド処理プログラムの一部として、ソースコードの危険個所を全モジュールに対して警告する静的解析ツールを指定したビルド処理記述を作成し、そのビルド処理記述を指定する内容を実施の形態と同様の手法で盛り込むことも可能である。   For example, as part of the build processing program, create a build processing description that specifies a static analysis tool that warns all modules of dangerous locations in the source code, and specify the build processing description as the embodiment. It is also possible to include in the same manner.

また、ソースコードに係るメトリクス(コード行数や複雑度など)を計測するために、ビルド処理プログラムの一部として、メトリクス計測プログラムを指定する内容を実施の形態と同様の手法で盛り込むことも可能である。   In addition, in order to measure metrics related to the source code (number of code lines, complexity, etc.), it is possible to include the contents specifying the metrics measurement program as part of the build processing program using the same method as in the embodiment. It is.

さらに、本発明の目的は、前述した実施の形態の機能を実現するソフトウェアのプログラムコードを記憶した記憶媒体を、システム或いは装置に供給し、そのシステム或いは装置のコンピュータが記憶媒体からプログラムコードを読み出し実行することによっても達成される。   Furthermore, an object of the present invention is to supply a storage medium storing software program codes for realizing the functions of the above-described embodiments to a system or apparatus, and the computer of the system or apparatus reads the program codes from the storage medium. It is also achieved by executing.

この場合、記憶媒体から読み出されたプログラムコード自体が前述した実施の形態の機能を実現することになり、そのプログラムコード及び該プログラムコードを記憶した記憶媒体は本発明を構成することになる。   In this case, the program code itself read from the storage medium realizes the functions of the above-described embodiments, and the program code and the storage medium storing the program code constitute the present invention.

また、プログラムコードを供給するための記憶媒体としては、例えば、フロッピー(登録商標)ディスク、ハードディスク、光磁気ディスク、CD−ROM、CD−R、CD−RW、DVD−ROM、DVD−RAM、DVD−RW、DVD+RW等の光ディスク、磁気テープ、不揮発性のメモリカード、ROM等を用いることができる。または、プログラムコードをネットワークを介してダウンロードしてもよい。   Examples of the storage medium for supplying the program code include a floppy (registered trademark) disk, a hard disk, a magneto-optical disk, a CD-ROM, a CD-R, a CD-RW, a DVD-ROM, a DVD-RAM, and a DVD. An optical disc such as RW or DVD + RW, a magnetic tape, a nonvolatile memory card, a ROM, or the like can be used. Alternatively, the program code may be downloaded via a network.

また、コンピュータが読み出したプログラムコードを実行することにより、前述した実施の形態の機能が実現されるだけではなく、そのプログラムコードの指示に基づき、コンピュータ上で稼動しているOS(オペレーティングシステム)等が実際の処理の一部または全部を行い、その処理によって前述した実施の形態の機能が実現される場合も含まれる。   Further, by executing the program code read by the computer, not only the functions of the above-described embodiments are realized, but also an OS (operating system) or the like running on the computer based on the instruction of the program code. Includes a case where part or all of the actual processing is performed and the functions of the above-described embodiments are realized by the processing.

さらに、記憶媒体から読み出されたプログラムコードが、コンピュータに挿入された機能拡張ボードやコンピュータに接続された機能拡張ユニットに備わるメモリに書き込まれた後、そのプログラムコードの指示に基づき、その拡張機能を拡張ボードや拡張ユニットに備わるCPU等が実際の処理の一部または全部を行い、その処理によって前述した実施の形態の機能が実現される場合も含まれる。   Furthermore, after the program code read from the storage medium is written to a memory provided in a function expansion board inserted into the computer or a function expansion unit connected to the computer, the expanded function is based on the instruction of the program code. This includes a case where a CPU or the like provided on the expansion board or the expansion unit performs part or all of the actual processing and the functions of the above-described embodiments are realized by the processing.

本発明の実施の形態に係るビルド処理方法を示す機能ブロック図である。It is a functional block diagram which shows the build processing method which concerns on embodiment of this invention. ターゲット記述例を示す図である。It is a figure which shows the example of a target description. ビルド処理記述例を示す図である。It is a figure which shows the example of a build process description. ビルド対象物記述例を示す図である。It is a figure which shows the example of a build target object description. ビルド処理のための作業ディレクトリの構成例を示す図である。It is a figure which shows the structural example of the working directory for a build process. ビルド処理の概要を示すフローチャートである。It is a flowchart which shows the outline | summary of a build process. 図6のステップS603におけるビルド対象記述の読み込み処理の手順を示すフローチャートである。FIG. 7 is a flowchart illustrating a procedure of a build target description reading process in step S603 of FIG. 6. FIG. 図7のステップS703における入出力・処理決定の手順を示すフローチャートである。It is a flowchart which shows the procedure of the input / output and process determination in step S703 of FIG. 図6〜図8の処理で得られて保存されたデータ例を示す図である。It is a figure which shows the example of data obtained by the process of FIGS. 6-8, and was preserve | saved. Makefileの一般的な記述例を示す図である。It is a figure which shows the general description example of Makefile. ビルド処理のための従来のMakefileの記述例を示す図である。It is a figure which shows the example of description of the conventional Makefile for a build process. 本発明の実施の形態に係るコンピュータのハードウェア構成を示す図である。It is a figure which shows the hardware constitutions of the computer which concerns on embodiment of this invention.

符号の説明Explanation of symbols

101…ビルド指定情報
102…ターゲット記述部
103,104…モジュール結合記述部
106〜109…モジュール構成記述部
110…ビルド対象物記述部
114,118…ビルド処理記述部
111,115…ビルド処理プログラム記述部
112,116…ビルド処理適用ルール記述部
113,117…ビルド処理パラメータ記述部
1201…CPU
1202…表示装置
1203…入力装置
1204…一次記憶装置
1205…二次記憶装置
101 ... Build designation information 102 ... Target description part 103, 104 ... Module combination description part 106-109 ... Module configuration description part 110 ... Build object description part 114, 118 ... Build process description part 111, 115 ... Build process program description part 112, 116 ... Build process application rule description part 113, 117 ... Build process parameter description part 1201 ... CPU
1202 ... Display device 1203 ... Input device 1204 ... Primary storage device 1205 ... Secondary storage device

Claims (5)

ソフトウェアにおける各モジュールを構成するソースファイルの識別情報をモジュール毎に記述する複数のモジュール構成記述部と、前記複数のモジュール構成記述部を識別する識別情報を用いて、結合すべき前記モジュールを記述するモジュール結合記述部と、各ターゲットに対して、前記モジュール構成記述部または前記ソースファイルの識別情報と関連付けてビルド処理の仕方を記述するビルド処理記述部とを参照するビルド処理方法であって、
前記ターゲット及び前記モジュール結合記述部の指定を受け付ける工程と、
指定された前記ターゲットに対応する前記ビルド処理記述部の内容を読み込む工程と、
指定された前記モジュール結合記述部で記述された結合すべき前記複数のモジュール構成記述部の内容を読み込む工程と、
読み込まれた前記ビルド処理記述部の内容及び前記複数のモジュール構成記述部の内容に基づいてビルド処理を実行する工程と
を有することを特徴とするビルド処理方法。
The module to be combined is described by using a plurality of module configuration description sections for describing identification information of source files constituting each module in the software for each module and the identification information for identifying the plurality of module configuration description sections. A build processing method that refers to a module combination description section and a build process description section that describes how to perform a build process in association with identification information of the module configuration description section or the source file for each target,
Receiving the designation of the target and the module combination description part;
Reading the contents of the build process description part corresponding to the specified target;
Reading the contents of the plurality of module configuration description parts to be combined described in the specified module combination description part;
And a step of executing a build process based on the read contents of the build process description part and the contents of the plurality of module configuration description parts.
前記ビルド処理記述部は、ビルド処理を行うプログラムの所在を示すプログラム記述部と、ビルド処理部において適用すべきルール記述部と、処理におけるパラメータを指定するパラメータ記述部とを備えることを特徴とする請求項1に記載のビルド処理方法。   The build process description part includes a program description part indicating a location of a program for performing the build process, a rule description part to be applied in the build process part, and a parameter description part for specifying a parameter in the process. The build processing method according to claim 1. 前記ビルド処理記述部は、実際のビルド処理のための入出力ファイルの識別情報の一部が、前記モジュール構成記述部の識別情報で置換されるべきダミー情報で記述されていることを特徴とする請求項1又は2に記載のビルド処理方法。   The build process description part is characterized in that a part of identification information of an input / output file for an actual build process is described by dummy information to be replaced with the identification information of the module configuration description part The build processing method according to claim 1 or 2. 請求項1〜3の何れかに記載のビルド処理方法を用いてビルド処理を行うビルド処理装置。   The build processing apparatus which performs a build process using the build processing method in any one of Claims 1-3. 請求項1〜3の何れかに記載のビルド処理方法をコンピュータに実行させるためのコンピュータ読み取り可能なプログラム。   A computer-readable program for causing a computer to execute the build processing method according to claim 1.
JP2006172638A 2006-06-22 2006-06-22 Build processing method, device and program Pending JP2008003841A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2006172638A JP2008003841A (en) 2006-06-22 2006-06-22 Build processing method, device and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2006172638A JP2008003841A (en) 2006-06-22 2006-06-22 Build processing method, device and program

Publications (1)

Publication Number Publication Date
JP2008003841A true JP2008003841A (en) 2008-01-10

Family

ID=39008168

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2006172638A Pending JP2008003841A (en) 2006-06-22 2006-06-22 Build processing method, device and program

Country Status (1)

Country Link
JP (1) JP2008003841A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010160732A (en) * 2009-01-09 2010-07-22 Nec Corp Server, software evaluation work management system, and program
JP2011510418A (en) * 2008-02-15 2011-03-31 サムスン エレクトロニクス カンパニー リミテッド Method for generating component model-based virtual software platform, method for verifying software platform architecture using the same, and apparatus therefor
JP2020013211A (en) * 2018-07-13 2020-01-23 オムロン株式会社 Program development device and controller

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011510418A (en) * 2008-02-15 2011-03-31 サムスン エレクトロニクス カンパニー リミテッド Method for generating component model-based virtual software platform, method for verifying software platform architecture using the same, and apparatus therefor
US8601433B2 (en) 2008-02-15 2013-12-03 Samsung Electronics Co., Ltd. Method and apparatus for generating virtual software platform based on component model and validating software platform architecture using the platform
KR101470319B1 (en) * 2008-02-15 2014-12-08 삼성전자주식회사 Method and apparatus for generating virtual software platform based on component model and validating software platform architecture using thereof
JP2010160732A (en) * 2009-01-09 2010-07-22 Nec Corp Server, software evaluation work management system, and program
JP2020013211A (en) * 2018-07-13 2020-01-23 オムロン株式会社 Program development device and controller

Similar Documents

Publication Publication Date Title
Meinicke et al. Mastering software variability with FeatureIDE
JP4148527B2 (en) Functional test script generator
US10782936B1 (en) Programming migration system and methods
US20080276221A1 (en) Method and apparatus for relations planning and validation
JP4978233B2 (en) Simulator development system and simulator development method
CN101937336A (en) Software asset bundling and consumption method and system
JP2008003841A (en) Build processing method, device and program
JP2008276735A (en) Program code converter and program code conversion method
CN112685040A (en) Method, device, equipment and storage medium for generating interface file in android system
CN102289367A (en) Command line shell command generation based on schema
JP2016224559A (en) Program creation support device, control method and program
JP2007226358A (en) Application generation device, application generation method, and application generation program
JP2011165051A (en) Development support device, method and program
Colombo-Mendoza et al. Alexandria: A visual tool for generating multi-device rich internet applications.
JP7208441B1 (en) FA control test support program, FA control test support device, FA control test support method and FA control test support system
Doux et al. An MDE-based approach for solving configuration problems: An application to the Eclipse platform
JP2009098963A (en) Automatic module generation system
de Sousa Saraiva et al. Development of CMS-based web-applications using a model-driven approach
JP6705993B2 (en) Information processing apparatus, information processing apparatus control method, and program
JP2018147114A (en) Test case generation method, computer, and program
JP2009104336A (en) Software deliverable management system and its method and program
Wilson et al. Engineering genomes with genotype specification language
JP5050624B2 (en) Software development support system
JP5076785B2 (en) Plant operation planning device and program thereof
JP2007200125A (en) Coding agreement selection program