Removed PrintTransportAddOn.cpp from libprintutils.a.

Use kits/print/PrintTransportAddOn.cpp in transport add-ons.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32499 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Michael Pfeiffer 2009-08-18 18:56:21 +00:00
parent 39fff75391
commit b0678ed3e2
7 changed files with 6 additions and 97 deletions

View File

@ -4,6 +4,8 @@ SetSubDirSupportedPlatformsBeOSCompatible ;
UsePrivateHeaders print ;
SEARCH_SOURCE += [ FDirName $(HAIKU_TOP) src kits print ] ;
Addon Parallel\ Port :
ParallelTransport.cpp
PrintTransportAddOn.cpp

View File

@ -1,32 +0,0 @@
#include "PrintTransportAddOn.h"
// We don't support multiple instances of the same transport add-on
static BDataIO* gTransport = NULL;
extern "C" _EXPORT BDataIO *init_transport(BMessage *msg)
{
if (msg == NULL || gTransport != NULL)
return NULL;
const char *spool_path = msg->FindString("printer_file");
if (spool_path && *spool_path != '\0') {
BDirectory printer(spool_path);
if (printer.InitCheck() == B_OK) {
gTransport = instantiate_transport(&printer, msg);
return gTransport;
};
};
return NULL;
}
extern "C" _EXPORT void exit_transport()
{
if (gTransport) {
delete gTransport;
gTransport = NULL;
}
}

View File

@ -4,6 +4,8 @@ SetSubDirSupportedPlatformsBeOSCompatible ;
UsePrivateHeaders print ;
SEARCH_SOURCE += [ FDirName $(HAIKU_TOP) src kits print ] ;
Addon Serial\ Port :
SerialTransport.cpp
PrintTransportAddOn.cpp

View File

@ -1,32 +0,0 @@
#include "PrintTransportAddOn.h"
// We don't support multiple instances of the same transport add-on
static BDataIO* gTransport = NULL;
extern "C" _EXPORT BDataIO *init_transport(BMessage *msg)
{
if (msg == NULL || gTransport != NULL)
return NULL;
const char *spool_path = msg->FindString("printer_file");
if (spool_path && *spool_path != '\0') {
BDirectory printer(spool_path);
if (printer.InitCheck() == B_OK) {
gTransport = instantiate_transport(&printer, msg);
return gTransport;
};
};
return NULL;
}
extern "C" _EXPORT void exit_transport()
{
if (gTransport) {
delete gTransport;
gTransport = NULL;
}
}

View File

@ -4,6 +4,8 @@ SetSubDirSupportedPlatformsBeOSCompatible ;
UsePrivateHeaders print ;
SEARCH_SOURCE += [ FDirName $(HAIKU_TOP) src kits print ] ;
Addon USB\ Port :
USBTransport.cpp
PrintTransportAddOn.cpp

View File

@ -1,32 +0,0 @@
#include "PrintTransportAddOn.h"
// We don't support multiple instances of the same transport add-on
static BDataIO* gTransport = NULL;
extern "C" _EXPORT BDataIO *init_transport(BMessage *msg)
{
if (msg == NULL || gTransport != NULL)
return NULL;
const char *spool_path = msg->FindString("printer_file");
if (spool_path && *spool_path != '\0') {
BDirectory printer(spool_path);
if (printer.InitCheck() == B_OK) {
gTransport = instantiate_transport(&printer, msg);
return gTransport;
};
};
return NULL;
}
extern "C" _EXPORT void exit_transport()
{
if (gTransport) {
delete gTransport;
gTransport = NULL;
}
}

View File

@ -12,5 +12,4 @@ StaticLibrary libprintutils.a :
PicturePrinter.cpp
PrintTransport.cpp
PictureIterator.cpp
PrintTransportAddOn.cpp
;