第29月第18天 mac evpp环境

1.boost

https://github.com/Orphis/boost-cmake/

2.evpp

brew install libevent

brew install glog

 

/usr/local/Cellar/glog/0.3.5_3/include
/usr/local/Cellar/gflags/2.2.2/include
/usr/local/Cellar/libevent/2.1.8/include


/usr/local/Cellar/glog/0.3.5_3/lib
/usr/local/Cellar/gflags/2.2.2/lib
/usr/local/Cellar/libevent/2.1.8/lib

 

https://github.com/Qihoo360/evpp/blob/master/docs/quick_start.md

 

 

curl "http://127.0.0.1:29099/echo" -d "Hello, world"

 

3.socket client

#!/usr/bin/python
# -*- coding: UTF-8 -*-
# 文件名:client.py

import socket               # 导入 socket 模块

s = socket.socket()         # 创建 socket 对象
host = "127.0.0.1" # 获取本地主机名
port = 9099                # 设置端口号

s.connect((host, port))
s.send("1111")
print s.recv(1024)
s.close()  

 

 

 

 

 

 

posted @ 2019-02-18 13:43  lianhuaren  阅读(281)  评论(0编辑  收藏  举报