How to compile LAN Messenger
============================
You need Qt (http://qt.nokia.com/) to compile.
I built LAN Messenger using Qt 4.8, so you probably need that or a
later version.
You also need OpenSSL (http://www.openssl.org/)
I used version 1.0.0.e, so you know what to get.
Please read the OpenSSL section for more information.
The application consists of two projects - lmc and lmcapp. lmcapp is
just an extension of the qtsingleapplication project released by the
Qt people. I have added a few functions to support multilanguage UI.
The main project is lmc which contains the entire application. I have
included the project files for both projects.
Extract both folders. Make sure the directory hierarchy is maintained.
"lmc" and "lmcapp" should be folders at same level. Make sure the
dependency paths of lmc are set to the correct locations. It depends
on lmcapp and openssl, in addition to the standard Qt libraries.
The code is identical for all platforms, but there are a few differences
in the way application is built and run on each platform. Please read
the platform specific notes to know more.
Note: I used Qt Creator IDE with gcc compiler on all platforms. If you
are using any other IDE and/or compiler and run into any issue, I can
only provide generic help.
Important: Its better if your project paths do not contain any white spaces.
Some tools do not work properly with paths containing spaces. Use paths that
do not have spaces to avoid headaches down the lane.
Saving project files to your dektop is a BAD idea.
Compiling/Installing OpenSSL
============================
If precompiled binary distribution of OpenSSL is available for your
platform, you can use it instead of building from source.
The steps for compiling OpenSSL varies depending on your platform.
The package that you get from OpenSSL website gives detailed instructions
on how to compile on all supported platforms. OpenSSL itself may need
additional software packages to compile depending on your system.
Make sure that OpenSSL is built as a shared library.
Windows
-------
Get the precompiled binary distribution of OpenSSL from
http://www.slproweb.com/products/Win32OpenSSL.html
This version of LAN Messenger was built with the package named
"Win32 OpenSSL v1.0.0e". Download the package and install to a folder
called "openssl" which should be at the same level as the folder "lmc".
While installing, make sure that the option to copy DLLs to the OpenSSL
binaries directory is selected in the Additional Tasks page.
Linux/X11
---------
Many Linux distributions come with pre-compiled OpenSSL packages. If your
system has one, you may be able to link the project to it. If your system
lacks the package, or if you are unable to link with it, you need to build
OpenSSL from source.
Specify the "shared" switch to ensure that OpenSSL is built as a shared
library.
Mac OS X
--------
Mac OS X ships with a binary package of OpenSSL, so there is not need to
compile. You can link the project with this package even if it is an older
version than the one found on OpenSSl web site.
Compiling LAN Messenger
=======================
Some custom scripts are used for automating part of the compilation and setup
of LAN Messenger. These scripts rely on an environment variable called
QTDIR that should contain the path where Qt libraries are installed. More
specifically, it should point to the parent folder of the bin and lib folders
where Qt binaries reside. Eg: C:\Qt\4.8.0 on Windows.
Refer PLATFORM_SPECIFIC.TXT for additional details about setting up the build
environment on respective platforms.
Compiling LAN Messenger on Windows
==================================
Its possible to compile using other build chains/IDEs, but its better
to stick to Qt Creator and gcc tool chain.
OpenSSL should be built/installed first. I recommend using a folder at
the same level as "lmc" folder as the OpenSSL folder.
Next build "lmcapp" project. All the files needed are present inside
lmcapp\src folder. This project should be built as a shared library.
The outputs of this project are lmcapp.dll and lmcapp.a, which will be
created in lmcapp\lib folder. The .dll file should be moved to
lmcapp\bin and the .a file should be left in lmcapp\lib. In case of
debug build, the output files will be lmcappd.dll and lmcappd.a
Finally build "lmc" project. This project references both OpenSSL and
lmcapp, so the correct paths to headers and libraries should be set
first.
The headers of lmcapp should be in lmcapp\include
The libraries of lmcapp should be in lmcapp\lib
The headers of OpenSSL should be in openssl\include
The libraries of OpenSSL should be in openssl\lib
Note: OpenSSL paths may be different depending on how it was built/installed
in your system.
Once you have built lmc, run the "buildwin32.bat" batch file found in
the src\scripts folder. This script compiles the translation files, builds
the resources into a separate binary file and copies the application
dependencies to the output folder. The path of output directory should
be passed as a parameter for this script. The script depends on the QTDIR
environment variable, so make sure it is set correctly. You can probably
add the execution of this script as a custom build step in your IDE. That
way it will be automatically called every time you build the project.
Compiling LAN Messenger on X11/Linux
====================================
OpenSSL should be built first. I recommend using a folder at the same
level as "lmc" folder as the OpenSSL folder.
Next build "lmcapp" project. All the files needed are present inside
lmcapp/src folder. This project should be built as a shared library.
The outputs of this project is liblmcapp.1.0.0.so, which will be
created in lmcapp/lib folder.
Finally build "lmc" project. This project references both OpenSSL and
lmcapp, so the correct paths to headers and libraries should be set
first.
The headers of lmcapp should be in lmcapp/include
The libraries of lmcapp should be in lmcapp/lib
The headers of OpenSSL should be in openssl/include
The libraries of OpenSSL should be in openssl/lib
Note: OpenSSL paths may be different depending on how it was built/installed
in your system.
Once you have built lmc, run the "buildx11" shell script found in the
src/scripts folder. This script performs the same actions as its Windows
counterpart. The QTDIR variable defined in the script should contain the
correct path to Qt libraries. You can add the execution of this script as
a custom build step to automate the whole process. If you get an error
while executing the script, edit the script to make sure that the Qt
plugins path in the script is correct.
Compiling LAN Messenger on Mac OS X
===================================
Build "lmcapp" project. All the files needed are present inside
lmcapp/src folder. This project should be built as a shared library.
The outputs of this project is liblmcapp.1.0.0.dylib, which will be
created in lmcapp/lib folder.
Finally build "lmc" project. This project references lmcapp, so the
correct paths to headers and libraries should be set first.
The headers of lmcapp should be in lmcapp/include
The libraries of lmcapp should be in lmcapp/lib
Note: There is no need to link to OpenSSL since it is present as a system
library on Mac OS X.
Once you have built lmc, run the "buildmacos" shell script found in the
src/scripts folder. This script performs the same actions as its Windows
counterpart. The script depends on the QTDIR environment variable, so make
sure it is set correctly. You can add the execution of this script as a
custom build step to automate the whole process. If you get an error while
executing the script, edit the script to make sure that the Qt plugins
path in the script is correct.
Note: On Mac O
没有合适的资源?快使用搜索试试~ 我知道了~
一个跨平台的聊天工具
共428个文件
png:153个
h:54个
cpp:48个
需积分: 13 9 下载量 200 浏览量
2018-12-09
14:05:19
上传
评论 1
收藏 2.09MB ZIP 举报
温馨提示
这是一个类似飞秋的局域网聊天工具,跨平台,可运行在windows和linux上,基于QT实现
资源推荐
资源详情
资源评论
收起资源包目录
一个跨平台的聊天工具 (428个子文件)
addlicense 640B
Applications 294KB
buildwin32.bat 2KB
setup.bat 132B
banner.bmp 51KB
header.bmp 10KB
header-r.bmp 10KB
buildmacos 1KB
buildx11 2KB
control 352B
control~ 352B
mainwindow.cpp 39KB
lmc.cpp 34KB
filemessagingproc.cpp 29KB
messagelog.cpp 29KB
settingsdialog.cpp 29KB
chatroomwindow.cpp 27KB
chatwindow.cpp 26KB
messaging.cpp 16KB
settings.cpp 14KB
network.cpp 14KB
transferwindow.cpp 13KB
broadcastwindow.cpp 13KB
usertreewidget.cpp 13KB
messagingproc.cpp 13KB
tcpnetwork.cpp 12KB
qtsingleapplication.cpp 12KB
netstreamer.cpp 11KB
filemodelview.cpp 10KB
qtlocalpeer.cpp 7KB
qtlockedfile_win.cpp 7KB
udpnetwork.cpp 7KB
qtlockedfile.cpp 6KB
qtsinglecoreapplication.cpp 6KB
shared.cpp 5KB
crypto.cpp 5KB
history.cpp 5KB
userselectdialog.cpp 5KB
historywindow.cpp 5KB
updatewindow.cpp 5KB
xmlmessage.cpp 4KB
main.cpp 4KB
theme.cpp 4KB
imagepicker.cpp 4KB
helpwindow.cpp 4KB
strings.cpp 4KB
qtlockedfile_unix.cpp 4KB
application.cpp 4KB
userinfowindow.cpp 3KB
webnetwork.cpp 3KB
transferlistview.cpp 3KB
chathelper.cpp 3KB
subcontrols.cpp 3KB
aboutdialog.cpp 3KB
soundplayer.cpp 2KB
message.cpp 2KB
trace.cpp 2KB
imagepickeraction.cpp 2KB
datagram.cpp 2KB
createdisk 1KB
main.css 5KB
main.css 4KB
main.css 4KB
main.css 3KB
main.css 3KB
lmc.desktop 460B
angry.gif 1KB
crying.gif 1KB
surprised.gif 1KB
embarrassed.gif 1KB
wink.gif 1KB
e-mail.gif 1KB
clock.gif 1KB
open_mouthed.gif 1KB
tongue_out.gif 1KB
hot.gif 1KB
confused.gif 1KB
disappointed.gif 1KB
smile.gif 1KB
sad.gif 1KB
birthday_cake.gif 1KB
camera.gif 1KB
angel.gif 1KB
filmstrip.gif 1KB
gift_with_bow.gif 1KB
light_bulb.gif 1KB
left_hug.gif 1KB
messenger.gif 1KB
broken_heart.gif 1KB
star.gif 1KB
cat_face.gif 1KB
dog_face.gif 1KB
red_heart.gif 1KB
sleeping_half-moon.gif 1KB
red_lips.gif 1KB
note.gif 1KB
coffee.gif 1KB
wilted_rose.gif 1018B
telephone_receiver.gif 1007B
red_rose.gif 611B
共 428 条
- 1
- 2
- 3
- 4
- 5
资源评论
loveabcc
- 粉丝: 2
- 资源: 22
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功