forked from deanmao/nusax
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathnukefile.linux
45 lines (33 loc) · 1.57 KB
/
nukefile.linux
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
37
38
39
40
41
42
43
44
;; source files
(set @m_files (filelist "^objc/.*.m$"))
(set @nu_files (filelist "^nu/.*nu$"))
(set SYSTEM ((NSString stringWithShellCommand:"uname") chomp))
(case SYSTEM
("Darwin"
(set @cflags "-g -fobjc-gc -std=gnu99 -DDARWIN")
(set @ldflags "-lcurl -framework Foundation -framework Nu "))
("Linux"
(set @arch (list "i386"))
;;(set @cflags "-I /usr/include/libxml2 -g -DLINUX -I/usr/include/GNUstep/Headers -I/usr/local/include -fconstant-string-class=NSConstantString ")
;;(set @ldflags "-L/usr/local/lib -lNu -lxml2")
(set gnustep_flags ((NSString stringWithShellCommand:"gnustep-config --objc-flags") chomp))
(set gnustep_libs ((NSString stringWithShellCommand:"gnustep-config --base-libs") chomp))
(set @cflags "-g -std=gnu99 -DLINUX -I /usr/include/libxml2 -I/usr/local/include #{gnustep_flags}")
(set @ldflags "#{gnustep_libs} -lNu -lxml2"))
(else nil))
;; framework description
(set @framework "NuSAX")
(set @framework_identifier "nu.programming.nusax")
(set @framework_creator_code "????")
(compilation-tasks)
(framework-tasks)
(task "clobber" => "clean" is
(SH "rm -rf #{@framework_dir}"))
(task "default" => "framework")
(task "doc" is (SH "nudoc"))
(task "install" => "framework" is
(SH "sudo rm -rf /Library/Frameworks/#{@framework}.framework")
(SH "ditto #{@framework}.framework /Library/Frameworks/#{@framework}.framework"))
(task "test" => "framework" is
(SH "nutest test/test_*.nu"))
(load "template")