CN111061489B - Multi-platform compiling detection method, device, equipment and medium - Google Patents

Multi-platform compiling detection method, device, equipment and medium Download PDF

Info

Publication number
CN111061489B
CN111061489B CN201911379576.2A CN201911379576A CN111061489B CN 111061489 B CN111061489 B CN 111061489B CN 201911379576 A CN201911379576 A CN 201911379576A CN 111061489 B CN111061489 B CN 111061489B
Authority
CN
China
Prior art keywords
compiling
platform
file
target
project
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.)
Active
Application number
CN201911379576.2A
Other languages
Chinese (zh)
Other versions
CN111061489A (en
Inventor
夏炎
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.)
Shanghai Mihoyo Tianming Technology Co Ltd
Original Assignee
Shanghai Mihoyo Tianming Technology Co Ltd
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 Shanghai Mihoyo Tianming Technology Co Ltd filed Critical Shanghai Mihoyo Tianming Technology Co Ltd
Priority to CN201911379576.2A priority Critical patent/CN111061489B/en
Publication of CN111061489A publication Critical patent/CN111061489A/en
Application granted granted Critical
Publication of CN111061489B publication Critical patent/CN111061489B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/40Transformation of program code
    • G06F8/41Compilation
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The embodiment of the invention discloses a multi-platform compiling detection method, a device, equipment and a medium, wherein the method comprises the following steps: when a compiling detection instruction is triggered, acquiring a project file to be processed corresponding to the compiling detection instruction and a target compiling platform; a development tool set plug-in is called through a development platform to obtain a target configuration file corresponding to the target compiling platform, and the contents in the project file to be processed are compiled based on the project file to be processed and the target configuration file; and acquiring a compiling result sent by the development tool set, and sending the compiling result to a target receiving end. The multi-platform compiling and detecting method provided by the embodiment of the invention realizes the compiling and detecting of multiple platforms in a project environment and improves the compiling and detecting efficiency of the multiple platforms.

Description

Multi-platform compiling detection method, device, equipment and medium
Technical Field
The embodiment of the invention relates to the technical field of game development, in particular to a multi-platform compiling and detecting method, device, equipment and medium.
Background
In the prior art, when the code compiling condition of the unit item on different platforms needs to be checked, for example, when the code compiling condition of the unit item on platforms such as Windows, iOS, android and the like is required to be switched to a target platform in a unit editor, and then the code is compiled to check the compiling result.
However, when the editor switches platforms, all the resources are converted into the format of the current platform, and this process is very time-consuming (which can reach several hours) in the project with huge number of resources. It is basically impossible to check code compilation by switching platforms by an editor in large projects. To automatically check the compiling conditions of all the platforms, a project environment switched to each platform needs to be prepared for each platform, and then the compiling checking is performed on the project of each platform. Thus, a large disk space is required, and the efficiency of compiling codes is low, so that quick inspection cannot be achieved.
Disclosure of Invention
The embodiment of the invention provides a multi-platform compiling and detecting method, device, equipment and medium, so as to improve the efficiency of multi-platform compiling and detecting.
In a first aspect, an embodiment of the present invention provides a multi-platform compilation detection method, including:
when a compiling detection instruction is triggered, acquiring a project file to be processed corresponding to the compiling detection instruction and a target compiling platform;
a development tool set plug-in is called through a development platform to obtain a target configuration file corresponding to the target compiling platform, and the contents in the project file to be processed are compiled based on the project file to be processed and the target configuration file;
and acquiring a compiling result sent by the development tool set, and sending the compiling result to a target receiving end.
In a second aspect, an embodiment of the present invention further provides a multi-platform compiling detection device, including:
the device comprises a to-be-processed file acquisition module, a target compiling platform and a target compiling platform, wherein the to-be-processed file acquisition module is used for acquiring a to-be-processed project file corresponding to a compiling detection instruction when the compiling detection instruction is triggered;
the file compiling module is used for calling a development tool set plug-in through a development platform to obtain a target configuration file corresponding to the target compiling platform, and compiling the content in the project file to be processed based on the project file to be processed and the target configuration file;
and the compiling result processing module is used for acquiring the compiling result sent by the development tool set and sending the compiling result to a target receiving end.
In a third aspect, an embodiment of the present invention further provides a computer apparatus, the apparatus including:
one or more processors;
a storage means for storing one or more programs;
the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the multi-platform compilation detection method as provided by any embodiment of the present invention.
In a fourth aspect, embodiments of the present invention further provide a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements a multi-platform compilation detection method as provided by any of the embodiments of the present invention.
According to the embodiment of the invention, when the compiling detection instruction is triggered, a project file to be processed corresponding to the compiling detection instruction and a target compiling platform are obtained; a development tool set plug-in is called through a development platform to obtain a target configuration file corresponding to the target compiling platform, and the contents in the project file to be processed are compiled based on the project file to be processed and the target configuration file; and acquiring the compiling result sent by the development tool set, and sending the compiling result to a target receiving end, so that the efficiency of multi-platform compiling detection is improved.
Drawings
FIG. 1 is a flowchart of a multi-platform compilation detection method according to an embodiment of the present invention;
FIG. 2a is a flowchart of a multi-platform compilation detection method according to a second embodiment of the present invention;
FIG. 2b is a block diagram of a multi-platform rapid compilation inspection tool according to a second embodiment of the present invention;
fig. 3 is a schematic structural diagram of a multi-platform compiling detection device according to a third embodiment of the present invention;
fig. 4 is a schematic structural diagram of a computer device according to a fourth embodiment of the present invention.
Detailed Description
The invention is described in further detail below with reference to the drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the invention and are not limiting thereof. It should be further noted that, for convenience of description, only some, but not all of the structures related to the present invention are shown in the drawings.
Example 1
Fig. 1 is a flowchart of a multi-platform compilation detection method according to an embodiment of the present invention. The embodiment is applicable to the case when the compiling results of a plurality of platforms are detected. The method may be performed by a multi-platform compilation detection apparatus that may be implemented in software and/or hardware, e.g., that may be configured in a computer device. As shown in fig. 1, the method includes:
and S110, when the compiling detection instruction is triggered, acquiring a to-be-processed project file corresponding to the compiling detection instruction and a target compiling platform.
In this embodiment, the compilation detection instruction is triggered by the user clicking on the user interface of the compilation detection-end. The target compiling platform may be a working platform that needs to be compiled. Optionally, the target compiling platform may be a platform such as Windows, iOS, android, etc. Specifically, when the compiling detection instruction is triggered, the target compiling platforms contained in the detected compiling detection instruction are obtained, wherein the number of the target compiling platforms can be 1 or more.
The multi-platform compiling detection device detects the compiling detection instruction triggered by the user, and obtains a target compiling platform contained in the compiling detection instruction and a project file to be processed corresponding to the compiling detection instruction. The project file to be processed can be obtained from a version control platform. Optionally, the multi-platform compiling and detecting device may actively acquire the to-be-processed project file from the version control platform, and may also receive the to-be-processed project file issued by the version control platform, which is not limited herein.
S120, a development tool set plug-in is called through a development platform to obtain a target configuration file corresponding to the target compiling platform, and compiling contents in the project file to be processed is conducted based on the project file to be processed and the target configuration file.
In this embodiment, the configuration file is a pre-established configuration file corresponding to a different compiling platform. The target configuration file is a configuration file corresponding to the target compiling platform. Illustratively, assuming that the target compilation platform is an android platform, the target configuration file is a configuration file corresponding to the android platform.
Specifically, the multi-platform compiling detection device calls the development platform to enable the development platform to call the development tool set plug-in to obtain a target configuration file corresponding to the target compiling platform, modifies the project file to be processed based on the target configuration file to obtain the project file to be compiled corresponding to the target compiling platform, and compiles the project file to be compiled by calling the compiling tool. In one embodiment, the development platform is a Unity development platform and the development tool set plugin is a Visual Studio (VS) plugin. The multi-platform compiling detection device can be configured in a Jenkins automation task platform. That is, the Jenkins automation task platform calls the Visual Studio plug-in through the Unity development platform to obtain a target configuration file corresponding to the target compiling platform, modifies the project file to be processed in the Visual Studio based on the target configuration file to obtain the project file to be compiled corresponding to the target compiling platform, and then compiles the project file to be compiled by calling the VS compiling tool. The method comprises the steps that a Visual Studio plug-in is called to obtain a target configuration file corresponding to a target compiling platform, and the target configuration file can be achieved through an expansion interface of the Visual Studio plug-in. Illustratively, a program for acquiring the project configuration file is pre-written, and the program for acquiring the project configuration file is called through an expansion interface of the Visual Studio plug-in to acquire a target configuration file corresponding to a target compiling platform. In addition, when the target compiling platforms are multiple, the VS compiling tools can be run in parallel, and codes of the target compiling platforms can be compiled simultaneously.
In one embodiment of the present invention, the acquiring, by the development platform calling the development tool set plug-in, the target configuration file corresponding to the target compiling platform includes: and calling a development tool set plug-in through the development platform, and acquiring a target configuration file corresponding to the target compiling platform from a pre-stored configuration file according to the compiling platform identification of the target compiling platform. Specifically, the development platform can call an expansion interface of the development tool set plug-in, and a target configuration file corresponding to the target compilation platform is obtained from a configuration file table which is stored with the corresponding relation between the identification of the compilation platform and the configuration file in advance. Optionally, the compiling platform identifier of the target compiling platform may be matched with the compiling platform identifier in the pre-stored configuration file table, and the configuration file corresponding to the compiling platform identifier matched with the compiling platform identifier of the target compiling platform in the pre-stored configuration file table is used as the target configuration file.
Optionally, before the development tool set plug-in is invoked by the development platform to obtain the target configuration file corresponding to the target compiling platform, the method further includes: and generating configuration files corresponding to the compiling platforms according to compiling rules of the compiling platforms, and storing compiling platform identifiers corresponding to the configuration files. In this embodiment, before multi-platform compilation detection, a configuration file corresponding to each compilation platform is generated according to the compilation rule of each compilation platform, and the compilation platform identifier and the configuration file are stored correspondingly, so that in the subsequent multi-platform compilation detection process, multi-platform quick compilation is performed according to the pre-stored configuration file. The configuration files can comprise platform configuration files, compiling configuration files, reference relations among macros and the like.
In one embodiment of the present invention, compiling the content in the to-be-processed project file based on the to-be-processed project file and the target configuration file includes: calling an editor script in a development platform to analyze the project file to be processed to obtain an initial project file; the development tool set plug-in is called through a development platform to modify the initial project file according to the target configuration file, so that a project file to be compiled is obtained; and calling a compiling tool in the development tool set plug-in through the development platform to compile the project file to be compiled.
Taking a development platform as a Unity development platform as an example, the Jenkins automation task platform analyzes the project file to be processed through a Unity editor script in the Unity development platform to obtain an initial VS project file, then invokes a Visual Studio plug-in (VSTU) of Unity to modify the initial project file according to a target configuration file to obtain a file to be compiled, which can be directly compiled on a target compiling platform, and invokes a VS compiling tool to compile the project file to be compiled.
On the basis of the scheme, the initial project file comprises a solution original file and a project original file, the target configuration file comprises a platform configuration file and a compiling configuration file, the initial project file is modified according to the target configuration file by calling a development tool set plug-in through a development platform to obtain a project file to be compiled, and the method comprises the following steps: calling a development tool set plug-in through a development platform, and adding the platform configuration file into the original solution file to obtain a target solution file; calling a development tool set plug-in through a development platform, and adding the compiling configuration file into the project original file to obtain a target project file; and generating the project file to be compiled based on the target solution file and the target project file.
Specifically, the Jenkins automation task platform analyzes the project file to be processed by calling the Unity VSTU to obtain a solution original file and a project original file, then the VSTU plug-in unit calls an expansion interface to respectively modify the solution original file and the project original file, and the target solution file and the target project file obtained after modification are used as the project file to be compiled together. Optionally, the VSTU plugin invokes the extension interface to modify the solution original file may be: the VSTU plug-in calls an extension interface to read and analyze the project file to be processed, extracts all project information contained in the project file to be processed, then adds a platform configuration file in all projects, and stores the modified solution as a target solution file. The VSTU plugin invokes the extension interface to modify the project original file may be: the VSTU plug-in calls an extension interface to read and analyze the project file to be processed, then adds a compiling configuration file, determines whether all the referencing relationships are available according to the pre-configured referencing relationships and the compiling configuration, deletes the unavailable referencing relationships, and then saves the modified project file as a target project file.
S130, acquiring a compiling result sent by the development tool set, and sending the compiling result to a target receiving end.
In this embodiment, after the VS compiling tool compiles the project file to be compiled, a corresponding compiling result is generated, and the multi-platform compiling detection device receives the compiling result returned by the VS compiling tool and displays the compiling result. Optionally, the compiling result display end may be preset as the target receiving end, and the compiling result is performed based on the preset compiling result display end, so that the compiling result is displayed on the compiling result display end. The user can determine whether the code corresponding to the target compiling platform is compiled normally or not according to the previous compiling result.
According to the embodiment of the invention, when the compiling detection instruction is triggered, a project file to be processed corresponding to the compiling detection instruction and a target compiling platform are obtained; a development tool set plug-in is called through a development platform to obtain a target configuration file corresponding to the target compiling platform, and the contents in the project file to be processed are compiled based on the project file to be processed and the target configuration file; and acquiring the compiling result sent by the development tool set, and sending the compiling result to a target receiving end, so that the efficiency of multi-platform compiling detection is improved.
Example two
Fig. 2a is a flowchart of a multi-platform compiling detection method according to a second embodiment of the invention. This embodiment provides a preferred embodiment on the basis of the above-described embodiments.
In this embodiment, the multi-platform compiling method may be implemented based on a multi-platform rapid compiling inspection tool. Fig. 2b is a block diagram of a multi-platform rapid compiling inspection tool according to a second embodiment of the present invention. As shown in FIG. 2b, the multi-platform rapid compilation inspection tool includes a Jenkins automation task platform, a Unity development platform, and Visual Studio plug-ins. Specifically, the Jenkins automation task platform runs an automated compiling checking script to execute an automated compiling detection flow.
The automatic compiling detection flow may be: updating a project file, executing a Unity editor script, generating a VS project file, calling a VSTU plug-in to call an extension interface of the VSTU to modify the VS project file, adding compiling configuration of each platform to generate a modified VS project file, compiling a VS project code by using a VS compiling tool to obtain a compiling result, and sending the compiling result to an enterprise WeChat through an enterprise WeChat sending module.
As shown in fig. 2a, the method flow is as follows: starting automated compiling inspection; executing an automation platform script; updating the project file; executing a Unity editor script to generate a VS project file (i.e., a project file to be processed); calling a VSTU plug-in to generate a VS project file (namely an initial project file); the VSTU plug-in analyzes the initial project file, generates a VS solution file (namely a solution original file) and a VS project file (namely a project original file), modifies the VS solution file and the VS project file respectively to obtain a modified solution file and a modified project file, and stores the modified solution file and the modified project file, so that the VS project file is generated completely to obtain the project file to be compiled. And then opening project files to be compiled through VS, selecting a platform (namely a target compiling platform) to be compiled, compiling codes to be compiled in VS to obtain compiling results for users to check, running VS compiling tools in parallel when the number of target compiling platforms is multiple, compiling codes of all compiling platforms simultaneously, outputting compiling results, and sending the compiling results to enterprise WeChat to complete automatic compiling inspection.
Wherein, modifying the VS solution file may be: the VSTU plug-in calls an extension interface to read and analyze the VS solution file, extracts all item information contained in the VS solution file, adds a platform configuration file of each target compiling platform in all item information, and obtains a modified solution file. The modification of the VS project file may be: the VSTU plug-in calls an extension interface to read and analyze the VS project file, adds the compiling configuration file of each target compiling platform, judges whether the references are available according to the references configured by each platform, deletes the unavailable references to obtain the modified project file.
According to the embodiment of the invention, the Jenkins automation task platform is utilized to automatically update the Unity project file, the VS project file is generated, the VS compiling code is called, the result is output and sent to the enterprise WeChat, and the automatic detection of multi-platform compiling is realized. In addition, the extension interface of the Visual Studio (VS) plug-in of Unity is utilized to realize the custom processing of the VS project file generated by Unity, and the compiling configuration of various platforms is added in the VS project file, so that the platform compiling code can be quickly switched in the Visual Studio without switching the platforms in the Unity editor, so that the compiling detection of multiple platforms can be realized by only preparing one project environment, the disk cost for preparing one project environment for each platform is avoided, the disk space is saved, and the compiling code is more efficient than that of the Unity editor by using the VS.
Example III
Fig. 3 is a schematic structural diagram of a multi-platform compiling and detecting device according to a third embodiment of the present invention. The multi-platform compilation detection apparatus may be implemented in software and/or hardware, for example, the multi-platform compilation detection apparatus may be configured in a computer device. As shown in fig. 3, the apparatus includes a pending file acquisition module 310, a file compiling module 320, and a compiling result processing module 330, where:
a to-be-processed file obtaining module 310, configured to obtain, when a compilation detection instruction is triggered, a to-be-processed project file corresponding to the compilation detection instruction and a target compilation platform;
the file compiling module 320 is configured to call a development tool set plug-in through a development platform to obtain a target configuration file corresponding to the target compiling platform, and compile contents in the to-be-processed project file based on the to-be-processed project file and the target configuration file;
and the compiling result processing module 330 is configured to obtain a compiling result sent by the development tool set, and send the compiling result to a target receiving end.
According to the embodiment of the invention, when a compiling detection instruction is triggered, a to-be-processed project file and a target compiling platform corresponding to the compiling detection instruction are acquired through a to-be-processed file acquisition module; the file compiling module invokes a development tool set plug-in through a development platform to acquire a target configuration file corresponding to the target compiling platform, and compiles the content in the project file to be processed based on the project file to be processed and the target configuration file; the compiling result processing module obtains the compiling result sent by the development tool set and sends the compiling result to the target receiving end, so that the efficiency of multi-platform compiling detection is improved.
Optionally, based on the above scheme, the file compiling module 320 is specifically configured to:
calling an editor script in a development platform to analyze the project file to be processed to obtain an initial project file;
the development tool set plug-in is called through a development platform to modify the initial project file according to the target configuration file, so that a project file to be compiled is obtained;
and calling a compiling tool in the development tool set plug-in through the development platform to compile the project file to be compiled.
Optionally, on the basis of the above solution, the initial project file includes a solution original file and a project original file, the target configuration file includes a platform configuration file and a compiling configuration file, and the file compiling module 320 is specifically configured to:
calling a development tool set plug-in through a development platform, and adding the platform configuration file into the original solution file to obtain a target solution file;
calling a development tool set plug-in through a development platform, and adding the compiling configuration file into the project original file to obtain a target project file;
and generating the project file to be compiled based on the target solution file and the target project file.
Optionally, based on the above scheme, the file compiling module 320 is specifically configured to:
and calling a development tool set plug-in through the development platform, and acquiring a target configuration file corresponding to the target compiling platform from a pre-stored configuration file according to the compiling platform identification of the target compiling platform.
Optionally, on the basis of the above scheme, the device further includes a configuration file storage module, configured to:
before a development tool set plug-in is called by a development platform to acquire a target configuration file corresponding to the target compiling platform, generating configuration files corresponding to the compiling platforms according to compiling rules of the compiling platforms, and storing compiling platform identifiers corresponding to the configuration files.
Optionally, on the basis of the above scheme, the development platform is a Unity development platform.
Optionally, based on the above scheme, the development tool set plugin is a Visual Studio plugin.
The multi-platform compiling and detecting device provided by the embodiment of the invention can execute the multi-platform compiling and detecting method provided by any embodiment, and has the corresponding functional modules and beneficial effects of the executing method.
Example IV
Fig. 4 is a schematic structural diagram of a computer device according to a fourth embodiment of the present invention. Fig. 4 illustrates a block diagram of an exemplary computer device 412 suitable for use in implementing embodiments of the invention. The computer device 412 shown in fig. 4 is only an example and should not be construed as limiting the functionality and scope of use of embodiments of the invention.
As shown in FIG. 4, computer device 412 is in the form of a general purpose computing device. Components of computer device 412 may include, but are not limited to: one or more processors 416, a system memory 428, and a bus 418 that connects the various system components (including the system memory 428 and the processors 416).
Bus 418 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, a processor 416, or a local bus using any of a variety of bus architectures. By way of example, and not limitation, such architectures include Industry Standard Architecture (ISA) bus, micro channel architecture (MAC) bus, enhanced ISA bus, video Electronics Standards Association (VESA) local bus, and Peripheral Component Interconnect (PCI) bus.
Computer device 412 typically includes a variety of computer system readable media. Such media can be any available media that is accessible by computer device 412 and includes both volatile and nonvolatile media, removable and non-removable media.
The system memory 428 may include computer system readable media in the form of volatile memory, such as Random Access Memory (RAM) 430 and/or cache memory 432. The computer device 412 may further include other removable/non-removable, volatile/nonvolatile computer system storage media. By way of example only, storage 434 may be used to read from or write to non-removable, non-volatile magnetic media (not shown in FIG. 4, commonly referred to as a "hard disk drive"). Although not shown in fig. 4, a magnetic disk drive for reading from and writing to a removable non-volatile magnetic disk (e.g., a "floppy disk"), and an optical disk drive for reading from or writing to a removable non-volatile optical disk (e.g., a CD-ROM, DVD-ROM, or other optical media) may be provided. In such cases, each drive may be coupled to bus 418 via one or more data medium interfaces. Memory 428 may include at least one program product having a set (e.g., at least one) of program modules configured to carry out the functions of embodiments of the invention.
A program/utility 440 having a set (at least one) of program modules 442 may be stored in, for example, memory 428, such program modules 442 including, but not limited to, an operating system, one or more application programs, other program modules, and program data, each or some combination of which may include an implementation of a network environment. Program modules 442 generally perform the functions and/or methodologies in the described embodiments of the invention.
The computer device 412 may also communicate with one or more external devices 414 (e.g., keyboard, pointing device, display 424, etc.), one or more devices that enable a user to interact with the computer device 412, and/or any devices (e.g., network card, modem, etc.) that enable the computer device 412 to communicate with one or more other computing devices. Such communication may occur through an input/output (I/O) interface 422. Moreover, computer device 412 may also communicate with one or more networks such as a Local Area Network (LAN), a Wide Area Network (WAN) and/or a public network, such as the Internet, through network adapter 420. As shown, network adapter 420 communicates with other modules of computer device 412 over bus 418. It should be appreciated that although not shown, other hardware and/or software modules may be used in connection with computer device 412, including, but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, data backup storage systems, and the like.
The processor 416 executes various functional applications and data processing by running programs stored in the system memory 428, for example, implementing a multi-platform compilation detection method provided by embodiments of the present invention, including:
when a compiling detection instruction is triggered, acquiring a project file to be processed corresponding to the compiling detection instruction and a target compiling platform;
a development tool set plug-in is called through a development platform to obtain a target configuration file corresponding to the target compiling platform, and the contents in the project file to be processed are compiled based on the project file to be processed and the target configuration file;
and acquiring a compiling result sent by the development tool set, and sending the compiling result to a target receiving end.
Of course, those skilled in the art will understand that the processor may also implement the technical solution of the multi-platform compilation detection method provided by any embodiment of the present invention.
Example five
The fifth embodiment of the present invention further provides a computer readable storage medium having a computer program stored thereon, where the program when executed by a processor implements the multi-platform compilation detection method provided by the embodiment of the present invention, the method including:
when a compiling detection instruction is triggered, acquiring a project file to be processed corresponding to the compiling detection instruction and a target compiling platform;
a development tool set plug-in is called through a development platform to obtain a target configuration file corresponding to the target compiling platform, and the contents in the project file to be processed are compiled based on the project file to be processed and the target configuration file;
and acquiring a compiling result sent by the development tool set, and sending the compiling result to a target receiving end.
Of course, the computer readable storage medium provided by the embodiments of the present invention, on which the computer program stored, is not limited to the method operations described above, but may also perform the related operations in the multi-platform compilation detection method provided by any embodiment of the present invention.
The computer storage media of embodiments of the invention may take the form of any combination of one or more computer-readable media. The computer readable medium may be a computer readable signal medium or a computer readable storage medium. The computer readable storage medium can be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples (a non-exhaustive list) of the computer-readable storage medium would include the following: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In this document, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
The computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, either in baseband or as part of a carrier wave. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination of the foregoing. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Computer program code for carrying out operations of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, smalltalk, C ++ and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computer (for example, through the Internet using an Internet service provider).
Note that the above is only a preferred embodiment of the present invention and the technical principle applied. It will be understood by those skilled in the art that the present invention is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the invention. Therefore, while the invention has been described in connection with the above embodiments, the invention is not limited to the embodiments, but may be embodied in many other equivalent forms without departing from the spirit or scope of the invention, which is set forth in the following claims.

Claims (7)

1. The multi-platform compiling detection method is characterized by comprising the following steps of:
when a compiling detection instruction is triggered, acquiring a project file to be processed corresponding to the compiling detection instruction and a target compiling platform;
a development tool set plug-in is called through a development platform to obtain a target configuration file corresponding to the target compiling platform, and the contents in the project file to be processed are compiled based on the project file to be processed and the target configuration file;
acquiring a compiling result sent by the development tool set, and sending the compiling result to a target receiving end;
the step of obtaining the target configuration file corresponding to the target compiling platform by calling a development tool set plug-in through the development platform comprises the following steps:
a development tool set plug-in is called through the development platform, and a target configuration file corresponding to the target compiling platform is obtained from the pre-stored configuration files according to the compiling platform identification of the target compiling platform;
the compiling the content in the to-be-processed project file based on the to-be-processed project file and the target configuration file comprises the following steps:
calling an editor script in a development platform to analyze the project file to be processed to obtain an initial project file;
the development tool set plug-in is called through a development platform to modify the initial project file according to the target configuration file, so that a project file to be compiled is obtained;
the compiling tool in the development tool set plug-in is called through the development platform to compile the project file to be compiled;
the initial project file comprises a solution original file and a project original file, the target configuration file comprises a platform configuration file and a compiling configuration file, the initial project file is modified according to the target configuration file by calling a development tool set plug-in through a development platform to obtain a project file to be compiled, and the method comprises the following steps:
calling a development tool set plug-in through a development platform, and adding the platform configuration file into the original solution file to obtain a target solution file;
calling a development tool set plug-in through a development platform, and adding the compiling configuration file into the project original file to obtain a target project file;
and generating the project file to be compiled based on the target solution file and the target project file.
2. The method of claim 1, further comprising, prior to invoking a development tool set plug-in via a development platform to obtain a target configuration file corresponding to the target compilation platform:
and generating configuration files corresponding to the compiling platforms according to compiling rules of the compiling platforms, and storing compiling platform identifiers corresponding to the configuration files.
3. The method of any one of claims 1-2, wherein the development platform is a Unity development platform.
4. The method of any one of claims 1-2, wherein the development tool set plugin is a Visual Studio plugin.
5. A multi-platform compilation detection device, comprising:
the device comprises a to-be-processed file acquisition module, a target compiling platform and a target compiling platform, wherein the to-be-processed file acquisition module is used for acquiring a to-be-processed project file corresponding to a compiling detection instruction when the compiling detection instruction is triggered;
the file compiling module is used for calling a development tool set plug-in through a development platform to obtain a target configuration file corresponding to the target compiling platform, and compiling the content in the project file to be processed based on the project file to be processed and the target configuration file;
the compiling result processing module is used for acquiring the compiling result sent by the development tool set and sending the compiling result to a target receiving end;
the file compiling module is specifically used for:
a development tool set plug-in is called through the development platform, and a target configuration file corresponding to the target compiling platform is obtained from the pre-stored configuration files according to the compiling platform identification of the target compiling platform;
calling an editor script in a development platform to analyze the project file to be processed to obtain an initial project file;
the development tool set plug-in is called through a development platform to modify the initial project file according to the target configuration file, so that a project file to be compiled is obtained;
the compiling tool in the development tool set plug-in is called through the development platform to compile the project file to be compiled;
the initial project file comprises a solution original file and a project original file, the target configuration file comprises a platform configuration file and a compiling configuration file, and the file compiling module is specifically used for:
calling a development tool set plug-in through a development platform, and adding the platform configuration file into the original solution file to obtain a target solution file;
calling a development tool set plug-in through a development platform, and adding the compiling configuration file into the project original file to obtain a target project file;
and generating the project file to be compiled based on the target solution file and the target project file.
6. A computer device, the device comprising:
one or more processors;
a storage means for storing one or more programs;
the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the multi-platform compilation detection method of any of claims 1-4.
7. A computer readable storage medium having stored thereon a computer program, which when executed by a processor implements a multi-platform compilation detection method according to any of claims 1-4.
CN201911379576.2A 2019-12-27 2019-12-27 Multi-platform compiling detection method, device, equipment and medium Active CN111061489B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911379576.2A CN111061489B (en) 2019-12-27 2019-12-27 Multi-platform compiling detection method, device, equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911379576.2A CN111061489B (en) 2019-12-27 2019-12-27 Multi-platform compiling detection method, device, equipment and medium

Publications (2)

Publication Number Publication Date
CN111061489A CN111061489A (en) 2020-04-24
CN111061489B true CN111061489B (en) 2023-06-27

Family

ID=70304289

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911379576.2A Active CN111061489B (en) 2019-12-27 2019-12-27 Multi-platform compiling detection method, device, equipment and medium

Country Status (1)

Country Link
CN (1) CN111061489B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111552480B (en) * 2020-05-07 2021-06-25 深圳百斯特控制技术有限公司 Cross-platform compiling method, device, equipment and readable storage medium
CN111913694A (en) * 2020-08-04 2020-11-10 深圳大趋智能科技有限公司 Method and system for compiling automatic identification platform
CN113434146A (en) * 2021-06-22 2021-09-24 青岛海尔科技有限公司 Code compiling method, device, storage medium and electronic device
CN116382775A (en) * 2023-03-15 2023-07-04 中电金信软件有限公司 Hbuilderx plug-in based multi-platform program package generation method

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101697135A (en) * 2009-10-28 2010-04-21 北京东方网力科技有限公司 Method and device for compiling program
CN107122219A (en) * 2017-03-31 2017-09-01 腾讯科技(深圳)有限公司 The acquisition methods and device of installation file
CN109582316A (en) * 2018-11-15 2019-04-05 北京深思数盾科技股份有限公司 A kind of cross-platform Compilation Method, device, system, server and storage medium
CN109814853A (en) * 2019-01-18 2019-05-28 宜创(北京)科技有限公司 Based on visual multi-platform data creation method, device, equipment and medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101697135A (en) * 2009-10-28 2010-04-21 北京东方网力科技有限公司 Method and device for compiling program
CN107122219A (en) * 2017-03-31 2017-09-01 腾讯科技(深圳)有限公司 The acquisition methods and device of installation file
CN109582316A (en) * 2018-11-15 2019-04-05 北京深思数盾科技股份有限公司 A kind of cross-platform Compilation Method, device, system, server and storage medium
CN109814853A (en) * 2019-01-18 2019-05-28 宜创(北京)科技有限公司 Based on visual multi-platform data creation method, device, equipment and medium

Also Published As

Publication number Publication date
CN111061489A (en) 2020-04-24

Similar Documents

Publication Publication Date Title
CN111061489B (en) Multi-platform compiling detection method, device, equipment and medium
CN111740948B (en) Data packet issuing method, dynamic updating method, device, equipment and medium
CN110727581B (en) Crash positioning method and electronic equipment
CN111176629A (en) Application development method and device
CN113051514B (en) Element positioning method and device, electronic equipment and storage medium
CN111399840A (en) Module development method and device
CN110659210A (en) Information acquisition method and device, electronic equipment and storage medium
CN112463256A (en) Method, system, electronic device and storage medium for determining configuration file
CN110688096A (en) Method, device, medium and electronic equipment for constructing application program containing plug-in
CN113127050A (en) Application resource packaging process monitoring method, device, equipment and medium
CN113050984A (en) Resource calling method and device, electronic equipment and storage medium
CN114003269A (en) Component processing method and device, electronic equipment and storage medium
CN113138768B (en) Application package generation method and device, electronic equipment and readable storage medium
CN111190791A (en) Application exception reporting method and device and electronic equipment
CN110688305B (en) Test environment synchronization method, device, medium and electronic equipment
CN111124423B (en) Compiling detection method, device, server and medium based on multiple platforms
CN113434217B (en) Vulnerability scanning method, vulnerability scanning device, computer equipment and medium
CN113986263A (en) Code automation test method, device, electronic equipment and storage medium
CN109669871B (en) Method for realizing Oracle Form automatic test
CN112114811A (en) Compiling method, device and equipment
CN111400396A (en) Method and device for generating data synchronization script and computer readable storage medium
CN111176718A (en) Script online method and device, storage medium and electronic equipment
CN111488286A (en) Method and device for independently developing Android module
CN111930478A (en) Service calling method and device based on dynamic bytecode
CN110780864A (en) Control method and device for class method replacement, storage medium and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant