<meta http-equiv="Content-Type" content="text/html; charset=GB18030"><div>Hello Phil,</div><div>The math module build-in python use c modules , according to Python-3.7.2\setup.py , the math module information as below:</div><div><pre style="font-family: 新宋体; font-size: 8.4pt;">shared_math = <span style="color: rgb(0, 128, 128); font-weight: bold;">'Modules/_math.o'<br></span><span style="color: rgb(128, 128, 128); font-style: italic;"># complex math library functions<br></span>exts.append( Extension(<span style="color: rgb(0, 128, 128); font-weight: bold;">'cmath'</span>, [<span style="color: rgb(0, 128, 128); font-weight: bold;">'cmathmodule.c'</span>],<br>                       <span style="color: rgb(102, 0, 153);">extra_objects</span>=[shared_math],<br>                       <span style="color: rgb(102, 0, 153);">depends</span>=[<span style="color: rgb(0, 128, 128); font-weight: bold;">'_math.h'</span>, shared_math],<br>                       <span style="color: rgb(102, 0, 153);">libraries</span>=[<span style="color: rgb(0, 128, 128); font-weight: bold;">'m'</span>]) )<br><span style="color: rgb(128, 128, 128); font-style: italic;"># math library functions, e.g. sin()<br></span>exts.append( Extension(<span style="color: rgb(0, 128, 128); font-weight: bold;">'math'</span>,  [<span style="color: rgb(0, 128, 128); font-weight: bold;">'mathmodule.c'</span>],<br>                       <span style="color: rgb(102, 0, 153);">extra_objects</span>=[shared_math],<br>                       <span style="color: rgb(102, 0, 153);">depends</span>=[<span style="color: rgb(0, 128, 128); font-weight: bold;">'_math.h'</span>, shared_math],<br>                       <span style="color: rgb(102, 0, 153);">libraries</span>=[<span style="color: rgb(0, 128, 128); font-weight: bold;">'m'</span>]) )</pre></div><div><pre style="font-family: 新宋体; font-size: 8.4pt;"></pre><pre style="font-family: 新宋体; font-size: 8.4pt;"><div style="font-size: medium; white-space: normal;"><span style="font-family: Verdana; font-size: 14px;"><br></span></div><div style="font-size: medium; white-space: normal;"><span style="font-family: Verdana; font-size: 14px;">Can you tell me how to import the math module on windows via pyqtdeploy? thank you!</span></div><div style="font-size: medium; white-space: normal;"><br style="font-family: Verdana; font-size: 14px;"></div></pre></div><div><br></div><div><br></div><div><div><br></div><div><br></div><div style="font-size: 12px;font-family: Arial Narrow;padding:2px 0 2px 0;">------------------ Original ------------------</div><div style="font-size: 12px;background:#efefef;padding:8px;"><div><b>From:</b> "Phil Thompson"<phil@riverbankcomputing.com>;</div><div><b>Date:</b> Mon, Mar 16, 2020 03:55 PM</div><div><b>To:</b> "1004483092"<1004483092@qq.com>;<wbr></div><div><b>Cc:</b> "pyqt"<pyqt@riverbankcomputing.com>;<wbr></div><div><b>Subject:</b> Re: [PyQt] pyqtdeploy application on windows with math module</div></div><div><br></div>I have no idea what that DLL is. pyqtdeploy supports the standard Python <br>math module. If you do not have lots of experience building and <br>debugging C++ code on Windows then please use something else.<br><br>Phil<br><br>On 16/03/2020 03:37, 1004483092 wrote:<br>> Hello Phil,I build the demo on windows10 with VS2017 success according<br>> to the document , but when my python script include math module , the<br>> application can't import math module.The math module is<br>> api-ms-win-crt-math-l1-1-0.dll on windows , can you tell me how to<br>> import math module via pyqtdeploy?My scripyt as below:from<br>> PyQt5.QtCore import *<br>> from PyQt5.QtGui import *<br>> from PyQt5.QtWidgets import *<br>> import sys<br>> import mathclass Window(QWidget):<br>>     def __init__(self):<br>>         super().__init__()<br>>         self.setupUI()<br>> <br>>     def setupUI(self):<br>>         self.lb=QLabel(self)<br>>         self.lb.setText('Label')<br>>         self.lb.move(30,10)<br>> <br>>         self.btn = QPushButton('test',self)<br>>         self.btn.move(30,30)<br>> <br>>         self.cb = QComboBox(self)<br>>         self.cb.move(30,70)<br>>         self.cb.resize(200,30)<br>>         self.resize(30,80)<br>> <br>>         self.btn.clicked.connect(self.test_func)<br>> <br>>         self.setWindowTitle('test')<br>>         self.setGeometry(400, 400, 300, 300)    def test_func(self):<br>>      test1 = math.cos(30)        test2 = math.asinh(60)        test3 =<br>> math.exp(40.1)        test4 = math.expm1(5.23)        test5 =<br>> math.factorial(40)        test6 = math.isfinite(3.24)<br>> self.cb.addItems([f'{test1}', f'{test2}', f'{test3}', f'{test4}',<br>> f'{test5}', f'{test6}'])if __name__=='__main__':<br>>     app = QApplication(sys.argv)<br>>     window=Window()<br>>     window.show()<br>>     sys.exit(app.exec_())<br>> _______________________________________________<br>> PyQt mailing list    PyQt@riverbankcomputing.com<br>> https://www.riverbankcomputing.com/mailman/listinfo/pyqt<br><br></div>