mirror of
https://github.com/janet-lang/janet
synced 2025-01-03 20:30:27 +00:00
Work on dllimport option for janet.
This commit is contained in:
parent
169bd812c9
commit
b10aaceab0
@ -64,7 +64,7 @@ rc /nologo /fobuild\janet_win.res janet_win.rc
|
|||||||
%JANET_LINK% /out:janet.exe build\janet.obj build\shell.obj build\janet_win.res
|
%JANET_LINK% /out:janet.exe build\janet.obj build\shell.obj build\janet_win.res
|
||||||
@if errorlevel 1 goto :BUILDFAIL
|
@if errorlevel 1 goto :BUILDFAIL
|
||||||
|
|
||||||
@rem Build static library (libjanet.a)
|
@rem Build static library (libjanet.lib)
|
||||||
%JANET_LINK_STATIC% /out:build\libjanet.lib build\janet.obj
|
%JANET_LINK_STATIC% /out:build\libjanet.lib build\janet.obj
|
||||||
@if errorlevel 1 goto :BUILDFAIL
|
@if errorlevel 1 goto :BUILDFAIL
|
||||||
|
|
||||||
@ -117,6 +117,7 @@ copy README.md dist\README.md
|
|||||||
|
|
||||||
copy janet.lib dist\janet.lib
|
copy janet.lib dist\janet.lib
|
||||||
copy janet.exp dist\janet.exp
|
copy janet.exp dist\janet.exp
|
||||||
|
copy janet.def dist\janet.def
|
||||||
|
|
||||||
janet.exe tools\patch-header.janet src\include\janet.h src\conf\janetconf.h build\janet.h
|
janet.exe tools\patch-header.janet src\include\janet.h src\conf\janetconf.h build\janet.h
|
||||||
copy build\janet.h dist\janet.h
|
copy build\janet.h dist\janet.h
|
||||||
|
@ -237,7 +237,11 @@ extern "C" {
|
|||||||
/* How to export symbols */
|
/* How to export symbols */
|
||||||
#ifndef JANET_API
|
#ifndef JANET_API
|
||||||
#ifdef JANET_WINDOWS
|
#ifdef JANET_WINDOWS
|
||||||
|
#ifdef JANET_DLL_IMPORT
|
||||||
|
#define JANET_API __declspec(dllimport)
|
||||||
|
#else
|
||||||
#define JANET_API __declspec(dllexport)
|
#define JANET_API __declspec(dllexport)
|
||||||
|
#endif
|
||||||
#else
|
#else
|
||||||
#define JANET_API __attribute__((visibility ("default")))
|
#define JANET_API __attribute__((visibility ("default")))
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user