[Web] App: enable precompiled headers
- also remove a unused header
This commit is contained in:
@@ -22,7 +22,6 @@
|
||||
|
||||
#include "PreCompiled.h"
|
||||
#ifndef _PreComp_
|
||||
# include <climits>
|
||||
# include <sstream>
|
||||
#endif
|
||||
|
||||
@@ -68,13 +67,13 @@ public:
|
||||
add_varargs_method("startServer",&Module::startServer,
|
||||
"startServer(address=127.0.0.1,port=0) -- Start a server."
|
||||
);
|
||||
add_varargs_method("waitForConnection",&Module::waitForConnection,
|
||||
add_varargs_method("waitForConnection", &Module::waitForConnection,
|
||||
"waitForConnection(address=127.0.0.1,port=0,timeout=0)\n"
|
||||
"Start a server, wait for connection and close server.\n"
|
||||
"Its use is disadvised in a the GUI version, since it will\n"
|
||||
"stop responding until the function returns."
|
||||
);
|
||||
add_varargs_method("registerServerFirewall",&Module::registerServerFirewall,
|
||||
add_varargs_method("registerServerFirewall", &Module::registerServerFirewall,
|
||||
"registerServerFirewall(callable(string)) -- Register a firewall."
|
||||
);
|
||||
initialize("This module is the Web module."); // register with Python
|
||||
@@ -87,7 +86,7 @@ private:
|
||||
{
|
||||
const char* addr = "127.0.0.1";
|
||||
int port=0;
|
||||
if (!PyArg_ParseTuple(args.ptr(), "|si",&addr,&port))
|
||||
if (!PyArg_ParseTuple(args.ptr(), "|si", &addr, &port))
|
||||
throw Py::Exception();
|
||||
if (port > USHRT_MAX) {
|
||||
throw Py::OverflowError("port number is greater than maximum");
|
||||
|
||||
@@ -23,10 +23,15 @@ SET(Web_SRCS
|
||||
Server.h
|
||||
)
|
||||
|
||||
if(FREECAD_USE_PCH)
|
||||
add_definitions(-D_PreComp_)
|
||||
GET_MSVC_PRECOMPILED_SOURCE("PreCompiled.cpp" PCH_SRCS ${Web_SRCS})
|
||||
ADD_MSVC_PRECOMPILED_HEADER(Web PreCompiled.h PreCompiled.cpp PCH_SRCS)
|
||||
endif(FREECAD_USE_PCH)
|
||||
|
||||
add_library(Web SHARED ${Web_SRCS})
|
||||
target_link_libraries(Web ${Web_LIBS})
|
||||
|
||||
|
||||
SET_BIN_DIR(Web Web /Mod/Web)
|
||||
SET_PYTHON_PREFIX_SUFFIX(Web)
|
||||
|
||||
|
||||
@@ -20,5 +20,4 @@
|
||||
* *
|
||||
***************************************************************************/
|
||||
|
||||
|
||||
#include "PreCompiled.h"
|
||||
|
||||
@@ -28,7 +28,6 @@
|
||||
#ifdef _PreComp_
|
||||
|
||||
// standard
|
||||
#include <climits>
|
||||
#include <stdexcept>
|
||||
|
||||
// STL
|
||||
|
||||
@@ -22,8 +22,8 @@
|
||||
|
||||
#include "PreCompiled.h"
|
||||
#ifndef _PreComp_
|
||||
# include <stdexcept>
|
||||
# include <memory>
|
||||
# include <stdexcept>
|
||||
# include <QCoreApplication>
|
||||
# include <QTcpSocket>
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user