Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

added -sourcepath=src/shiny and -sourcepath=. to the ooc flags so tha…

…t .ooc's can 'import foo' instead of 'import src/shiny/foo'
  • Loading branch information...
commit 19e685aa4efe5da777f733e972d553dee988c0f1 1 parent 1709ef6
Scott Olson tsion authored
2  SConstruct
@@ -25,7 +25,7 @@ env = Environment(
25 25 LINK='ld',
26 26 LINKFLAGS=['-melf_i386', '-nostdlib'],
27 27 OOC='ooc',
28   - OOCFLAGS=['-c', '-gcc', '-driver=sequence', '-nomain', '-gc=off', '+-m32', '+-nostdinc', '+-ffreestanding', '-Iinclude'],
  28 + OOCFLAGS=['-c', '-gcc', '-driver=sequence', '-nomain', '-gc=off', '+-m32', '+-nostdinc', '+-ffreestanding', '-Iinclude', '-sourcepath=.'],
29 29 ENV = os.environ, # pass outside env to build so ooc is in PATH and OOC_DIST exists
30 30 )
31 31
7 src/shiny/SConscript
@@ -10,10 +10,13 @@ Export('sources', 'shiny')
10 10 SConscript('boot/%s/SConscript' % arch)
11 11 SConscript('hal/%s/SConscript' % arch)
12 12
13   -ooc = env.ooc('ooc.lib', 'init/init.ooc')
  13 +ooc = env.Clone()
  14 +ooc.Append(OOCFLAGS=['-sourcepath=src/shiny'])
  15 +
  16 +ooclib = ooc.ooc('ooc.lib', 'init/init.ooc')
14 17
15 18 sources += [
16   - ooc,
  19 + ooclib
17 20 ]
18 21
19 22 shinyexe = shiny.Program('shiny', sources)
2  src/shiny/init/init.ooc
... ... @@ -1,7 +1,7 @@
1 1 include shiny/shiny
2 2 include shiny/hal/hal
3 3
4   -import src/shiny/display
  4 +import display
5 5
6 6 MultiBootInfoT: cover from multiboot_info_t {
7 7 cmdline, boot_loader_name: extern UInt

0 comments on commit 19e685a

Please sign in to comment.
Something went wrong with that request. Please try again.