CN108595192B - Application program installation method and terminal equipment - Google Patents

Application program installation method and terminal equipment Download PDF

Info

Publication number
CN108595192B
CN108595192B CN201810434234.5A CN201810434234A CN108595192B CN 108595192 B CN108595192 B CN 108595192B CN 201810434234 A CN201810434234 A CN 201810434234A CN 108595192 B CN108595192 B CN 108595192B
Authority
CN
China
Prior art keywords
application program
user
file
library file
partition
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
CN201810434234.5A
Other languages
Chinese (zh)
Other versions
CN108595192A (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.)
Hisense Broadband Multimedia Technology Co Ltd
Original Assignee
Hisense Broadband Multimedia 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 Hisense Broadband Multimedia Technology Co Ltd filed Critical Hisense Broadband Multimedia Technology Co Ltd
Priority to CN201810434234.5A priority Critical patent/CN108595192B/en
Publication of CN108595192A publication Critical patent/CN108595192A/en
Application granted granted Critical
Publication of CN108595192B publication Critical patent/CN108595192B/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/60Software deployment
    • G06F8/61Installation

Abstract

The invention provides an installation method of an application program and terminal equipment, and relates to the field of computers. The embodiment of the invention can avoid library file conflict caused by the duplicate name of the library file of the application program preset in the terminal equipment, thereby avoiding the problem of influencing the normal operation of the application program. The method comprises the following steps: acquiring an APK android installation package file of an application program in a system partition, wherein the APK file comprises a library file of the application program; and storing the library file of the application program to a user directory corresponding to the application program in the user partition, so that the library file of the application program in the user directory is loaded through a general interface when the application program runs. The embodiment of the invention is applied to the terminal equipment adopting the Android operating system.

Description

Application program installation method and terminal equipment
Technical Field
The present invention relates to the field of computers, and in particular, to an installation method of an application program and a terminal device.
Background
At present, terminal products of an Android system become mainstream products in the intelligent terminal equipment market. In order to provide richer function experience, a terminal device manufacturer generally selects to cooperate with a third-party application provider, and presets an application program which is good in experience and popular with a user as a system application of a product, so that the mode becomes a mainstream trend of the intelligent terminal device market.
At present, many algorithms of the application program or functions related to the platform are realized by adopting a more efficient C language, and are dynamically loaded in the form of library files when the application program runs. When the application program is preset as a system application, after an APK (android package) file is placed at a corresponding position under a/system directory, a library file of the application program needs to be separately placed under the/system/lib directory, so that the corresponding library file under the/system/lib directory is loaded through a general interface when the application program runs.
In view of the above prior art, the inventors found that: as the functions of the application programs are gradually enhanced, library files are more and more, and when a large number of application programs need to be preset, the library file of each preset application program needs to be placed under a system/lib directory, which may cause a problem of library file collision due to the same name of the library file, and further cause that some application programs cannot correctly load the library files thereof, so that the functions of the application programs are abnormal.
Disclosure of Invention
The invention provides an installation method of an application program and a terminal device, which can avoid the problem that the normal operation of the application program is influenced due to library file collision caused by the duplicate name of a library file of the application program preset in the terminal device.
In order to achieve the above purpose, the embodiment of the invention adopts the following technical scheme:
in a first aspect, the present invention provides an installation method of an application program, which is applied to a terminal device adopting an Android operating system, and the method includes: acquiring an APK android installation package file of an application program in a system partition, wherein the APK file comprises a library file of the application program; and storing the library file of the application program to a user directory corresponding to the application program in the user partition, so that the library file of the application program in the user directory is loaded through a general interface when the application program runs.
In a second aspect, the present invention provides a terminal device, where the terminal device employs an Android operating system, and the terminal device includes: the device comprises an acquisition unit, a storage unit and a processing unit, wherein the acquisition unit is used for acquiring an APK android installation package file of an application program in a system partition, and the APK file comprises a library file of the application program; and the library file installation unit is used for storing the library file of the application program into the user directory corresponding to the application program in the user partition after the acquisition unit acquires the APK file, so that the library file of the application program in the user directory is loaded through the universal interface when the application program runs.
In a third aspect, a terminal device is provided, including: communication interface, processor, memory, bus; the memory is used for storing computer execution instructions, the processor is connected with the memory through the bus, and when the terminal device runs, the processor executes the computer execution instructions stored in the memory, so that the terminal device executes the method provided by the first aspect.
In a fourth aspect, there is provided a computer storage medium comprising instructions which, when run on a computer, cause the computer to perform the method as provided in the first aspect above.
In the installation method of the application program provided by the embodiment of the invention, the library file is generally loaded by a universal interface method system. The system, the loadlibrary, in the actual execution process, loads the library file in a way of searching the library file name, and the searching process specifically includes: firstly, searching a library file corresponding to an application program under a library file directory (usually/system/lib) in a system partition, and if the library file is searched, loading the library file; and if the corresponding library file is not found under the library file directory in the system partition, finding the corresponding library file under the user directory corresponding to the application program under the library file directory in the user partition, and loading the library file. Further, in the embodiment of the present invention, by saving the library file of the preset application program in the user directory corresponding to the application program in the user partition, a situation that the library files of the preset application program are all mixed in the library file directory in the system partition in the prior art is avoided, and further, a problem that library file collision may occur when the library file renaming of the application program occurs is avoided. In addition, in the embodiment of the present invention, after the ROM of the operating system is written into the terminal device and the operating system is started, the library file is stored in the corresponding directory of the user partition, so that the step of separately decompressing the APK file, taking out the library file from the APK file, and placing the library file in the system/lib directory of the SDK (Software Development Kit) of the project engineering is omitted when the preset application program is integrated into the ROM, thereby simplifying the integration step of the APK library file.
It is to be understood that any one of the terminal device or the computer storage medium provided above is used to execute the method according to the first aspect provided above, and therefore, the beneficial effects achieved by the method according to the first aspect and the beneficial effects of the solutions in the following detailed description may be referred to, and are not repeated herein.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below.
Fig. 1 is a flowchart of an installation method of an application according to an embodiment of the present invention;
FIG. 2 is a flow chart of another method for installing an application according to an embodiment of the present invention;
fig. 3 is a flowchart of a further method for installing an application according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of a terminal device according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of another terminal device according to an embodiment of the present invention;
fig. 6 is a schematic structural diagram of another terminal device according to an embodiment of the present invention.
Detailed Description
Embodiments of the present invention will be described below with reference to the accompanying drawings.
First, the inventive principle of the present invention is described:
at present, application programs in a terminal device adopting an Android operating system are divided into preset applications (also called system applications) and user applications. The preset application is the application preset when the terminal equipment leaves the factory, and is characterized in that: the application program is stored under an application installation directory, typically referred to as/system/app directory, of the system partition with read-only properties. And the library file corresponding to the application program is stored in the system partition/system/lib directory and cannot be deleted. The user application, namely the application which is independently installed by the user, is characterized in that: when the corresponding library file is installed, the corresponding library file is automatically stored in a user directory corresponding to an application program under a data/app-lib directory in the user partition and can be automatically unloaded. The library files of each preset application of the terminal equipment are stored in the system partition/system/lib directory, so that when a plurality of application programs adopt library files with the same name, the library files conflict, only one of the library files can be ensured, and if the functions realized by the library files are different, the problem of abnormal function or running exit of one application can be caused.
Based on the above situation, the inventor of the present invention considers that the library file is generally loaded by a universal interface method system. The system, the loadlibrary, in the actual execution process, loads the library file in a way of searching the library file name, and the searching process specifically includes: firstly, searching a library file corresponding to an application program under a library file directory (usually/system/lib) in a system partition, and if the library file is searched, loading the library file; and if the corresponding library file is not found under the library file directory in the system partition, finding the corresponding library file under the user directory corresponding to the application program under the library file directory in the user partition, and loading the library file. Further, in the embodiment of the present invention, by saving the library file of the preset application program in the user directory corresponding to the application program in the user partition, a situation that the library files of the preset application program are all mixed in the library file directory in the system partition in the prior art is avoided, and further, a problem that library file collision may occur when the library file renaming of the application program occurs is avoided. In addition, in the embodiment of the present invention, after the ROM of the operating system is written into the terminal device and the operating system is started, the library file is stored in the corresponding directory of the user partition, so that the step of separately decompressing the APK file, taking out the library file from the APK file, and placing the library file in the system/lib directory of the SDK (Software Development Kit) of the project engineering is omitted when the preset application program is integrated into the ROM, thereby simplifying the integration step of the APK library file.
The first embodiment is as follows:
based on the above inventive principle, the present invention provides an installation method of an application program, as shown in fig. 1, the method includes:
s101, obtaining an APK file of an application program in a system partition. Wherein, the APK file comprises the library file of the application program.
Specifically, when a Read Only Memory (ROM) version of the terminal device is manufactured, the APK file may be integrated in the ROM version, so that after the ROM version is written into the terminal device, the APK file is stored in a corresponding directory in a system partition with Read Only permission, thereby presetting the application program in the terminal device.
And S102, storing the library file of the application program into a user directory corresponding to the application program in the user partition. So that the library files of the application under the user directory can be loaded through the common interface when the application is running.
For example, in the user partition, the library file of the application program is usually stored in the storage directory corresponding to the application program under the/data/app-lib directory. For example, the library file of the application program A is saved under the data/app-lib/A, and the library file of the application program B is saved under the data/app-lib/B. And then the library files of the application programs preset in the system partition are stored in the user directory corresponding to the application programs in the user partition, so that the condition that the library files conflict due to the same name of the library files of a plurality of application programs is avoided.
In addition, in the prior art, when an application is preset as a system application, an APK (android package) file needs to be placed at a corresponding position under a/system directory, and a library file of the application needs to be placed under the/system/lib directory separately. Specifically, the general steps of presetting the application program include the following: firstly, manually decompressing an APK file of an application program, and taking out a library file contained in a lib directory in the APK file; secondly, placing the APK file under a system/app or/system/priv _ app directory of a project engineering SDK (Software Development Kit); thirdly, placing the taken library file in a system/lib directory of the project engineering SDK; fourthly, compiling and packaging are carried out through the project engineering compiling command, and a ROM version is generated. As can be seen, in the prior art, in order to place a library file into a system/lib directory in a system partition, an APK file needs to be manually decompressed, and the library file is taken out and placed into the system/lib directory of an SDK. Not only does this increase the workload of the developer, but also the manual process is prone to error, which may result in the library file of the APK being missed. In the invention, the library file is stored in the user directory corresponding to the application program in the user partition, so that the library file can be correspondingly installed through the package management service program packagemanagerServer after the android system is started, and the process of manually placing the library file is avoided. When the ROM version is generated by compiling, the method of the invention only needs to place the APK file of the application program in the corresponding directory of the project engineering SDK and then compile to generate the ROM version, thereby saving the process of presetting and installing the library file of the application program and reducing the development cost.
Example two:
based on the installation method of the application program provided in the first embodiment, in an implementation manner, the APK file is stored in an application installation directory in the system partition. Specifically, the application installation directory in the system partition is usually/system/app or/system/priv _ app. That is, when the ROM version is generated, the APK file is placed under the/system/app or/system/priv _ app directory of the project engineering SDK. Furthermore, as shown in fig. 2, the method for installing an application program provided by the present invention specifically includes:
s201, scanning an application installation directory in a system partition by using a PackageManagerServer package management service program to obtain an APK file.
After the Android system is started, the SystemServer starts an Android package management service program PackageManagerServer. After the PackageManagerServer is initialized, scanning all APK files in a/system/app directory, and further acquiring the APK files of the application program.
S202, determining application program information according to the APK file.
Specifically, the packagemanargerserver calls a packagemerer to analyze a configuration file android document.
S203, after determining that the application information does not exist in the package management service program, storing the application information in the package management service program.
Specifically, after determining that the application information does not exist in the PackageManagerServer, the application information is saved to the PackageManagerServer by calling the packagemarser.
And S204, after determining that the application program information does not exist in the package management service program, saving the library file of the application program to a user directory corresponding to the application program in the user partition.
Specifically, when the information of the application program does not exist in the PackageManagerServer, the fact that the application program is not installed in the terminal device is indicated, and further, the application program and the library file are installed in a mode that the information of the application program is stored in a package management service program and the library file is stored in a corresponding user directory in a user partition.
In the embodiment of the invention, the APK file is stored in the application installation directory in the system partition, and the PackageManagerServer is used for realizing the installation of the library file in the installation process of the application program, so that the application program and the library file are automatically installed when the terminal equipment judges that the application program is not installed currently after starting up.
In an implementation manner, considering that the library file of the application program is saved in the readable and writable user partition in the embodiment of the present invention, and in order to avoid a problem that the library file is deleted due to a user misoperation or the like, after determining that the application program information exists in the package management service program, the method provided in the embodiment of the present invention further includes:
s205, judging whether a user directory corresponding to the application program exists in the user partition or not and whether a library file of the application program is stored in the user directory or not.
Specifically, the PackageManagerServer judges whether a user directory of the current application program exists under the data directory.
S206, after determining that the user directory corresponding to the application program does not exist in the user partition, establishing the user directory of the application program, and storing the library file of the application program into the user directory corresponding to the application program in the user partition.
Specifically, when the PackageManagerServer judges that the data directory does not have the user directory of the application program, the user directory is created, so that the library file of the application program is stored in the user directory corresponding to the application program in the user partition.
For another example, when the PackageManagerServer reads the package name of the APK file of the application program and judges that no directory named by the package name exists under the/data/app-lib directory, the directory/data/app-lib/AAA is created, and the library file is copied to the/data/app-lib/AAA directory.
And S207, after the user directory corresponding to the application program exists in the user partition and the user directory does not have the library file of the application program, saving the library file of the application program to the user directory corresponding to the application program in the user partition.
For example, when the PackageManagerServer reads the package name of the APK file of the application program, and judges that a directory named by the package name exists under the/data/app-lib directory, but no library file exists under the directory, the library file is copied to the/data/app-lib/AAA directory.
Additionally, in one implementation, it is contemplated that the application may be updated during use of the terminal device. Therefore, after determining that the application information exists in the package management service program, the installation method provided by the invention further comprises the following steps: and reading the application program information stored in the package management service program by the packageParser, comparing the application program information with the current application program information, and updating the current application program information to the package management service program if the application program information is inconsistent with the current application program information.
The following describes, with reference to an example, specific implementation steps of the application installation method provided by the second embodiment of the present invention:
firstly, before installing the application program, when the ROM version of the terminal device is generated, the APK file of the application program is placed under the/system/app directory of the project engineering SDK and then compiled into the ROM version of the terminal device.
Then, the Android package management service program packagemanagerServer realizes the installation of the application program, wherein the installation of the library file is included, and the method specifically comprises the following steps:
s301, starting an Android system, and starting an Android package management service program packagemanagerServer by the SystemServer.
S302, completing initialization of the PackageManagerServer, and scanning all APK files in the/system/app directory.
S303, calling a PackageManagerServer to analyze a configuration file AndrodiMenifest.xml in the APK file, judging whether the current PackageManagerServer has the application program information, and if not, executing the step S305; if yes, go to step S304.
S304, reading the existing version information of the application program, comparing the version information with the current application program information, and executing the step S305 if the version information of the application program is inconsistent with the current application program information; if yes, go to step S306.
S305, updating or saving the application program information to a packagemanagerServer by the packagemarer.
S306, judging whether the data directory has a user directory of the current APK or not by the packagemanagerServer, and if not, creating and executing the next step; if so, the next step is directly executed.
S307, calling a packagemerarser to analyze the APK file, judging whether a so-base file exists or not, and if so, executing the next step; if not, the process is finished.
S308, reading the current APK package name by the PackageManagerServer, judging whether a directory named by the package name exists under the data/app-lib, and if not, creating and executing the next step; if yes, the next step is executed.
S309, the packagemanagerServer judges whether a corresponding library file exists in the data/app-lib directory, and if not, the next step is carried out; if yes, the process is ended.
S310, the PackageManagerServer copies the so-library file to the corresponding data/app-lib directory.
In the embodiment of the invention, the library files of the preset application program are stored in the user directory corresponding to the application program in the user partition, so that the condition that the library files of the preset application program are all mixed in the library file directory in the system partition in the prior art is avoided, and the problem of library file collision possibly occurring when the library files of the application program are renamed is further avoided. In addition, in the embodiment of the present invention, after the ROM of the operating system is written into the terminal device and the operating system is started, the library file is stored in the corresponding directory of the user partition, so that the step of separately decompressing the APK file, taking out the library file from the APK file, and placing the library file in the system/lib directory of the SDK (Software Development Kit) of the project engineering is omitted when the preset application program is integrated into the ROM, thereby simplifying the integration step of the APK library file.
Example three:
based on the installation method of the application provided in the first embodiment, it is considered that in the installation method of the application provided in the second embodiment, the existing package installation mechanism of the Android needs to be modified, that is, the PackageManagerServer is improved. In practical application, however, modification of the existing installation mechanism of the Android, that is, modification of the Android system, may not be wanted. Furthermore, an embodiment of the present invention further provides another installation method of an application program, where an APK file of the application program is stored in a private directory in a system partition. Specifically, as shown in fig. 3, the method includes:
s402, scanning a private directory in the system partition by using a preset service program, and acquiring an APK file of the application program.
For example, a private directory, thirdapp, is created in the system partition, which holds all the preset third party applications, including the above-mentioned application.
And S403, calling a system installation interface by using a preset service program and installing the APK file into the user partition.
Wherein installing the APK file into the user partition comprises: and acquiring the library file of the application program contained in the APK file, and storing the library file of the application program into a user directory corresponding to the application program in the user partition.
Specifically, in the present invention, a preset service program is implemented, and specifically, the preset service program may be an Android service program apk (installthidapp). And then, the APK files under the private directory in the system partition are installed in the user partition through the preset service program, and then the library files of the application program are automatically placed under the directory corresponding to the application program of the data partition, so that the manual operation process is removed, meanwhile, the corresponding library files can also be placed at different positions because different application programs correspond to different user directories, and the problem of conflict caused by duplicate names of the library files is effectively solved.
In one implementation manner, in order to automatically install the application program stored in the private directory in the system partition at the time of system startup to achieve the above effect, the installation method provided in the embodiment of the present invention further includes, before performing the above steps S402 and S403:
s401, starting of the android operating system is detected, and after the android operating system is determined to be started successfully, a preset service program is operated. The preset service program scans the private directory in the system partition, acquires the APK file of the application program, and calls the system installation interface and installs the APK file into the user partition.
The following describes, with reference to an example, specific implementation steps of the application installation method provided by the second embodiment of the present invention:
first, when a ROM version of the terminal device is generated, a private directory thirdapp is created in the system partition, which holds all third party APK programs.
And then, realizing an Android service program APK (Android Thidap), wherein the APK automatically runs after the Android system is successfully started, scans/system/third directory, and installs the application programs in the directory one by one. The method specifically comprises the following steps:
and S1, monitoring a message that the system is successfully started, and carrying out the next step if the system is successfully started.
S2, traversing files in the system/thirdapp directory, judging whether the files are APK files or not, and if the files exist, then carrying out the next step; if not, the process is finished.
S3, analyzing the APK file, judging whether the APK is installed in the current system, if so, returning to S2 and traversing the next APK file; if not, the next step is carried out.
And S4, calling a system installation interface to install the APK, and in the system installation process, copying the so library file to the corresponding app-lib directory.
By the method for installing the application program, provided by the embodiment of the invention, all library files of the application program can be automatically placed under the directory corresponding to the application program in the data partition when the system is started, and the manual operation process is eliminated. Meanwhile, different application programs correspond to different user partition directories, and corresponding library files can be placed at different positions, so that the problem of conflict caused by duplicate names of the library files is effectively solved.
Example four:
based on the service handling method, the invention provides terminal equipment. Fig. 4 shows a schematic diagram of a possible structure of a terminal device according to the present invention. Specifically, the terminal device 50 includes: an acquisition unit 501, a library file installation unit 502, wherein:
an obtaining unit 501, configured to obtain an APK android installation package file of an application program in a system partition, where the APK file includes a library file of the application program;
a library file installing unit 502, configured to, after the obtaining unit 501 obtains the APK file, store the library file of the application program into a user directory corresponding to the application program in the user partition, so that the library file of the application program in the user directory is loaded through a general interface when the application program runs.
In one implementation, the APK file is stored under an application installation directory in a system partition; the terminal device 50 further includes: an application installation unit 503;
an obtaining unit 501, configured to scan an application installation directory in a system partition by using a PackageManagerServer package management service program, and obtain an APK file;
an application installation unit 503, configured to determine application information according to the APK file before the library file installation unit 502 stores the library file of the application program in the user directory corresponding to the application program in the user partition; after determining that the application information does not exist in the package management service program, saving the application information to the package management service program;
the library file installing unit 502 is specifically configured to, after the application installing unit 503 determines that the package management service program does not have the application program information, save the library file of the application program into a user directory corresponding to the application program in the user partition.
Wherein, optionally, the library file installing unit 502 is further configured to: after the application installation unit 503 determines that the package management service program has application program information, it determines whether a user directory corresponding to the application program exists in the user partition, and whether a library file of the application program is stored in the user directory; after determining that the user directory corresponding to the application program does not exist in the user partition, establishing the user directory corresponding to the application program and storing the library file of the application program under the user directory corresponding to the application program in the user partition, and after determining that the user directory corresponding to the application program exists in the user partition and the user directory does not have the library file of the application program, storing the library file of the application program under the user directory corresponding to the application program in the user partition.
In another embodiment, the APK file is stored under a private directory in the system partition;
an obtaining unit 501, configured to scan a private directory by using a preset service program, and obtain an APK file;
a library file installation unit 502, specifically configured to invoke a system installation interface by using a preset service program and install an APK file into a user partition; wherein installing the APK file into the user partition comprises: and acquiring the library file of the application program contained in the APK file, and storing the library file of the application program into a user directory corresponding to the application program in the user partition.
Wherein, optionally, the terminal device 50 further includes: a start-up unit 504;
the starting unit 504 is configured to detect starting of the android operating system, and run a preset service program after determining that the starting of the android operating system is successful.
Since the terminal device in the embodiment of the present invention may be applied to implement the method embodiment, the technical effect obtained by the terminal device may also refer to the method embodiment, and the embodiment of the present invention is not described herein again.
In the case of an integrated unit, fig. 5 shows a possible structural diagram of the terminal device according to the above-described embodiment. The terminal device 60 includes: a processing module 601 and a communication module 602. The processing module 601 is used for controlling and managing the actions of the terminal device. The communication module 602 is used to support communication between the terminal device and other entity devices, and the terminal device 60 may further include a storage module 603 for storing program codes and data of the terminal device 60.
The Processing module 601 may be a Processor or a controller, and may be, for example, a Central Processing Unit (CPU), a general purpose Processor, a Digital Signal Processor (DSP), an Application-Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other Programmable logic device, a transistor logic device, a hardware component, or any combination thereof. Which may implement or perform the various illustrative logical blocks, modules, and circuits described in connection with the disclosure. The processor may also be a combination of computing functions, e.g., comprising one or more microprocessors, DSPs, and microprocessors, among others. The communication module 602 may be a transceiver, a transceiving circuit or a communication interface, etc. The storage module 603 may be a memory.
When the processing module 601 is a processor, the communication module 602 is a communication interface, and the storage module 603 is a memory, the terminal device according to the embodiment of the present invention may be the terminal device shown in fig. 6.
Referring to fig. 6, the terminal device 70 includes: a processor 701, a communication interface 702, a memory 703, and a bus 704. The communication interface 702, the processor 701, and the memory 703 are connected to each other by a bus 704; the bus 704 may be a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, or the like. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown in FIG. 6, but this does not indicate only one bus or one type of bus.
The steps of a method or algorithm described in connection with the disclosure herein may be embodied in hardware or in software instructions executed by a processor. An embodiment of the present invention further provides a storage medium, where the storage medium may include a memory, and is used to store computer software instructions for a terminal device, where the computer software instructions include program codes designed to execute the service handling method provided in the foregoing embodiment. Specifically, the software instructions may be composed of corresponding software modules, and the software modules may be stored in a Random Access Memory (RAM), a flash Memory, a Read Only Memory (ROM), an Erasable Programmable Read Only Memory (EPROM), an Electrically Erasable Programmable Read Only Memory (EEPROM), a register, a hard disk, a removable hard disk, a compact disc Read Only Memory (CD-ROM), or any other form of storage medium known in the art. An exemplary storage medium is coupled to the processor such the processor can read information from, and write information to, the storage medium. Of course, the storage medium may also be integral to the processor. The processor and the storage medium may reside in an ASIC. Additionally, the ASIC may reside in a core network interface device. Of course, the processor and the storage medium may reside as discrete components in a core network interface device.
The embodiment of the present invention further provides a computer program, where the computer program may be directly loaded into the memory and contains a software code, and the computer program is loaded and executed by the computer, so as to implement the service handling method provided in the foregoing embodiment.
Those skilled in the art will recognize that, in one or more of the examples described above, the functions described in this invention may be implemented in hardware, software, firmware, or any combination thereof. When implemented in software, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media includes both computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. A storage media may be any available media that can be accessed by a general purpose or special purpose computer.
The above-mentioned embodiments, objects, technical solutions and advantages of the present invention are further described in detail, it should be understood that the above-mentioned embodiments are only exemplary embodiments of the present invention, and are not intended to limit the scope of the present invention, and any modifications, equivalent substitutions, improvements and the like made on the basis of the technical solutions of the present invention should be included in the scope of the present invention.

Claims (10)

1. An installation method of an application program is applied to terminal equipment adopting an Android operating system, and is characterized by comprising the following steps:
acquiring an APK file of the application program in a system partition, wherein the APK file comprises a library file of the application program;
and storing the library file of the application program to a user directory corresponding to the application program in a user partition, so that the library file of the application program in the user directory is loaded through a general interface when the application program runs.
2. The installation method according to claim 1, wherein the APK file is stored under an application installation directory in the system partition;
the method for acquiring the APK file of the application program in the system partition specifically comprises the steps of scanning an application installation directory in the system partition by using a PackageManagerServer package management service program to acquire the APK file;
before the saving the library file of the application program to the user directory corresponding to the application program in the user partition, the method further includes:
determining application program information according to the APK file;
after determining that the application information does not exist in the package management service program, saving the application information to the package management service program;
the storing the library file of the application program to a user directory corresponding to the application program in a user partition specifically includes: and after determining that the application program information does not exist in the package management service program, saving the library file of the application program to a user directory corresponding to the application program in the user partition.
3. The installation method according to claim 2, wherein after determining that the application information exists in the package management service, the method further comprises:
judging whether a user directory corresponding to the application program exists in the user partition or not and whether a library file of the application program is stored in the user directory or not;
the storing the library file of the application program to a user directory corresponding to the application program in a user partition specifically includes:
after determining that the user directory corresponding to the application program does not exist in the user partition, establishing the user directory corresponding to the application program and saving the library file of the application program to the user directory corresponding to the application program in the user partition, and
and after determining that the user directory corresponding to the application program exists in the user partition and the user directory does not contain the library file of the application program, saving the library file of the application program to the user directory corresponding to the application program in the user partition.
4. The installation method according to claim 1, wherein the APK file is stored under a private directory in the system partition;
the acquiring the APK file of the application program in the system partition specifically includes: scanning the private directory by using a preset service program to acquire the APK file;
the storing the library file of the application program to a user directory corresponding to the application program in a user partition specifically includes: calling a system installation interface by using the preset service program and installing the APK file into the user partition; wherein installing the APK file into the user partition comprises: and acquiring the library file of the application program contained in the APK file, and storing the library file of the application program to a user directory corresponding to the application program in a user partition.
5. The method of installing as claimed in claim 4, wherein the method further comprises:
detecting the starting of the android operating system;
and after the android operating system is determined to be successfully started, running the preset service program.
6. The utility model provides a terminal equipment, terminal equipment adopts Android operating system, its characterized in that, terminal equipment includes:
the system comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring an APK file of an application program in a system partition, and the APK file comprises a library file of the application program;
and the library file installation unit is used for storing the library file of the application program to a user directory corresponding to the application program in a user partition after the acquisition unit acquires the APK file, so that the library file of the application program in the user directory is loaded through a general interface when the application program runs.
7. The terminal device of claim 6, wherein the APK file is stored under an application installation directory in the system partition; the terminal device further includes: an application installation unit;
the obtaining unit is specifically configured to scan an application installation directory in the system partition by using a PackageManagerServer package management service program, and obtain the APK file;
the application installation unit is used for determining application program information according to the APK file before the library file installation unit stores the library file of the application program into a user directory corresponding to the application program in a user partition; after determining that the application information does not exist in the package management service program, saving the application information to the package management service program;
the library file installation unit is specifically configured to, after the application installation unit determines that the application information does not exist in the package management service program, store the library file of the application program in a user directory corresponding to the application program in the user partition.
8. The terminal device according to claim 7, wherein the library file installing unit is further configured to:
after the application installation unit determines that the application information exists in the package management service program, judging whether a user directory corresponding to the application exists in the user partition and whether a library file of the application is stored in the user directory;
after determining that the user directory corresponding to the application program does not exist in the user partition, establishing the user directory corresponding to the application program and saving the library file of the application program to the user directory corresponding to the application program in the user partition, and
and after determining that the user directory corresponding to the application program exists in the user partition and the user directory does not contain the library file of the application program, saving the library file of the application program to the user directory corresponding to the application program in the user partition.
9. The terminal device of claim 6, wherein the APK file is stored under a private directory in the system partition;
the obtaining unit is specifically configured to scan the private directory by using a preset service program to obtain the APK file;
the library file installation unit is specifically configured to call a system installation interface by using the preset service program and install the APK file into the user partition; wherein installing the APK file into the user partition comprises: and acquiring the library file of the application program contained in the APK file, and storing the library file of the application program to a user directory corresponding to the application program in a user partition.
10. The terminal device according to claim 9, wherein the terminal device further comprises: a start unit;
the starting unit is used for detecting the starting of the android operating system and running the preset service program after the android operating system is determined to be started successfully.
CN201810434234.5A 2018-05-08 2018-05-08 Application program installation method and terminal equipment Active CN108595192B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810434234.5A CN108595192B (en) 2018-05-08 2018-05-08 Application program installation method and terminal equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810434234.5A CN108595192B (en) 2018-05-08 2018-05-08 Application program installation method and terminal equipment

Publications (2)

Publication Number Publication Date
CN108595192A CN108595192A (en) 2018-09-28
CN108595192B true CN108595192B (en) 2021-08-27

Family

ID=63636333

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810434234.5A Active CN108595192B (en) 2018-05-08 2018-05-08 Application program installation method and terminal equipment

Country Status (1)

Country Link
CN (1) CN108595192B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112115134A (en) * 2020-08-04 2020-12-22 北京金山云网络技术有限公司 Data storage method and device, electronic equipment and storage medium
CN113766059B (en) * 2021-11-09 2022-03-18 飞天诚信科技股份有限公司 Application program starting method, terminal device and computer readable storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1164476A2 (en) * 2000-06-08 2001-12-19 Sony Corporation Information processing and providing, communication systems and server
CN102521031A (en) * 2011-12-13 2012-06-27 华为终端有限公司 Management method of preset application programs of mobile terminal and mobile terminal
CN105867947A (en) * 2016-04-25 2016-08-17 青岛海信电器股份有限公司 Data processing method and device after upgrades of preset applications
CN106126289A (en) * 2016-06-27 2016-11-16 贵州万臻时代通讯技术有限公司 File loading method and mobile terminal are installed in a kind of application
CN106843921A (en) * 2016-12-13 2017-06-13 北京元心科技有限公司 Resource loading method and device
CN107911741A (en) * 2017-12-14 2018-04-13 深圳Tcl新技术有限公司 Free memory method for improving, smart television and computer-readable recording medium
CN107943490A (en) * 2017-11-16 2018-04-20 珠海市魅族科技有限公司 Using installation method, equipment, computer-readable recording medium and computer installation

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1164476A2 (en) * 2000-06-08 2001-12-19 Sony Corporation Information processing and providing, communication systems and server
CN102521031A (en) * 2011-12-13 2012-06-27 华为终端有限公司 Management method of preset application programs of mobile terminal and mobile terminal
CN105867947A (en) * 2016-04-25 2016-08-17 青岛海信电器股份有限公司 Data processing method and device after upgrades of preset applications
CN106126289A (en) * 2016-06-27 2016-11-16 贵州万臻时代通讯技术有限公司 File loading method and mobile terminal are installed in a kind of application
CN106843921A (en) * 2016-12-13 2017-06-13 北京元心科技有限公司 Resource loading method and device
CN107943490A (en) * 2017-11-16 2018-04-20 珠海市魅族科技有限公司 Using installation method, equipment, computer-readable recording medium and computer installation
CN107911741A (en) * 2017-12-14 2018-04-13 深圳Tcl新技术有限公司 Free memory method for improving, smart television and computer-readable recording medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
Android动态加载so文件(解决so文件冲突);陈利健;《CSDN:https://www.jianshu.com/p/9609e1fb8756》;20151125;1-10 *

Also Published As

Publication number Publication date
CN108595192A (en) 2018-09-28

Similar Documents

Publication Publication Date Title
RU2435200C2 (en) Fast booting operating system from off state
US20100235617A1 (en) System recovery method and embedded system with automatic recovery function
CN105867947A (en) Data processing method and device after upgrades of preset applications
US10019598B2 (en) Dynamic service discovery
WO2018099292A1 (en) Process management method and apparatus
CN111427596A (en) Software upgrading method and device and terminal equipment
CN108595192B (en) Application program installation method and terminal equipment
CN106293849B (en) application updating method and terminal
CN111694585A (en) Method, system, terminal and storage medium for replacing system partition file
CN110750280A (en) Application upgrading method and system based on Android platform and storage medium
CN110955885B (en) Data writing method and device
CN116880877A (en) Virtual machine enhancement tool upgrading method and device, computer equipment and storage medium
US20050289537A1 (en) System and method for installing software on a computing device
KR100640389B1 (en) Method for executing application in an apparatus having nand flash memory and the apparatus
CN113641389B (en) Software upgrading method, device and equipment based on OpenCPU
CN114969720A (en) Installation method and device of android application, storage medium and computer equipment
KR20070108646A (en) Method and terminal for managing of compression binary file
KR100775431B1 (en) Apparatus and Method for System Imbedded System and Firmware Updating Method Therein
WO2019157891A1 (en) Application installation method and application installer generating method
CN115167886B (en) Automatic adaptation method, device, storage medium and electronic equipment
KR100622148B1 (en) Method for booting of portable terminal
KR101384929B1 (en) Media scanning method and media scanning device for storage medium of user terminal
CN116400945B (en) Dynamic link library upgrading method, electronic equipment and storage medium
CN113722715B (en) Imported file checking method, checking system and computing equipment
CN108459879B (en) Method for preventing terminal from crashing and terminal

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