Minigui Development: ubuntu-14.04 Environment Transplant Minigui

Source: Internet
Author: User

development projects on the embedded platform using Minigui as a user interface development tools, in the spare part of the preparation of the ubuntu14.04 on a test environment, so that the code test is more convenient.

After a lot of days and years, encountered many problems, but finally ran through. As a before to Minigui completely do not understand the small white, really need to have a good groping.

Sum up:Minigui really is a pit! If it's not something that the project must have, I suggest that you don't have to.

Question: (1) Minigui officially provided by the library has been a few years ago, in the transplant process is prone to installation errors, pro-test!

(2) It is said that the official seems to be no longer maintained. So even if you encounter a bug, the estimate is not easy to solve.

1, build the development environment system: ubuntu-14.04.3 i686 Compiler: gcc-4.8.4, GNU make 3.81MiniGui resource download: Http://www.minigui.org/zhcn/download/MiniGui library version:  3.0.12 resource file: minigui-res-be-3.0.12.tar.gzlibminigui-gpl-3.0.12.tar.gzlibmgplus-1.2.4.tar.gzmg-samples-3.0.12.tar.gz 2. Compile and install Minigui (1) Install resource file Extract resource file and enter minigui-res-be-3.0.12 directory $./configure--prefix=/home/test/install/minigui/$ Make && make install (2) Unzip the resource file into the libminigui-gpl-3.0.12 directory $./configure--prefix=/home/test/install/minigui--enable-qvfbial=yes--enable-videoqvfb=yes$ make error: Png.c:28:17:fatal error:png.h:no such file or directory resolved: sudo apt-get install libpng12-dev$ make installed after installation is complete View installation directory $ ls minigui/etc include Lib share after installation, under the specified directory ~/install/minigui, generated the ETC include Lib share four folders, respectively, placed a configuration file, header file, Library files and resource files that need to be used in real-world development. (3) Install Minigui Library and header files to extract the resource files, enter the libmgplus-1.2.4 directory, configure:./configure--prefix=/home/test/install/miniguipkg_config_path=/home/test/install/minigui/lib/pkgconfig cppflags=-i/home/test/install/minigui/includeError: Agg_platform_support.cpp:30:28:fatal error:minigui/common.h:no such file or directory resolved: Set Minigui header directory, cppflags= -i/home/test/install/minigui/include Execute $ make && make install (4) Compile the sample file to extract the resource file and enter the mg-samples-3.0.12 directory. Configure--prefix=/home/test/install/miniguipkg_config_path=/home/test/install/minigui/lib/pkgconfig cppflags=-i/home/test/install/minigui/ IncludeRun the make command to compile. Error: Dlgdemo.c:40:27:fatal error:mgplus/mgplus.h: No file or directory resolved: Set Libmgplus header file directory, cppflags=-i/home/test/install/ Minigui/include Tip: No package ' Minigui ' found----run Configure is added Pkg_config_path=~/install/minigui/lib/pkgconfig ; Tip: Error:minigui/common.h----Run Configure is to increase cppflags=-i~/install/minigui/include; 3. Modify the configuration file in the installation directory of the ETC directory to produce the Minigui required configuration file minigui.cfg, copy the file to/etc directory, and modify some configuration information.
[system]# GAL engine and default options#gal_engine  =pc_xvfbgal_engine=  qvfbdefaultmode=800x600-16bpp# IAL engine#ial_engine=pc_xvfbial _engine=qvfbmdev=/dev/input/micemtype=imps2

Modify the default configuration to use the QVFB emulator to configure the resource file directory:

cursorpath=/home/test/install/minigui/share/minigui/res/cursor/

respath=/home/test/install/minigui/share/minigui/res/

Modify the cursor directory and source directory values to the actual installation directory and save the exit.

4. Install QVFB Simulator

Reference: http://www.cnblogs.com/hancq/p/5950382.html

5. Test and build the test environment, create directory HelloWorld include Lib, copy the header files and static library files from the installation directory.

$ tree

├──helloworld
│├──helloworld.c
│├──helloworld_res_cn.h
│├──helloworld_res_en.h
│├──helloworld_res_tw.h
│└──makefile
├──include
│├──mgplus
│└──minigui
└──lib
├──libmgplus.a
└──libminigui_ths.a

Write Makefile:

# Makefile forMinigui Test # author hancq#Date       .- the- -Pro_name=Helloworldminigui_dir=/home/test/share/workspace/test/Miniguicflags+= -I.cflags+ =-i$ (minigui_dir)/Includeldflags+ =-lmgplus-lminigui_ths-lpthread-lm-ldl-lpng-ljpeg-l$ (minigui_dir)/Lib. Phony:all cleanall:$ (pro_name) $ (pro_name): $ (pro_name). OGCC$ (CFLAGS) $ (pro_name). O-o [email protected] $ (ldflags)%.o:%. CGCC$ (CFLAGS)-C $^-o [email protected]clean:-RM-RF $ (pro_name) *.O

Copy the HelloWorld-related files from the SRC directory in the Minigui sample to the Helloword directory

$ ls helloworld*
HELLOWORLD.C helloworld_res_cn.h Helloworld_res_en.h helloworld_res_tw.h

Run the make command to compile the build HelloWorld executable, execute the QVFB in the background, execute the./helloworld, and it will work properly in the emulator.

The test was successful.

Other errors:

Error:./helloworld:error while loading shared libraries:libminigui_ths-3.0.so.12:cannot open shared object file:no such F Ile or Directory Resolution: compilation cannot find library file, need to add library and library file path error in compilation option: Kernel>initgui (step 4): Can Not start client (run Mginit first FIX: Run the client version of the process program, you need to run the server Mginit first. Error: Kernel>initgui:count not init mouse cursor! Kernel>initgui:init failure, please check your MiniGUI configuration or resource. Workaround: The resource file directory in the MiniGUI profile is not found and modified.

Minigui Development: ubuntu-14.04 Environment Transplant Minigui

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.