CN111026439B - Application program compatibility method, device, equipment and computer storage medium - Google Patents

Application program compatibility method, device, equipment and computer storage medium Download PDF

Info

Publication number
CN111026439B
CN111026439B CN201911158733.7A CN201911158733A CN111026439B CN 111026439 B CN111026439 B CN 111026439B CN 201911158733 A CN201911158733 A CN 201911158733A CN 111026439 B CN111026439 B CN 111026439B
Authority
CN
China
Prior art keywords
file
source code
application program
code engineering
library file
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
CN201911158733.7A
Other languages
Chinese (zh)
Other versions
CN111026439A (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.)
Guangzhou Cubesili Information Technology Co Ltd
Original Assignee
Guangzhou Cubesili Information 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 Guangzhou Cubesili Information Technology Co Ltd filed Critical Guangzhou Cubesili Information Technology Co Ltd
Priority to CN201911158733.7A priority Critical patent/CN111026439B/en
Publication of CN111026439A publication Critical patent/CN111026439A/en
Application granted granted Critical
Publication of CN111026439B publication Critical patent/CN111026439B/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/70Software maintenance or management
    • G06F8/76Adapting program code to run in a different environment; Porting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/61Installation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44521Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading

Abstract

The application discloses a method, a device and equipment for application program compatibility and a computer storage medium, and belongs to the technical field of application programs. The method comprises the following steps: acquiring a source code engineering file corresponding to the mobile operating system and configuring a development environment; changing a first dynamic link library file in the source code engineering file into an annotation; placing a second dynamic link library file into a directory corresponding to the architecture of the processor in the source code engineering file to obtain an updated source code engineering file, wherein the version of the second dynamic link library file is higher than that of the first dynamic link library file; running and updating the source code engineering file to obtain a library file; placing the library file into a native project of a specified application program; and running the primary project of the specified application program to obtain the installation package of the application program. The method and the device solve the problem of poor compatibility of the application program in the related technology, and achieve the effect of improving the compatibility of the application program.

Description

Application program compatibility method, device, equipment and computer storage medium
Technical Field
The present application relates to the field of application program technologies, and in particular, to a method, an apparatus, a device, and a computer storage medium for application program compatibility.
Background
An application program of a mobile terminal operating system (such as an android system or an apple system) can be used in a simulator of a personal computer (pc), but when the application program runs in the simulator of the pc, a crash caused by a compatibility problem may occur.
In a compatible method for an application program in the related art, a new source code engineering file is first obtained from an open source library, and then an installation package of the application program is generated through the new source code engineering file, so as to improve the compatibility of the application program.
However, the source code engineering files are generally updated slowly, and the source code engineering files obtained from the open source library may still be older versions, which may result in poor compatibility of the application program.
Disclosure of Invention
The embodiment of the application provides a method, a device and equipment for application program compatibility and a computer storage medium, and can solve the problem of poor compatibility of application programs in the related technology. The technical scheme is as follows:
according to a first aspect of the present application, there is provided an application compatibility method, including:
acquiring a source code engineering file corresponding to a mobile operating system;
configuring a development environment according to the source code engineering file;
changing a first dynamic link library file in the source code engineering file into an annotation;
acquiring a second dynamic link library file, and putting the second dynamic link library file into a directory corresponding to a framework of a processor in the source code engineering file to obtain an updated source code engineering file, wherein the processor comprises a processor of the desktop operating system and a processor of the mobile operating system, and the version of the second dynamic link library file is higher than that of the first dynamic link library file;
running the updated source code engineering file to obtain a library file;
putting the library file into a native project of a specified application program;
and running the native project of the specified application program to obtain the installation package of the application program.
Optionally, before the running the native project of the specified application and obtaining the installation package of the application, the method further includes:
creating a notification module in a native project of the specified application;
after the running of the native project of the specified application program and obtaining the installation package of the application program, the method further includes:
and running the application program in a simulator of the mobile operating system according to the installation package, wherein the notification module is used for transmitting data when the application program runs.
Optionally, the installation package includes a cross-platform running module and a local event transmitter, and the running the application program in the simulator of the mobile operating system according to the installation package includes:
the cross-platform operation module controls the notification module to package and send data;
receiving and unpacking data through the notification module;
when the notification module receives the data, sending the unpacked data to the cross-platform operation module through a local event transmitter;
performing judgment processing on the unpacked data through the cross-platform operation module;
and sending the unpacked data subjected to the judgment processing to a service layer for data rendering.
Optionally, the performing, by the cross-platform running module, a judgment process on the unpacked data includes:
judging whether each field in the unpacked data exists and is assigned;
and if any field in the unpacked data does not exist or is not assigned with a value, assigning a specified value to the any field.
Optionally, the configuring the development environment according to the source code engineering file includes:
and configuring the development environment according to the source code engineering file and the native development toolkit of the cross-platform mobile application development framework.
Optionally, before the running of the native project of the specified application program obtains the installation package of the application program, the method further includes:
and modifying the name of the library file according to the version number of the source code engineering file.
In another aspect, an apparatus for application compatibility is provided, the apparatus including:
the first acquisition module is used for acquiring a source code project file corresponding to the mobile operating system;
the configuration module is used for configuring a development environment according to the source code engineering file;
the changing module is used for changing a first dynamic link library file in the source code engineering file into an annotation;
a second obtaining module, configured to obtain a second dynamic link library file, and place the second dynamic link library file in a directory corresponding to a framework of a processor in the source code engineering file to obtain an updated source code engineering file, where the processor includes a processor of the desktop operating system and a processor of the mobile operating system, and a version of the second dynamic link library file is higher than a version of the first dynamic link library file;
the first operation module is used for operating the updated source code engineering file to obtain a library file;
the setting module is used for placing the library file into a native project of a specified application program;
and the second running module is used for running the native project of the specified application program to obtain the installation package of the application program.
Optionally, the apparatus further comprises:
and the notification module is used for transmitting data when the application program runs.
In a further aspect, there is provided an application compatible device, comprising a processor and a memory, wherein the memory stores at least one instruction, at least one program, a set of codes, or a set of instructions, and the at least one instruction, the at least one program, the set of codes, or the set of instructions is loaded and executed by the processor to implement the application compatible method according to the first aspect.
In a further aspect, there is provided a computer storage medium having stored therein at least one instruction, at least one program, set of codes, or set of instructions that is loaded and executed by a processor to implement a compatible method of an application program as described in the first aspect.
The beneficial effects that technical scheme that this application embodiment brought include at least:
the method comprises the steps of changing a first dynamic link library file in a source code engineering file corresponding to a mobile operating system into a comment, placing a second dynamic link library file with a version higher than that of the first dynamic link library file into a directory corresponding to a framework of a processor in the source code engineering file to obtain an updated source code engineering file, operating the updated source code engineering file to obtain a library file, placing the library file into a native project of a specified application program, operating the native project of the specified application program to obtain an installation package of the application program, so that the compatibility between the application program and a pc-end simulator is improved by using the dynamic link library file with the higher version, and the breakdown caused by the compatibility problem between the application program and the simulator is repaired. The problem of relatively poor compatibility of the application program in the related technology is solved, and the effect of improving the compatibility of the application program is achieved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
FIG. 1 is a schematic diagram of an implementation environment of a method for application compatibility according to an embodiment of the present application;
FIG. 2 is a flowchart of a method for application compatibility according to an embodiment of the present disclosure;
FIG. 3 is a flow chart of another application program compatibility method provided by an embodiment of the present application;
FIG. 4 is a display page of an application program on a terminal after a service layer renders unpacked data;
FIG. 5 is a flow chart of running an application in a simulator of a mobile operating system;
fig. 6 is a block diagram of a compatible device of an application according to an embodiment of the present application;
FIG. 7 is a block diagram of another application compatible device provided by an embodiment of the present application;
fig. 8 is a schematic structural diagram of a compatible device for an application according to an embodiment of the present application.
With the above figures, there are shown specific embodiments of the present application, which will be described in more detail below. These drawings and written description are not intended to limit the scope of the inventive concepts in any manner, but rather to illustrate the inventive concepts to those skilled in the art by reference to specific embodiments.
Detailed Description
To make the objects, technical solutions and advantages of the present application more clear, embodiments of the present application will be described in further detail below with reference to the accompanying drawings.
In a current method for compatible application programs, a new source code engineering file in an application program is obtained from an open source library to optimize the application program, and then an installation package of the application program is generated through the new source code engineering file, so as to improve the compatibility of the application program. .
However, the source code engineering files are generally updated slowly, and the source code engineering files obtained from the open source library may still be older versions, which may result in poor compatibility of the application program.
The embodiment of the application provides a method, a device and equipment for application program compatibility and a computer storage medium.
Fig. 1 is a schematic diagram of an implementation environment of a method for application compatibility according to an embodiment of the present application, where the implementation environment may include a server 11 and a terminal 12.
The server 11 may be a server or a cluster of servers.
The terminal 12 may be a desktop computer, a notebook computer, a mobile phone, a tablet computer, a smart wearable device, or other various terminals capable of running a desktop operating system. The terminal 12 may be connected to the server by wire or wirelessly (in the case of wireless connection shown in fig. 1).
The desktop operating system may be software that runs on a computer by means of hardware and performs computation (application), and may include, for example, an apple operating system (mac os), a windows operating system (windows), a linnas operating system (linux), and the like.
Fig. 2 is a flowchart of a method for application compatibility according to an embodiment of the present application. The application program compatible method can be applied to the terminal of the implementation environment. The application program compatibility method can comprise the following steps:
step 201, acquiring a source code project file corresponding to the mobile operating system.
Step 202, configuring a development environment according to the source code engineering file.
Step 203, the first dynamic link library file in the source code engineering file is changed into a comment.
And 204, acquiring a second dynamic link library file, and placing the second dynamic link library file into a directory corresponding to the architecture of a processor in the source code engineering file to obtain an updated source code engineering file, wherein the processor comprises a processor of a desktop operating system and a processor of a mobile operating system, and the version of the second dynamic link library file is higher than that of the first dynamic link library file.
And step 205, running and updating the source code engineering file to obtain a library file.
Step 206, the library file is placed into the native project of the specified application program.
And step 207, running the primary project of the specified application program to obtain an installation package of the application program.
In summary, the embodiment of the present application provides an application program compatibility method, in which a first dynamic link library file in a source code engineering file corresponding to a mobile operating system is changed into a comment, a second dynamic link library file with a version higher than that of the first dynamic link library file is placed in a directory corresponding to a framework of a processor in the source code engineering file to obtain an updated source code engineering file, the updated source code engineering file is run to obtain an updated library file, the library file is placed in a native project of a specified application program, the native project of the specified application program is run to obtain an installation package of the application program, so that compatibility between the application program and a pc-side simulator is improved by using the dynamic link library file with a higher version, and a crash caused by a compatibility problem between the application program and the simulator is repaired. The problem of relatively poor compatibility of the application program in the related technology is solved, and the effect of improving the compatibility of the application program is achieved.
Fig. 3 is a flowchart of another application compatibility method according to an embodiment of the present application, where the application compatibility method may be applied to a terminal in the implementation environment. The application program compatibility method can comprise the following steps:
step 301, acquiring a source code engineering file of a cross-platform mobile application development framework corresponding to a mobile operating system.
The terminal running the desktop operating system can acquire the source code engineering file of a cross-platform mobile application development framework (such as read Native) corresponding to the mobile operating system through the open source library. Illustratively, the source code engineering file of reach Native may be obtained from https:// github. Com/facebook/act-Native.
Step 302, configuring a development environment according to the source code engineering file of the cross-platform mobile application development framework and the native development toolkit.
The terminal running the desktop operating system can import the source code engineering file of the cross-platform mobile application Development framework into the Development tool, and then configure the Development environment according to the source code engineering file of the cross-platform mobile application Development framework and a Native Development Kit (NDK).
Illustratively, the source code engineering file of the real Native may be imported into an Android Studio (the Android Studio is an integrated development tool corresponding to an Android system), and then the development environment may be configured according to the source code engineering file of the real Native and the NDK.
Step 303, the first dynamic link library file in the source code engineering file of the cross-platform mobile application development framework is changed into an annotation.
The first version of the dynamic link library file directly obtained from the open source library is usually low, which easily causes the problem of the crash of the simulator, i.e. the compatibility with the simulator is low. In the embodiment of the application, the terminal may change the first dynamic link library file into the annotation, that is, change the first dynamic link library file into a state that cannot be run.
Illustratively, the first dynamic link library file may comprise an android-jsc dynamic link library file. A virtual machine (JavaScript core, jsc) is an engine of JavaScript (a programming language), and an android-jsc is a dynamically linked library file that jsc runs on an android platform.
And 304, acquiring a second dynamic link library file, and putting the second dynamic link library file into a directory corresponding to the architecture of the processor in the source code engineering file of the cross-platform mobile application development framework to obtain an updated source code engineering file.
Wherein, the processor (cpu) includes a processor of a desktop operating system and a processor of a mobile operating system, and the second dynamic link library file can be obtained in an open source community (such as https:// www.npmjs.com/package/jsc-android), and the version of the second dynamic link library file is generally higher than that of the first dynamic link library file. The architecture of the desktop operating system processor may be x86 or x64, while the architecture of the mobile operating system processor may be an Advanced reduced instruction set Machine (ARM) architecture. Processors of different architectures may correspond to different directories in a cross-platform mobile application development framework.
And after the terminal puts the second dynamic link library file into a directory corresponding to the architecture of the processor in the source code engineering file of the cross-platform mobile application development framework, the updated source code engineering file can be obtained. The version of the second dynamic link library file in the updated source code engineering file is high, and the compatibility is good.
Illustratively, the version of the second dynamic link library file may be the r216113.0.3 version, which has a higher compatibility with simulators. The second dynamic link library file of the r216113.0.3 version may be placed under x86 and armeabi directories in the source code engineering file of the cross-platform mobile application development framework, respectively, according to the processor architecture (both the x86 and armeabi directories are under libs directories of the source code engineering file of the cross-platform mobile application development framework), where the x86 directory is a directory corresponding to an x86 architecture processor of the desktop operating system, and the armeabi directory is a directory corresponding to an arm architecture processor of the mobile operating system.
And 305, running and updating the source code engineering file to obtain a library file.
After obtaining the updated source code engineering file, the terminal may run the updated source code engineering file to obtain a library file, where the library file may include an aar file, and the aar file may include a resource file.
Step 306, the library file is placed into the native project of the specified application program.
The specified application may refer to an application for which compatibility enhancement is to be performed. The terminal may place the library file obtained in step 305 in the native project of the specified application. Wherein specifying the native item of the application may include specifying an Android native item of the application. The native project is a file for generating an application program, running the native project in the development tool can generate an installation package of the application program corresponding to the native project, and the installation package of the application program can include the native project and a cross-platform running module and other components.
Illustratively, the terminal may place the library file into a local-repository directory (local-repository) in the native project of the specified application.
And 307, modifying the name of the library file according to the version number of the source code engineering file of the cross-platform mobile application development framework.
And modifying the name of the library file according to the version number of the source code engineering file of the cross-platform mobile application development framework, so that the original library file in the primary project of the specified application program can be replaced.
For example, if the version number of the source code engineering file acquired in step 301 is 0.54.4, the name of the library file may be modified to be exact-native-0.54.4.
Step 307 may be executed after obtaining the library file, that is, step 307 may be executed after step 305, or may be executed after step 306, which is not limited in this embodiment of the application.
At step 308, a notification module is created in the native project of the specified application. And the notification module is used for transmitting data when the application program runs.
And a notification module is created in the native project of the specified application program, and data can be transmitted by the notification module when the application program runs. Step 308 may be before step 301, or after any step from step 301 to step 307, and this embodiment of the present application is not limited in any way.
Step 309, running the native project of the specified application program to obtain the installation package of the application program.
The installation package comprises a cross-platform running module (i.e. js terminal, a module mainly written by JavaScript language) and a local Event Emitter (Native Event Emitter). And running the native project of the specified application program by using the development tool to obtain the installation package of the application program.
The installation package obtained in step 309 is generated according to the dynamic link library file of the high version, so that the stability of the simulator of the mobile operating system can be remarkably improved.
The application program compatibility method provided by the embodiment of the application program can comprise the steps of generating a part of an installation package of the application program, and running the part of the application program in a simulator of a mobile operating system through the installation package.
Steps 301 to 309 are part of generating an installation package of the application program, and the subsequent step is running the part of the application program in the simulator of the mobile operating system through the installation package.
The main body of the step 310 to the step 313 is also a terminal running a desktop operating system, but the terminal may be the same terminal as the terminal executing the step 301 to the step 309, or the terminal executing the step 310 to the step 313 may be a different terminal from the terminal executing the step 301 to the step 309, which is not limited in the embodiment of the present application.
When the terminal performing steps 310 to 313 and the terminal performing steps 301 to 309 are different terminals, the terminal performing steps 301 to 309 may be a terminal of an application provider and the terminal performing steps 310 to 313 may be a terminal of an application user.
And step 310, controlling the notification module to package and send data through the cross-platform running module.
When the application program is run in the simulator of the mobile operating system, the cross-platform running module can control the notification module to package and send data, the data can include data corresponding to the operation of a user on the application program display page, and the notification module packages and sends the data to the server.
Step 311, when the notification module receives the data, the unpacked data is sent to the cross-platform operation module through the local event transmitter.
The terminal can receive and unpack the data through the notification module. And unpacking the data after receiving the data returned by the server, and sending the unpacked data to the cross-platform running module through the local event emitter, wherein the local event emitter can be positioned in a native project of a specified application program.
In the related art, the packet unpacking of the data and the sending and receiving of the data are performed at a cross-platform operation module (js end), and crash caused by abnormal data of a server interface may occur by using the method, but the packet unpacking of the data and the sending and receiving of the data are transferred from the cross-platform operation module (js end) to a primary project of a specified application program through the step 310 and the step 311, so that crash caused by abnormal data of the server interface can be avoided.
And step 312, performing judgment processing on the unpacked data through the cross-platform operation module.
The judgment processing comprises the steps of judging whether each field in the unpacked data exists and is assigned, if any field in the unpacked data does not exist or is not assigned, assigning a specified value to any field, and setting the specified value by an operator according to the actual situation. The unpacking data is judged in a data layer of the cross-platform operation module.
When the unpacked data is abnormal, the terminal uses the unpacked data which is not subjected to the emptying processing, and collapse caused by abnormal server interface data can occur.
The unpacking data is subjected to judgment processing, so that the crash caused by the server data exception can be improved.
And 313, sending the unpacked data subjected to the judgment processing to a service layer for data rendering.
The terminal can send the unpacked data subjected to the judgment processing to a service layer of the cross-platform operation module for data rendering, and the data rendering is to display a corresponding page according to the operation of a user.
For example, as shown in fig. 4, the display page is a display page of an application program on the terminal after the service layer performs data rendering on unpacked data. The user can operate according to the requirement, and the operation can include clicking a certain position of a display page, controlling data corresponding to the position of the notification module to be packaged by the cross-platform operation module, and sending the data to the server.
Fig. 5 is a flow chart illustrating the running of an application in a simulator of a mobile operating system. And starting an application program in a simulator of the mobile operating system, and initializing an executable file by using the second dynamic link library file, wherein the executable file is initialized once when the application is started every time, and the executable file can comprise a Bundle file. And displaying a page, and when a user operates the displayed page, packaging data corresponding to the user operation by the cross-platform operation module through the notification module in the application native project, and sending the data to the server. The server returns corresponding data according to the received data, the notification module unpacks the data after receiving the data returned by the server, and the unpacked data are sent to the cross-platform operation module. And the data layer of the cross-platform operation module performs the judgment on the unpacked data, sends the unpacked data subjected to the judgment to the service layer of the cross-platform operation module for data rendering, and displays a page corresponding to the user operation.
In summary, the embodiment of the present application provides an application program compatibility method, in which a first dynamic link library file in a source code engineering file corresponding to a mobile operating system is changed into a comment, a second dynamic link library file with a version higher than that of the first dynamic link library file is placed in a directory corresponding to a framework of a processor in the source code engineering file to obtain an updated source code engineering file, the updated source code engineering file is run to obtain an updated library file, the library file is placed in a native project of a specified application program, the native project of the specified application program is run to obtain an installation package of the application program, so that compatibility between the application program and a pc-side simulator is improved by using the dynamic link library file with a higher version, and a crash caused by a compatibility problem between the application program and the simulator is repaired. The problem of relatively poor compatibility of the application program in the related technology is solved, and the effect of improving the compatibility of the application program is achieved.
In the compatible method for an application provided in the embodiment of the present application, a process of generating an installation package in an exemplary embodiment may include:
a terminal of a provider (such as a provider of a small partner application) of an application program obtains a source code engineering file of real Native from the terminal, the source code engineering file of the real Native is imported into Android Studio, a development environment is configured according to the source code engineering file of the real Native and NDK, a dynamic link library file of Android-jsc in the source code engineering file of the real Native is changed into an annotation, a dynamic link library file of an r216113.0.3 version is obtained, the dynamic link library file of the r216113.0.3 version is placed into x86 and armeabi directories under a libs directory of the source code engineering file of the real Native according to a cpu architecture, an updated source code engineering file is obtained, and the updated source code engineering file is operated to obtain an aar file. And (3) putting the aar file into an Android Native project of a specified application program, and modifying the name of the aar file according to the version number (namely 0.54.4) of the source code engineering file of the real Native, wherein the modified aar file is named as a real-Native-0.54.4. Aar. And creating a notification module in the Android primary project of the specified application program, and operating the Android primary project of the specified application program to obtain an installation package of the application program.
In the compatible method for an application provided in the embodiment of the present application, a process of running the application may include, in an exemplary embodiment:
the terminal of the user of the application (for example, a user of a small buddy application) starts the application in the simulator of the mobile operating system, and initializes the Bundle file using the dynamic link library file of the r216113.0.3 version. And displaying a page, and when a user operates the displayed page, packaging data corresponding to the user operation by the cross-platform operation module through a notification module in the Android native project, and sending the data to the server. The server returns corresponding data according to the received data, the notification module unpacks the data after receiving the data returned by the server, and sends the unpacked data to the cross-platform operation module. And the data layer of the cross-platform operation module performs the judgment on the unpacked data, sends the unpacked data subjected to the judgment to the service layer of the cross-platform operation module for data rendering, and displays a page corresponding to the user operation.
Fig. 6 is a block diagram of a compatible device of an application according to an embodiment of the present application. As can be seen with reference to fig. 6, the compatible device of the application may include:
the first obtaining module 601 is configured to obtain a source code engineering file corresponding to the mobile operating system.
And a configuration module 602, configured to configure the development environment according to the source code engineering file.
A changing module 603, configured to change the first dynamic link library file in the source code engineering file into an annotation.
The second obtaining module 604 is configured to obtain a second dynamic link library file, and place the second dynamic link library file in a directory corresponding to a framework of a processor in the source code engineering file to obtain an updated source code engineering file, where the processor includes a processor of a desktop operating system and a processor of a mobile operating system, and a version of the second dynamic link library file is higher than a version of the first dynamic link library file.
The first running module 605 is configured to run the updated source code engineering file to obtain a library file.
A setup module 606 for placing the library file into the native project of the specified application.
The second running module 607 is configured to run the native project of the specified application program, and obtain the installation package of the application program.
In summary, the embodiment of the present application provides an apparatus for application compatibility, where the apparatus changes a first dynamic link library file in a source code engineering file corresponding to a mobile operating system into an annotation, and places a second dynamic link library file having a version higher than that of the first dynamic link library file into a directory corresponding to a framework of a processor in the source code engineering file to obtain an updated source code engineering file, runs the updated source code engineering file to obtain a library file, places the library file into a native project of a specified application program, runs the native project of the specified application program, and obtains an installation package of the application program. The problem of relatively poor compatibility of the application program in the related technology is solved, and the effect of improving the compatibility of the application program is achieved.
Fig. 7 is a block diagram of another application compatible device provided in the embodiment of the present application. As can be seen with reference to fig. 7, the compatible device of the application may include:
the first obtaining module 701 is configured to obtain a source code engineering file corresponding to the mobile operating system.
And a configuration module 702, configured to configure the development environment according to the source code engineering file.
A changing module 703, configured to change the first dynamic link library file in the source code engineering file into an annotation.
The second obtaining module 704 is configured to obtain a second dynamic link library file, and place the second dynamic link library file in a directory corresponding to a framework of a processor in the source code engineering file to obtain an updated source code engineering file, where the processor includes a processor of a desktop operating system and a processor of a mobile operating system, and a version of the second dynamic link library file is higher than a version of the first dynamic link library file.
The first running module 705 is configured to run the updated source code engineering file to obtain a library file.
A setup module 706 to place the library file into the native project of the specified application.
The second running module 707 is configured to run the native project of the specified application, and obtain an installation package of the application.
A notification module 708, configured to transmit data when the application runs.
In summary, the embodiment of the present application provides an apparatus for application program compatibility, where a first dynamic link library file in a source code engineering file corresponding to a mobile operating system is changed into a comment, a second dynamic link library file with a version higher than that of the first dynamic link library file is placed in a directory corresponding to a framework of a processor in the source code engineering file to obtain an updated source code engineering file, the updated source code engineering file is run to obtain an updated library file, the library file is placed in a native project of a specified application program, the native project of the specified application program is run to obtain an installation package of the application program, and thus, by using the dynamic link library file with a higher version, compatibility between the application program and a pc-side simulator is improved, and a crash caused by a compatibility problem between the application program and the simulator is repaired. The problem of relatively poor compatibility of the application program in the related technology is solved, and the effect of improving the compatibility of the application program is achieved.
Referring to fig. 8, a schematic structural diagram of an application compatible device 800 according to an embodiment of the present application is shown, where the application compatible device 800 may be various terminals using a desktop operating system. Illustratively, as shown in FIG. 8, the apparatus 800 includes a Central Processing Unit (CPU) 801, a system memory 804 including a Random Access Memory (RAM) 802 and a Read Only Memory (ROM) 803, and a system bus 805 connecting the system memory 804 and the central processing unit 801. The apparatus 800 also includes a basic input/output system (I/O system) 806, which facilitates transfer of information between devices within the computer, and a mass storage device 807 for storing an operating system 813, application programs 814, and other program modules 815.
The basic input/output system 806 includes a display 808 for displaying information and an input device 809 such as a mouse, keyboard, etc. for user input of information. Wherein a display 808 and an input device 809 are connected to the central processing unit 801 through an input output controller 810 connected to the system bus 805. The basic input/output system 806 may also include an input/output controller 810 for receiving and processing input from a number of other devices, such as a keyboard, mouse, or electronic stylus. Similarly, an input/output controller 810 also provides output to a display screen, a printer, or other type of output device.
The mass storage device 807 is connected to the central processing unit 801 through a mass storage controller (not shown) connected to the system bus 805. The mass storage device 807 and its associated computer-readable media provide non-volatile storage for the apparatus 800. That is, the mass storage device 807 may include a computer-readable medium (not shown) such as a hard disk or CD-ROM drive.
Without loss of generality, computer-readable storage media may comprise computer storage media and communication media. Computer storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data. Computer storage media includes RAM, ROM, EPROM, EEPROM, flash memory or other solid state memory technology, CD-ROM, DVD, or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices. Of course, those skilled in the art will appreciate that computer storage media is not limited to the foregoing. The system memory 804 and mass storage 807 described above may be collectively referred to as memory.
According to various embodiments of the present application, the apparatus 800 may also operate as a remote computer connected to a network through a network, such as the Internet. That is, the apparatus 800 may be connected to a network 812 through a network interface unit 811 coupled to the system bus 805, or may be connected to other types of networks or remote computer systems (not shown) using the network interface unit 811.
The memory further includes one or more programs, and the one or more programs are stored in the memory and configured to be executed by the CPU to implement the method provided by the embodiment of the present application.
The embodiment of the present application further provides an apparatus compatible with an application, where the apparatus compatible with an application includes a processor and a memory, where the memory stores at least one instruction, at least one program, a code set, or a set of instructions, and the at least one instruction, the at least one program, the code set, or the set of instructions is loaded and executed by the processor to implement the method compatible with an application provided in the foregoing method embodiment.
Embodiments of the present application further provide a computer storage medium having at least one instruction, at least one program, a set of codes, or a set of instructions stored therein, which is loaded and executed by a processor to implement a compatible method of an application program as provided in the above method embodiments.
The above description is only exemplary of the present application and should not be taken as limiting, as any modification, equivalent replacement, or improvement made within the spirit and principle of the present application should be included in the protection scope of the present application.

Claims (10)

1. A method for application compatibility, for use with a desktop operating system, the method comprising:
acquiring a source code engineering file corresponding to a mobile operating system;
configuring a development environment according to the source code engineering file;
changing a first dynamic link library file in the source code engineering file into an annotation;
acquiring a second dynamic link library file, and putting the second dynamic link library file into a directory corresponding to a framework of a processor in the source code engineering file to obtain an updated source code engineering file, wherein the processor comprises a processor of the desktop operating system and a processor of the mobile operating system, and the version of the second dynamic link library file is higher than that of the first dynamic link library file;
running the updated source code engineering file to obtain a library file;
putting the library file into a native project of a specified application program;
and running the native project of the specified application program to obtain an installation package of the application program.
2. The method of claim 1, wherein before the running the native project of the specified application results in an installation package for the application, the method further comprises:
creating a notification module in a native project of the specified application;
after the running of the native project of the specified application program and obtaining the installation package of the application program, the method further includes:
and running the application program in a simulator of the mobile operating system according to the installation package, wherein the notification module is used for transmitting data when the application program runs.
3. The method of claim 2, wherein the installation package comprises a cross-platform execution module and a local event transmitter, and wherein executing the application program in the simulator of the mobile operating system according to the installation package comprises:
the cross-platform operation module controls the notification module to package and send data;
receiving and unpacking data through the notification module;
when the notification module receives the data, sending the unpacked data to the cross-platform operation module through a local event transmitter;
performing judgment processing on the unpacked data through the cross-platform operation module;
and sending the unpacked data subjected to the judgment processing to a service layer for data rendering.
4. The method according to claim 3, wherein the performing, by the cross-platform running module, a predicate process on the unpacked data comprises:
judging whether each field in the unpacked data exists and is assigned;
and if any field in the unpacked data does not exist or is not assigned with a value, assigning a specified value to the any field.
5. The method of claim 1, wherein the source code engineering file is a source code engineering file of a cross-platform mobile application development framework, and wherein configuring the development environment according to the source code engineering file comprises:
and configuring the development environment according to the source code engineering file and the native development toolkit of the cross-platform mobile application development framework.
6. The method of claim 1, wherein before the running the native project of the specified application results in an installation package for the application, the method further comprises:
and modifying the name of the library file according to the version number of the source code engineering file.
7. An application compatible device for use with a desktop operating system, the device comprising:
the first acquisition module is used for acquiring a source code engineering file corresponding to the mobile operating system;
the configuration module is used for configuring a development environment according to the source code engineering file;
the changing module is used for changing a first dynamic link library file in the source code engineering file into an annotation;
a second obtaining module, configured to obtain a second dynamic link library file, and place the second dynamic link library file in a directory corresponding to a framework of a processor in the source code engineering file to obtain an updated source code engineering file, where the processor includes a processor of the desktop operating system and a processor of the mobile operating system, and a version of the second dynamic link library file is higher than a version of the first dynamic link library file;
the first operation module is used for operating the updated source code engineering file to obtain a library file;
the setting module is used for putting the library file into a native project of a specified application program;
and the second running module is used for running the native project of the specified application program to obtain the installation package of the application program.
8. The apparatus of claim 7, further comprising:
and the notification module is used for transmitting data when the application program runs.
9. An application-compatible device comprising a processor and a memory, wherein at least one instruction, at least one program, set of codes, or set of instructions is stored in the memory, and wherein the at least one instruction, the at least one program, the set of codes, or the set of instructions is loaded and executed by the processor to implement an application-compatible method according to any one of claims 1 to 6.
10. A computer storage medium having stored therein at least one instruction, at least one program, set of codes, or set of instructions, which is loaded and executed by a processor to implement a compatible method of an application program according to any one of claims 1 to 6.
CN201911158733.7A 2019-11-22 2019-11-22 Application program compatibility method, device, equipment and computer storage medium Active CN111026439B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911158733.7A CN111026439B (en) 2019-11-22 2019-11-22 Application program compatibility method, device, equipment and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911158733.7A CN111026439B (en) 2019-11-22 2019-11-22 Application program compatibility method, device, equipment and computer storage medium

Publications (2)

Publication Number Publication Date
CN111026439A CN111026439A (en) 2020-04-17
CN111026439B true CN111026439B (en) 2023-03-24

Family

ID=70203239

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911158733.7A Active CN111026439B (en) 2019-11-22 2019-11-22 Application program compatibility method, device, equipment and computer storage medium

Country Status (1)

Country Link
CN (1) CN111026439B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112764797B (en) * 2021-01-06 2023-03-21 浙江大华技术股份有限公司 Software compatibility detection method and device, electronic device and storage medium
CN112783542A (en) * 2021-02-04 2021-05-11 华东交通大学 Software upgrading method and device and readable storage medium
CN113535227B (en) * 2021-09-07 2021-12-21 深圳市云中鹤科技股份有限公司 Deployment method and device of digital technology architecture
CN115129333B (en) * 2022-09-02 2022-11-25 城云科技(中国)有限公司 NPm resource package management method, device and system suitable for micro front-end framework

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5838911A (en) * 1996-05-23 1998-11-17 Electronic Data Systems Corporation Method and apparatus for obtaining network information by using a dynamic link library
CN101650668A (en) * 2008-08-11 2010-02-17 优诺威讯国际有限公司 Method and device for realizing virtual environment
US7735079B1 (en) * 2005-02-04 2010-06-08 Symantec Corporation Securely hooking installations for compatibility with other applications
CN103379481A (en) * 2012-04-26 2013-10-30 腾讯科技(深圳)有限公司 Method for achieving safety protection and firewall
CN103677777A (en) * 2012-09-19 2014-03-26 腾讯科技(深圳)有限公司 Method and device for calling application program component
CN104965712A (en) * 2015-07-17 2015-10-07 北京奇虎科技有限公司 Application reinforcing protection method and apparatus and mobile terminal
CN106371940A (en) * 2015-07-21 2017-02-01 腾讯科技(深圳)有限公司 Solution method and device for program crash
CN110046479A (en) * 2019-03-21 2019-07-23 腾讯科技(深圳)有限公司 A kind of chained library file reverse adjustment method and device based on Android operation system

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6484309B2 (en) * 1998-10-08 2002-11-19 Intel Corporation Enabling software designed for one operating system to operate on another operating system
US20140304720A1 (en) * 2013-04-03 2014-10-09 Tencent Technology (Shenzhen) Company Limited Method for starting process of application and computer system

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5838911A (en) * 1996-05-23 1998-11-17 Electronic Data Systems Corporation Method and apparatus for obtaining network information by using a dynamic link library
US7735079B1 (en) * 2005-02-04 2010-06-08 Symantec Corporation Securely hooking installations for compatibility with other applications
CN101650668A (en) * 2008-08-11 2010-02-17 优诺威讯国际有限公司 Method and device for realizing virtual environment
CN103379481A (en) * 2012-04-26 2013-10-30 腾讯科技(深圳)有限公司 Method for achieving safety protection and firewall
CN103677777A (en) * 2012-09-19 2014-03-26 腾讯科技(深圳)有限公司 Method and device for calling application program component
CN104965712A (en) * 2015-07-17 2015-10-07 北京奇虎科技有限公司 Application reinforcing protection method and apparatus and mobile terminal
CN106371940A (en) * 2015-07-21 2017-02-01 腾讯科技(深圳)有限公司 Solution method and device for program crash
CN110046479A (en) * 2019-03-21 2019-07-23 腾讯科技(深圳)有限公司 A kind of chained library file reverse adjustment method and device based on Android operation system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
DLL在机载总线仿真系统中的应用;丛伟等;《现代电子技术》;20030825(第16期);全文 *

Also Published As

Publication number Publication date
CN111026439A (en) 2020-04-17

Similar Documents

Publication Publication Date Title
CN111026439B (en) Application program compatibility method, device, equipment and computer storage medium
CN111740948B (en) Data packet issuing method, dynamic updating method, device, equipment and medium
CN111338623B (en) Method, device, medium and electronic equipment for developing user interface
CN108762767B (en) Application publishing method, device and computer readable storage medium
CN113010827B (en) Page rendering method and device, electronic equipment and storage medium
CN112769706B (en) Componentized routing method and system
CN113805882A (en) Method and device for developing application program, electronic equipment and storage medium
CN112416458A (en) Preloading method and device based on ReactNative, computer equipment and storage medium
CN113050940A (en) Method for previewing small program, related device and computer program product
CN108733370B (en) Stylized display method, device, terminal and storage medium of native APP
JP7048663B2 (en) Code execution methods, devices, rendering devices, storage media, and programs
CN110928571A (en) Business program development method and device
CN113138768B (en) Application package generation method and device, electronic equipment and readable storage medium
CN112988175A (en) Cross-platform application installation package generation method, device, medium and electronic equipment
CN111414154A (en) Method and device for front-end development, electronic equipment and storage medium
CN112000334A (en) Page development method, device, server and storage medium
WO2023083071A1 (en) View interaction method and apparatus, electronic device, and computer readable medium
CN112835568A (en) Project construction method and device
CN113468067B (en) Application program debugging method and device, electronic equipment and computer readable medium
CN112988588B (en) Client software debugging method and device, storage medium and electronic equipment
CN114461223A (en) Code generation method and device and terminal equipment
CN112714148A (en) Interface configuration method, device, equipment and medium
CN110780864A (en) Control method and device for class method replacement, storage medium and electronic equipment
CN111158661A (en) System interface docking method, device, medium and electronic equipment
EP4191407A1 (en) Method and device for generating and registering ui service package and loading ui service

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
TA01 Transfer of patent application right
TA01 Transfer of patent application right

Effective date of registration: 20210111

Address after: 511442 3108, 79 Wanbo 2nd Road, Nancun Town, Panyu District, Guangzhou City, Guangdong Province

Applicant after: GUANGZHOU CUBESILI INFORMATION TECHNOLOGY Co.,Ltd.

Address before: 511446 24 / F, building B-1, Wanda Plaza, Panyu District, Guangzhou City, Guangdong Province

Applicant before: GUANGZHOU HUADUO NETWORK TECHNOLOGY Co.,Ltd.

EE01 Entry into force of recordation of patent licensing contract
EE01 Entry into force of recordation of patent licensing contract

Application publication date: 20200417

Assignee: GUANGZHOU HUADUO NETWORK TECHNOLOGY Co.,Ltd.

Assignor: GUANGZHOU CUBESILI INFORMATION TECHNOLOGY Co.,Ltd.

Contract record no.: X2021440000054

Denomination of invention: Compatible method, device, device and computer storage medium of application program

License type: Common License

Record date: 20210208

GR01 Patent grant
GR01 Patent grant