Fix python build on windows
Patch from Gisle Vanem """ I tried to build this extension on Windows, but failed since ws2_32.lib is needed in libraries """
This commit is contained in:
parent
f3f031f94c
commit
5b3deec186
|
@ -20,9 +20,16 @@
|
||||||
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
||||||
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||||
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
|
|
||||||
|
import sys
|
||||||
from distutils.core import setup
|
from distutils.core import setup
|
||||||
from distutils.extension import Extension
|
from distutils.extension import Extension
|
||||||
|
|
||||||
|
if sys.platform == "win32":
|
||||||
|
LIBS = ['nghttp2_imp', 'ws2_32']
|
||||||
|
else:
|
||||||
|
LIBS = ['nghttp2']
|
||||||
|
|
||||||
setup(
|
setup(
|
||||||
name = 'python-nghttp2',
|
name = 'python-nghttp2',
|
||||||
description = 'Python HTTP/2 library on top of nghttp2',
|
description = 'Python HTTP/2 library on top of nghttp2',
|
||||||
|
@ -36,6 +43,6 @@ setup(
|
||||||
'@top_srcdir@/lib/includes',
|
'@top_srcdir@/lib/includes',
|
||||||
'@top_builddir@/lib/includes'],
|
'@top_builddir@/lib/includes'],
|
||||||
library_dirs=['@top_builddir@/lib/.libs'],
|
library_dirs=['@top_builddir@/lib/.libs'],
|
||||||
libraries=['nghttp2'])],
|
libraries=LIBS)],
|
||||||
long_description='TBD'
|
long_description='TBD'
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in New Issue