-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathsetup.py
36 lines (22 loc) · 1.11 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#! /usr/bin/env python
# -*- coding: utf-8 -*-
import os
from distutils.command.build_py import build_py as _build_py
from distutils.core import setup, Extension
#class build_py(_build_py):
# def run(self):
# os.system('cp -rf server/mecloud.py /usr/local/bin/')
import distutils.core
#打包,解压,过程。
#打包:在MeCloud下面执行,python setup sdist,就会根据下面的setup进行打包的操作,会再Mecloud下面生成一个dist文件夹,里面有一个war包,就是打包好的文件包了。
#解压安装:把打好的包,进行解压,解压后的文件夹中有一个setup.py,执行python setup.py install就可以对解压后的包进行安装了。
version = "1.0"
distutils.core.setup(
name="mecloud",
version=version,
author="blinnnk",
package_dir={'mecloud': 'server'},
packages=["mecloud", "mecloud.api", "mecloud.helper", "mecloud.lib", "mecloud.model", "mecloud.constants"],
ext_modules=[Extension('mecloud.lib.crypto_string',sources = ['server/lib/crypto_string.cpp'],library_dirs = ['server/lib'])]
#cmdclass={'build_py': build_py}
)