1diff -urwN nxcomp-orig/configure.ac nxcomp/configure.ac 2--- nxcomp-orig/configure.ac 2012-02-20 18:19:57.606376552 +0100 3+++ nxcomp/configure.ac 2012-02-20 22:58:38.504797724 +0100 4@@ -52,6 +52,15 @@ 5 ;; 6 esac 7 8+dnl set default visibility 9+fe_CHECK_FLAG([C],[CFLAGS],[-fvisibility=hidden]) 10+fe_CHECK_FLAG([C],[CFLAGS],[-fvisibility-inlines-hidden]) 11+fe_CHECK_FLAG([C++],[CXXFLAGS],[-fvisibility=hidden]) 12+fe_CHECK_FLAG([C++],[CXXFLAGS],[-fvisibility-inlines-hidden]) 13+CXXFLAGS="$CXXFLAGS $ac_checked_CXXFLAGS" 14+CFLAGS="$CFLAGS $ac_checked_CFLAGS" 15+AC_DEFINE_UNQUOTED([NXCOMP_DLL_BUILDING],[1],[Define, if building shared lib]) 16+ 17 dnl Special handling if nx-X11 exists 18 if test -d "../nx-X11/include" ; then 19 CXXFLAGS="$CXXFLAGS -I../nx-X11/exports/include" 20diff -urwN nxcomp-orig/configure.in nxcomp/configure.in 21--- nxcomp-orig/configure.in 2010-03-01 18:18:59.000000000 +0100 22+++ nxcomp/configure.in 1970-01-01 01:00:00.000000000 +0100 23@@ -1,393 +0,0 @@ 24-dnl Process this file with autoconf to produce a configure script. 25- 26-dnl Prolog 27- 28-AC_INIT(NX.h) 29-AC_PREREQ(2.13) 30- 31-dnl Set our default compilation flags. 32- 33-CXXFLAGS="-O3 -fno-rtti -fno-exceptions" 34-CFLAGS="-O3" 35- 36-dnl Reset default linking directives. 37- 38-LIBSTATIC="" 39-LIBSHARED="" 40- 41-dnl Prefer headers and libraries from nx-X11, if present. 42- 43-if test -d "../nx-X11/include" ; then 44- CXXFLAGS="$CXXFLAGS -I../nx-X11/exports/include" 45- CFLAGS="$CFLAGS -I../nx-X11/exports/include" 46- LIBS="$LIBS -L../nx-X11/exports/lib" 47-fi 48- 49-dnl Check whether --with-ipaq was given. 50- 51-if test "${with_ipaq}" = yes; then 52- echo -e "enabling IPAQ configuration" 53- CXX="arm-linux-c++" 54- CC="arm-linux-gcc" 55- unset ac_cv_prog_armcxx 56- unset ac_cv_prog_armcc 57- unset ac_cv_prog_CXXCPP 58- AC_CHECK_PROG([armcxx],["$CXX"],[yes],[no],[$PATH]) 59- AC_CHECK_PROG([armcc],["$CC"],[yes],[no],[$PATH]) 60- if test $armcxx = "yes" && test $armcc = "yes" ; then 61- ac_cv_prog_CXX="$CXX" 62- ac_cv_prog_CC="$CC" 63- else 64- AC_MSG_ERROR(Installation or configuration problem. Cannot find compiler for arm-linux.) 65- fi 66-else 67- unset ac_cv_prog_CXX 68- unset ac_cv_prog_CC 69- unset ac_cv_prog_CXXCPP 70-fi 71- 72-dnl Check for programs. 73- 74-AC_PROG_CXX 75-AC_PROG_CC 76-AC_LANG_CPLUSPLUS 77- 78-dnl Check whether option -Wno-deprecated 79-dnl is needed by GCC compiler. 80- 81-AC_MSG_CHECKING([whether compiler needs -Wno-deprecated]) 82-gcc_version=`${CC} --version | grep 'gcc (GCC) [[3-4]].' | head -n 1` 83-case "${gcc_version}" in 84- gcc*) 85- AC_MSG_RESULT([yes]) 86- CXXFLAGS="$CXXFLAGS -Wno-deprecated" 87- ;; 88- 89- *) 90- AC_MSG_RESULT([no]) 91- ;; 92-esac 93- 94-AC_MSG_CHECKING([whether compiler accepts -Wmissing-declarations]) 95-gcc_version=`${CC} --version | grep 'gcc (GCC) [[3-4]].' | head -n 1` 96-case "${gcc_version}" in 97- gcc*) 98- AC_MSG_RESULT([no]) 99- ;; 100- 101- *) 102- AC_MSG_RESULT([yes]) 103- CXXFLAGS="$CXXFLAGS -Wmissing-declarations" 104- ;; 105-esac 106- 107-dnl Check for BSD compatible install. 108- 109-AC_PROG_INSTALL 110- 111-dnl Check for extra header files. 112- 113-AC_PATH_XTRA 114- 115-dnl Custom addition. 116- 117-ac_help="$ac_help 118- --with-symbols add the -g flag to produce the debug symbols 119- --with-use-malloc add the __USE_MALLOC flag to avoid the STL allocators 120- --with-info define INFO at compile time to get basic log output 121- --with-valgrind clean up allocated buffers to avoid valgrind warnings 122- --with-version use this version for produced libraries 123- 124- --with-static-png enable static linking of PNG library 125- --with-static-jpeg enable static linking of JPEG library 126- --with-static-z enable static linking of Z library" 127- 128-dnl Check to see if we're running under Cygwin32. 129- 130-AC_DEFUN(nxconf_CYGWIN32, 131-[AC_CACHE_CHECK(for Cygwin32 environment, nxconf_cv_cygwin32, 132-[AC_TRY_COMPILE(,[return __CYGWIN32__;], 133-nxconf_cv_cygwin32=yes, nxconf_cv_cygwin32=no) 134-rm -f conftest*]) 135-CYGWIN32= 136-test "$nxconf_cv_cygwin32" = yes && CYGWIN32=yes]) 137-nxconf_CYGWIN32 138- 139-dnl Check whether we're building on a AMD64. 140- 141-AC_DEFUN(nxconf_AMD64, 142-[AC_CACHE_CHECK(for Amd64 environment, nxconf_cv_amd64, 143-[AC_TRY_COMPILE(,[return (__amd64__ || __x86_64__);], 144-nxconf_cv_amd64=yes, nxconf_cv_amd64=no) 145-rm -f conftest*]) 146-AMD64= 147-test "$nxconf_cv_amd64" = yes && AMD64=yes]) 148-nxconf_AMD64 149- 150-dnl Check for Darwin environment. 151- 152-AC_DEFUN(nxconf_DARWIN, 153-[AC_CACHE_CHECK(for Darwin environment, nxconf_cv_darwin, 154-[AC_TRY_COMPILE(,[return __APPLE__;], 155-nxconf_cv_darwin=yes, nxconf_cv_darwin=no) 156-rm -f conftest*]) 157-DARWIN= 158-test "$nxconf_cv_darwin" = yes && DARWIN=yes]) 159-nxconf_DARWIN 160- 161-dnl Check to see if we're running under Solaris. 162- 163-AC_DEFUN(nxconf_SUN, 164-[AC_CACHE_CHECK(for Solaris environment, nxconf_cv_sun, 165-[AC_TRY_COMPILE(,[return __sun;], 166-nxconf_cv_sun=yes, nxconf_cv_sun=no) 167-rm -f conftest*]) 168-SUN= 169-test "$nxconf_cv_sun" = yes && SUN=yes]) 170-nxconf_SUN 171- 172-dnl Check to see if we're running under FreeBSD. 173- 174-AC_DEFUN(nxconf_FreeBSD, 175-[AC_CACHE_CHECK(for FreeBSD environment, nxconf_cv_freebsd, 176-[AC_TRY_COMPILE(,[return __FreeBSD__;], 177-nxconf_cv_freebsd=yes, nxconf_cv_freebsd=no) 178-rm -f conftest*]) 179-FreeBSD= 180-test "$nxconf_cv_freebsd" = yes && FreeBSD=yes]) 181-nxconf_FreeBSD 182- 183-dnl Build PIC libraries. 184- 185-if test "$CYGWIN32" != yes -a "$DARWIN" != yes; then 186- CXXFLAGS="$CXXFLAGS -fPIC" 187- CFLAGS="$CFLAGS -fPIC" 188-fi 189- 190-dnl Solaris requires the socket and gcc_s libs explicitly linked. 191-dnl Note also that headers from default /usr/openwin/include/X11 192-dnl cause a warning due to pragma in Xmd.h. 193- 194-if test "$SUN" = yes; then 195- LIBS="$LIBS -L/usr/sfw/lib -lsocket " 196- CXXFLAGS="$CXXFLAGS -I/usr/sfw/include" 197- CFLAGS="$CFLAGS -I/usr/sfw/include" 198-fi 199- 200-dnl On FreeBSD search libraries and includes under /usr/local. 201- 202-if test "$FreeBSD" = yes; then 203- LIBS="$LIBS -L/usr/local/lib" 204- CXXFLAGS="$CXXFLAGS -I/usr/local/include" 205- CFLAGS="$CFLAGS -I/usr/local/include" 206-fi 207- 208-dnl Under Darwin we don't have support for -soname option and 209-dnl we need the -bundle flag. Under Solaris, instead, we need 210-dnl the options -G -h. 211- 212-if test "$DARWIN" = yes; then 213- LDFLAGS="$LDFLAGS -bundle" 214-elif test "$SUN" = yes; then 215- LDFLAGS="$LDFLAGS -G -h \$(LIBLOAD)" 216-else 217- LDFLAGS="$LDFLAGS -Wl,-soname,\$(LIBLOAD)" 218-fi 219- 220-dnl Check to see if in_addr_t is defined. 221-dnl Could use a specific configure test. 222- 223-AC_DEFUN(nxconf_INADDRT, 224-[AC_CACHE_CHECK(for in_addr_t, nxconf_cv_inaddrt, 225-[AC_TRY_COMPILE([#include <netinet/in.h>],[in_addr_t t; t = 1; return t;], 226-nxconf_cv_inaddrt=yes, nxconf_cv_inaddrt=no) 227-rm -f conftest*]) 228-INADDRT= 229-test "$nxconf_cv_inaddrt" = yes && INADDRT=yes]) 230-nxconf_INADDRT 231- 232-dnl If in_addr_t is not defined use unsigned int. 233- 234-if test "$INADDRT" != yes ; then 235- echo -e "using unsigned int for type in_addr_t" 236- CXXFLAGS="$CXXFLAGS -DIN_ADDR_T=unsigned" 237- CFLAGS="$CFLAGS -DIN_ADDR_T=unsigned" 238-else 239- CXXFLAGS="$CXXFLAGS -DIN_ADDR_T=in_addr_t" 240- CFLAGS="$CFLAGS -DIN_ADDR_T=in_addr_t" 241-fi 242- 243-dnl Check whether --with-version was given. 244- 245-AC_SUBST(LIBVERSION) 246-AC_SUBST(VERSION) 247-if test "${with_version}" = yes; then 248- VERSION=${ac_option} 249-else 250- VERSION=`cat VERSION` 251-fi 252-echo -e "compiling version ${VERSION}" 253- 254-LIBVERSION=`echo ${VERSION} | cut -d '.' -f 1` 255- 256-CXXFLAGS="$CXXFLAGS -DVERSION=\\\"${VERSION}\\\"" 257-CFLAGS="$CFLAGS -DVERSION=\\\"${VERSION}\\\"" 258- 259-dnl Check whether --with-static-png was given and 260-dnl add -lpng or libpng.a to linking. 261- 262-if test "${with_static_png}" = yes; then 263- echo -e "enabling static linking of PNG library" 264- if test "$SUN" = yes && test -f "/usr/sfw/lib/libpng.a"; then 265- LIBSTATIC="$LIBSTATIC /usr/sfw/lib/libpng.a" 266- else 267- if test -f "/usr/lib/libpng.a" ; then 268- LIBSTATIC="$LIBSTATIC /usr/lib/libpng.a" 269- else 270- if test -f "/usr/local/lib/libpng.a" ; then 271- echo -e "assuming libpng.a in /usr/local/lib" 272- LIBSTATIC="$LIBSTATIC /usr/local/lib/libpng.a" 273- else 274- echo -e "Warning: assuming libpng.a in the local path" 275- LIBSTATIC="$LIBSTATIC libpng.a" 276- fi 277- fi 278- fi 279-else 280- echo -e "enabling dynamic linking of PNG library" 281- LIBSHARED="$LIBSHARED -lpng" 282-fi 283- 284-dnl Check whether --with-static-jpeg was given and 285-dnl add -ljpeg or libjpeg.a to linking. 286- 287-if test "${with_static_jpeg}" = yes; then 288- echo -e "enabling static linking of JPEG library" 289- if test "$SUN" = yes && test -f "/usr/sfw/lib/libjpeg.a"; then 290- LIBSTATIC="$LIBSTATIC /usr/sfw/lib/libjpeg.a" 291- else 292- if test -f "/usr/lib/libjpeg.a" ; then 293- LIBSTATIC="$LIBSTATIC /usr/lib/libjpeg.a" 294- else 295- if test -f "/usr/local/lib/libjpeg.a" ; then 296- echo -e "assuming libjpeg.a in /usr/local/lib" 297- LIBSTATIC="$LIBSTATIC /usr/local/lib/libjpeg.a" 298- else 299- echo -e "Warning: assuming libjpeg.a in the local path" 300- LIBSTATIC="$LIBSTATIC libjpeg.a" 301- fi 302- fi 303- fi 304-else 305- echo -e "enabling dynamic linking of JPEG library" 306- LIBSHARED="$LIBSHARED -ljpeg" 307-fi 308- 309-dnl Check whether --with-static-z was given and 310-dnl add -lz or libz.a to linking. 311- 312-if test "${with_static_z}" = yes; then 313- echo -e "enabling static linking of Z library" 314- if test "$SUN" = yes && test -f "/usr/sfw/lib/libz.a"; then 315- LIBSTATIC="$LIBSTATIC /usr/sfw/lib/libz.a" 316- else 317- if test -f "/usr/lib/libz.a" ; then 318- LIBSTATIC="$LIBSTATIC /usr/lib/libz.a" 319- else 320- if test -f "/usr/local/lib/libz.a" ; then 321- echo -e "assuming libz.a in /usr/local/lib" 322- LIBSTATIC="$LIBSTATIC /usr/local/lib/libz.a" 323- else 324- echo -e "Warning: assuming libz.a in the local path" 325- LIBSTATIC="$LIBSTATIC libz.a" 326- fi 327- fi 328- fi 329-else 330- echo -e "enabling dynamic linking of Z library" 331- LIBSHARED="$LIBSHARED -lz" 332-fi 333- 334-dnl Finally compose the LIB variable. 335- 336-if test "$DARWIN" = yes ; then 337- LIBS="$LIBS $LIBSTATIC $LIBSHARED" 338-elif test "$SUN" = yes ; then 339- LIBS="$LIBS $LIBSTATIC $LIBSHARED" 340-else 341- LIBS="$LIBS $LIBSTATIC -shared $LIBSHARED" 342-fi 343- 344-dnl Check whether --with-symbols or --without-symbols was 345-dnl given and set the required optimization level. 346- 347-if test "${with_symbols}" = yes; then 348- echo -e "enabling production of debug symbols" 349- CXXFLAGS="-g $CXXFLAGS" 350- CFLAGS="-g $CFLAGS" 351-else 352- echo -e "disabling production of debug symbols" 353-fi 354- 355-dnl Check whether --with-use-malloc or --without-use-malloc 356-dnl was given. 357- 358-if test "${with_use_malloc}" = yes; then 359- echo -e "disabling use of the STL allocators" 360- CXXFLAGS="$CXXFLAGS -D__USE_MALLOC" 361-else 362- echo -e "enabling use of the STL allocators" 363-fi 364- 365-dnl Check whether --with-info or --without-info was given. 366- 367-if test "${with_info}" = yes; then 368- echo -e "enabling info output in the log file" 369- CXXFLAGS="$CXXFLAGS -DINFO" 370- CFLAGS="$CFLAGS -DINFO" 371-else 372- echo -e "disabling info output in the log file" 373-fi 374- 375-dnl Check whether --with-valgrind or --without-valgrind was given. 376- 377-if test "${with_valgrind}" = yes; then 378- echo -e "enabling valgrind memory checker workarounds" 379- CXXFLAGS="$CXXFLAGS -DVALGRIND" 380- CFLAGS="$CFLAGS -DVALGRIND" 381-else 382- echo -e "disabling valgrind memory checker workarounds" 383-fi 384- 385-dnl Find makedepend somewhere. 386- 387-AC_SUBST(MAKEDEPEND) 388- 389-if test -x "../nx-X11/config/makedepend/makedepend" ; then 390- MAKEDEPEND=../nx-X11/config/makedepend/makedepend 391-else 392- if test -x "/usr/X11R6/bin/makedepend" ; then 393- MAKEDEPEND=/usr/X11R6/bin/makedepend 394- else 395- if test -x "/usr/openwin/bin/makedepend" ; then 396- MAKEDEPEND=/usr/openwin/bin/makedepend 397- else 398- MAKEDEPEND=/usr/bin/makedepend 399- fi 400- fi 401-fi 402- 403-dnl Determine what to build based on the platform. 404-dnl Override the LIBS settings on Cygwin32 so that 405-dnl we always link with the exact set of libraries. 406- 407-AC_SUBST(ALL) 408- 409-if test "$CYGWIN32" = yes; then 410- ALL="\$(LIBCYGARCHIVE) \$(LIBCYGSHARED) \$(LIBARCHIVE)" 411- LIBS="-lstdc++ -lpng -ljpeg -lz" 412-else 413- ALL="\$(LIBFULL) \$(LIBLOAD) \$(LIBSHARED) \$(LIBARCHIVE)" 414-fi 415- 416-AC_OUTPUT(Makefile) 417diff -urwN nxcomp-orig/NX.h nxcomp/NX.h 418--- nxcomp-orig/NX.h 2012-02-20 18:20:24.559375350 +0100 419+++ nxcomp/NX.h 2012-02-20 22:57:28.518800840 +0100 420@@ -18,6 +18,29 @@ 421 #ifndef NX_H 422 #define NX_H 423 424+#if defined _WIN32 || defined __CYGWIN__ 425+# define NXCOMP_DLL_IMPORT __declspec(dllimport) 426+# define NXCOMP_DLL_EXPORT __declspec(dllexport) 427+# define NXCOMP_DLL_LOCAL 428+#else 429+# if __GNUC__ >= 4 430+# define NXCOMP_DLL_IMPORT __attribute__ ((visibility ("default"))) 431+# define NXCOMP_DLL_EXPORT __attribute__ ((visibility ("default"))) 432+# define NXCOMP_DLL_LOCAL __attribute__ ((visibility ("hidden"))) 433+# else 434+# define NXCOMP_DLL_IMPORT 435+# define NXCOMP_DLL_EXPORT 436+# define NXCOMP_DLL_LOCAL 437+# endif 438+#endif 439+ 440+#ifdef NXCOMP_DLL_BUILDING 441+# define NXCOMP_API NXCOMP_DLL_EXPORT 442+#else 443+# define NXCOMP_API NXCOMP_DLL_IMPORT 444+#endif 445+#define NXCOMP_LOCAL NXCOMP_DLL_LOCAL 446+ 447 #ifdef __cplusplus 448 extern "C" { 449 #endif 450@@ -83,7 +106,7 @@ 451 * done after having created a pair of connected sockets. 452 */ 453 454-extern int NXTransCreate(int fd, int mode, const char *options); 455+extern NXCOMP_API int NXTransCreate(int fd, int mode, const char *options); 456 457 /* 458 * Tell the proxy to use the second descriptor as its own end of 459@@ -93,7 +116,7 @@ 460 * possible, will trigger the use of the memory-to-memory transport. 461 */ 462 463-extern int NXTransAgent(int fd[2]); 464+extern NXCOMP_API int NXTransAgent(int fd[2]); 465 466 /* 467 * Prepare the file sets and the timeout for a later execution of 468@@ -104,7 +127,7 @@ 469 * pointers are passed. 470 */ 471 472-extern int NXTransPrepare(int *maxfds, fd_set *readfds, 473+extern NXCOMP_API int NXTransPrepare(int *maxfds, fd_set *readfds, 474 fd_set *writefds, struct timeval *timeout); 475 476 /* 477@@ -112,7 +135,7 @@ 478 * pending data. 479 */ 480 481-extern int NXTransSelect(int *result, int *error, int *maxfds, fd_set *readfds, 482+extern NXCOMP_API int NXTransSelect(int *result, int *error, int *maxfds, fd_set *readfds, 483 fd_set *writefds, struct timeval *timeout); 484 485 /* 486@@ -122,7 +145,7 @@ 487 * the other NX resources. 488 */ 489 490-extern int NXTransExecute(int *result, int *error, int *maxfds, fd_set *readfds, 491+extern NXCOMP_API int NXTransExecute(int *result, int *error, int *maxfds, fd_set *readfds, 492 fd_set *writefds, struct timeval *timeout); 493 494 /* 495@@ -130,7 +153,7 @@ 496 * its descriptors. 497 */ 498 499-extern int NXTransContinue(struct timeval *timeout); 500+extern NXCOMP_API int NXTransContinue(struct timeval *timeout); 501 502 /* 503 * Perform I/O on the given descriptors. If memory-to-memory trans- 504@@ -140,14 +163,14 @@ 505 * ing network operation will be performed. 506 */ 507 508-extern int NXTransRead(int fd, char *data, int size); 509-extern int NXTransWrite(int fd, char *data, int size); 510-extern int NXTransReadable(int fd, int *readable); 511+extern NXCOMP_API int NXTransRead(int fd, char *data, int size); 512+extern NXCOMP_API int NXTransWrite(int fd, char *data, int size); 513+extern NXCOMP_API int NXTransReadable(int fd, int *readable); 514 515-extern int NXTransReadVector(int fd, struct iovec *iovdata, int iovsize); 516-extern int NXTransWriteVector(int fd, struct iovec *iovdata, int iovsize); 517+extern NXCOMP_API int NXTransReadVector(int fd, struct iovec *iovdata, int iovsize); 518+extern NXCOMP_API int NXTransWriteVector(int fd, struct iovec *iovdata, int iovsize); 519 520-extern int NXTransClose(int fd); 521+extern NXCOMP_API int NXTransClose(int fd); 522 523 /* 524 * Return true if the NX transport is running. The fd parameter can 525@@ -155,7 +178,7 @@ 526 * NX_FD_ANY. 527 */ 528 529-extern int NXTransRunning(int fd); 530+extern NXCOMP_API int NXTransRunning(int fd); 531 532 /* 533 * Close down the NX transport and free all the allocated resources. 534@@ -164,7 +187,7 @@ 535 * start the tear down procedure. 536 */ 537 538-extern int NXTransDestroy(int fd); 539+extern NXCOMP_API int NXTransDestroy(int fd); 540 541 /* 542 * Tell to the proxy how to handle the standard POSIX signals. For 543@@ -233,7 +256,7 @@ 544 * ialize the NX transport. 545 */ 546 547-extern int NXTransSignal(int signal, int action); 548+extern NXCOMP_API int NXTransSignal(int signal, int action); 549 550 /* 551 * Return a value between 0 and 9 indicating the congestion level 552@@ -241,7 +264,7 @@ 553 * the link is congested and no further data can be sent. 554 */ 555 556-extern int NXTransCongestion(int fd); 557+extern NXCOMP_API int NXTransCongestion(int fd); 558 559 /* 560 * Let the application to be notified by the proxy when an event oc- 561@@ -276,7 +299,7 @@ 562 * wrapper. 563 */ 564 565-extern int NXTransHandler(int fd, int type, void (*handler)(void *parameter, 566+extern NXCOMP_API int NXTransHandler(int fd, int type, void (*handler)(void *parameter, 567 int reason), void *parameter); 568 569 /* 570@@ -292,21 +315,21 @@ 571 * the agent. 572 */ 573 574-extern int NXTransPolicy(int fd, int type); 575+extern NXCOMP_API int NXTransPolicy(int fd, int type); 576 577 /* 578 * Query the number of bytes that have been accumulated for a deferred 579 * flush. 580 */ 581 582-extern int NXTransFlushable(int fd); 583+extern NXCOMP_API int NXTransFlushable(int fd); 584 585 /* 586 * Tell to the NX transport to write all the accumulated data to the 587 * remote proxy. 588 */ 589 590-extern int NXTransFlush(int fd); 591+extern NXCOMP_API int NXTransFlush(int fd); 592 593 /* 594 * Create a new channel of the given type. It returns 1 on success, 595@@ -386,7 +409,7 @@ 596 * mentation of _XSelect() in nx-X11/lib/X11/XlibInt.c for an example. 597 */ 598 599-extern int NXTransChannel(int fd, int channelfd, int type); 600+extern NXCOMP_API int NXTransChannel(int fd, int channelfd, int type); 601 602 /* 603 * Return the name of the files used by the proxy for the current session. 604@@ -408,41 +431,41 @@ 605 * pointer. 606 */ 607 608-extern const char *NXTransFile(int type); 609+extern NXCOMP_API const char *NXTransFile(int type); 610 611 /* 612 * Return the time in milliseconds elapsed since the last call to this 613 * same function. 614 */ 615 616-extern long NXTransTime(void); 617+extern NXCOMP_API long NXTransTime(void); 618 619 /* 620 * Other interfaces to the internal transport functions. 621 */ 622 623-extern int NXTransProxy(int fd, int mode, const char *display); 624+extern NXCOMP_API int NXTransProxy(int fd, int mode, const char *display); 625 626-extern int NXTransClient(const char *display); 627+extern NXCOMP_API int NXTransClient(const char *display); 628 629-extern int NXTransDialog(const char *caption, const char *message, 630+extern NXCOMP_API int NXTransDialog(const char *caption, const char *message, 631 const char *window, const char *type, int local, 632 const char *display); 633 634-extern int NXTransAlert(int code, int local); 635+extern NXCOMP_API int NXTransAlert(int code, int local); 636 637-extern int NXTransWatchdog(int timeout); 638+extern NXCOMP_API int NXTransWatchdog(int timeout); 639 640-extern int NXTransKeeper(int caches, int images, const char *root); 641+extern NXCOMP_API int NXTransKeeper(int caches, int images, const char *root); 642 643-extern void NXTransExit(int code) __attribute__((noreturn)); 644+extern NXCOMP_API void NXTransExit(int code) __attribute__((noreturn)); 645 646-extern int NXTransParseCommandLine(int argc, const char **argv); 647-extern int NXTransParseEnvironment(const char *env, int force); 648+extern NXCOMP_API int NXTransParseCommandLine(int argc, const char **argv); 649+extern NXCOMP_API int NXTransParseEnvironment(const char *env, int force); 650 651-extern void NXTransCleanup(void) __attribute__((noreturn)); 652+extern NXCOMP_API void NXTransCleanup(void) __attribute__((noreturn)); 653 654-extern int NXTransRate(void); 655+extern NXCOMP_API int NXTransRate(void); 656 657 #ifdef __cplusplus 658 } 659