-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmakefile.dao
36 lines (23 loc) · 1.15 KB
/
makefile.dao
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
project = DaoMake::Project( "DaoGSL" )
daovm = DaoMake::FindPackage( "Dao", $REQUIRED )
daoaux = DaoMake::FindPackage( "DaoAux", $REQUIRED )
gsl2 = DaoMake::FindPackage( "GSL", $OPTIONAL )
if( daovm == none or daoaux == none or gsl2 == none ) return
cflags = gsl2.MakeCompilingFlags()
clangdao = project.MakeBuildPath( "../../bin/clangdao" )
if( DaoMake::IsFile( clangdao ) && DaoMake::IsOutOfSourceBuild() == 0 ){
bind = project.AddCommand( "$(DAOMAKE_SOURCE_DIR)/wrap/dao_gsl.h: gsl.c", "@$(DAOMAKE) mkdir2 ./wrap/" )
bind.AddCommand( clangdao + " " + cflags + " gsl.c -o wrap/" )
}
project.SetTargetPath( "../../lib/dao/modules" )
project.UseImportLibrary( daovm, "dao" )
project.UseSharedLibrary( daoaux, "dao_aux" )
project.AddIncludePath( "." )
project.AddIncludePath( "../../kernel" )
project.AddIncludePath( "../../" )
sources = { "wrap/dao_gsl.c", "wrap/dao_gsl2.c", "wrap/dao_gsl3.c" }
daogsl_objs = project.AddObjects( sources, { "wrap/dao_gsl.h" } )
daogsl_dll = project.AddSharedLibrary( "dao_gsl", daogsl_objs )
daogsl_dll.UseSharedLibrary( gsl2 )
project.Install( DaoMake::Variables[ "INSTALL_MOD" ], daogsl_dll );
project.GenerateFinder( $TRUE );