Device and method for project migration among different operating platforms

An operation platform and engineering technology, applied in the direction of program control device, program control design, instrument, etc., can solve problems such as error-prone, troublesome and time-consuming, complicated makefile, etc., and achieve the effect of less error-prone, less time-consuming, and simple implementation methods

Active Publication Date: 2015-04-29
AEROSPACE INFORMATION
View PDF5 Cites 7 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] The shortcoming of the method of transplanting the project source code on the linux/unix platform to the windows platform in the above-mentioned prior art is: because the makefile itself is powerful, just like a Shell script, it can execute the order of the operating system, so most The makefiles

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Device and method for project migration among different operating platforms
  • Device and method for project migration among different operating platforms
  • Device and method for project migration among different operating platforms

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0037] This embodiment provides a processing flow of an engineering transplantation method between different operating platforms such as figure 1 As shown, the following processing steps are included:

[0038] Step S110, execute the makefile source file organization structure file of the C / C++ project under the linux / unix platform with the make integrated compilation tool, the make integrated compilation tool utilizes the gcc compilation tool to execute the above-mentioned makefile source file organization structure file, the makefile source file organization structure After the file is executed, the output result is obtained, and the output result is redirected to a text file.

[0039] make is an important program for compiling and maintaining software. It can automatically recompile and link the target code according to the modification of the program file to ensure that the target code is always composed of its latest files. Based on it, it can be automatically compiled, wh...

Embodiment 2

[0056] Method of transplanting C / C++ project under linux / unix to codeblock project under windows platform

[0057] Take OpenSSL-1.0.1e ported as codeblock project as an example:

[0058] 1) Execute the perl compilation script, call the make tool to execute the makefile to obtain the output redirection file content is excerpted as follows:

[0059]

[0060]

[0061]

[0062]

[0063] 2) Analyze the compilation result with a python script, according to "ar r out\libcrypto.a * "( * Indicates the omitted .o file name) extracts all the .o files needed to generate libcrypto.a.

[0064] 3) Analyze the compilation result with a python script, according to "gcc-o tmp\ * .o"( * Indicates the name of a .o file), and extracts the set of correspondences between all .o and .c file paths.

[0065] 4) Use the python script to analyze the obtained .c file, extract all required .h files, and find the corresponding directory path in the openssl directory.

[0066] 5) Use codebl...

Embodiment 3

[0076] This embodiment provides a kind of engineering transplantation device between different operating platforms, its specific implementation structure is as shown in Figure 3, specifically can include the following modules:

[0077] makefile execution module 310, used to execute the makefile of the C / C++ project under the linux / unix platform with the make integrated compilation tool, obtain the output result after the completion of the execution of the makefile file, and redirect the output result to a text file ;

[0078] The source file acquisition module 320 is used to analyze the text file, and execute the correspondence between the .o intermediate file and the .a target file and the .c source file to the .o intermediate file processed by the make integrated compilation tool in the process of executing the makefile. The corresponding relationship is found, and all the source files required to reconstruct the project file corresponding to the .a target file are obtained;...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention provides a device and a method for project migration among different operating platforms. The method includes: using a make integrated compilation tool for executing a makefile of a C/C++ project under a linux/unix platform, acquiring an output result after execution of the makefile is finished, and redirecting the output result as a text file; analyzing the text file, finding corresponding relation between intermediate files .o and target files .a and corresponding relation between source files .c and intermediate files .o during execution of the makefile executed by the make integrated compilation tool, and acquiring all source files need for reconstruction of project files corresponding to the target files .a; automatically reconstructing according to the source files by the aid of a script language to obtain project files corresponding to the target files .a under a windows platform. The method for project migration among the different operating platforms avoids analysis of the makefile and is low in time consumption, convenience and simple to implement and less prone to errors, and higher convenience and quickness in migration of the C/C++ project under the linux/unix platform to projects such as a codeblock project and the like under the windows platform are realized.

Description

technical field [0001] The invention relates to the technical field of computer applications, in particular to a method and device for project transplantation between different operating platforms. Background technique [0002] C / C++ projects under linux / unix are basically organized by a series of rules defined in the makefile, and the sequence of compilation is specified through the makefile. When transplanting a C / C++ project under linux / unix to the window platform, it is usually necessary to analyze the makefile, extract the organizational structure of the source file, compile order, etc., and then reorganize it into an integrated development tool under the windows platform (such as codeblock ) works. [0003] The development tools on the Windows platform are basically graphical integrated development environments, such as codeblock. In the integrated development environment under the Windows platform, all .c, .cpp, and .h files in the project are organized through a pro...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
IPC IPC(8): G06F9/45G06F9/44
Inventor 华刚陈怡博邵波
Owner AEROSPACE INFORMATION
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products