changes to get the nntpTest building again on Linux

This commit is contained in:
sspitzer%netscape.com 1999-04-27 02:12:55 +00:00
Родитель f973c46a0f
Коммит e62445398f
4 изменённых файлов: 20 добавлений и 8 удалений

Просмотреть файл

@ -25,8 +25,7 @@ include $(DEPTH)/config/autoconf.mk
MODULE=nntp
LIBRARY_NAME=nntpTest
# DIRS = nntp
DIRS = newsParser
DIRS = nntp newsParser
EXPORTS = \
$(NULL)

Просмотреть файл

@ -122,11 +122,11 @@ nsresult newsTestDriver::RunDriver()
nsresult newsTestDriver::GetPath(nsFileSpec& aPathName)
{
/* eventually turn news://news.mozilla.org/netscape.public.mozilla.unix
into /tmp/mozillanews/news.mozilla.org/netscape.public.mozilla.unix
getting /tmp/mozillanews from the account manager (which gets it
into /u/sspitzer/mozillanews/news.mozilla.org/netscape.public.mozilla.unix
getting /u/sspitzer/mozillanews from the account manager (which gets it
from the prefs
*/
aPathName = "/tmp/mozillanews/news.mozilla.org/netscape.public.mozilla.unix";
aPathName = "/u/sspitzer/mozillanews/news.mcom.com.sbd/mcom.linux";
return NS_OK;
}

Просмотреть файл

@ -53,19 +53,22 @@ LIBS = \
-lmozdbm \
-lxp \
-lpref \
-ljs \
-lmozjs \
-lraptorbase \
-lgmbase$(MOZ_TOOLKIT) \
-lsecfree \
-lraptorhtml \
-lraptorhtmlpars \
-lraptorgfx \
-lexpat \
-lxmltok \
-lraptorgfx \
-ljsdom \
-ljsurl \
-limg \
-lpng \
-ljpeg \
-lmozutil \
-lmsgbaseutil \
$(ZLIB_LIBS) \
$(DIST)/lib/librdfbase_s.a \
$(NSPR_LIBS) \

Просмотреть файл

@ -62,12 +62,14 @@
#ifdef XP_PC
#define NETLIB_DLL "netlib.dll"
#define XPCOM_DLL "xpcom32.dll"
#define NEWS_DLL "msgnews.dll"
#else
#ifdef XP_MAC
#include "nsMacRepository.h"
#else
#define NETLIB_DLL "libnetlib.so"
#define XPCOM_DLL "libxpcom.so"
#define NEWS_DLL "libmsgnews.so"
#endif
#endif
@ -77,6 +79,7 @@
static NS_DEFINE_CID(kNetServiceCID, NS_NETSERVICE_CID);
static NS_DEFINE_CID(kEventQueueServiceCID, NS_EVENTQUEUESERVICE_CID);
static NS_DEFINE_CID(kNntpUrlCID, NS_NNTPURL_CID);
/////////////////////////////////////////////////////////////////////////////////
// Define default values to be used to drive the test
@ -218,8 +221,14 @@ nsNntpTestDriver::nsNntpTestDriver(nsINetService * pNetService,
void nsNntpTestDriver::InitializeProtocol(const char * urlString)
{
nsresult rv = NS_OK;
// this is called when we don't have a url nor a protocol instance yet...
NS_NewNntpUrl(&m_url, urlString);
rv = nsServiceManager::GetService(kNntpUrlCID,
nsINntpUrl::GetIID(),
(nsISupports**)&m_url);
if (NS_FAILED(rv)) return rv;
// now create a protocl instance...
m_nntpProtocol = new nsNNTPProtocol(m_url, m_transport);
m_protocolInitialized = PR_TRUE;
@ -655,6 +664,7 @@ int main()
nsComponentManager::RegisterComponent(kNetServiceCID, NULL, NULL, NETLIB_DLL, PR_FALSE, PR_FALSE);
nsComponentManager::RegisterComponent(kEventQueueServiceCID, NULL, NULL, XPCOM_DLL, PR_FALSE, PR_FALSE);
nsComponentManager::RegisterComponent(kNntpUrlCID, NULL, NULL, NEWS_DLL, PR_FALSE, PR_FALSE);
// Create the Event Queue for this thread...
nsIEventQueueService* pEventQService;