zxdos / zxuno

All the files for ZX-Uno project repository
112 stars 30 forks source link

Source files have much in common #70

Closed ghost closed 3 years ago

ghost commented 3 years ago

Contents of assembler files of firmware and utils directories have much in common (and may be in others, I haven't checked it yet). Some shared source code is in .inc files in utils directory. What if we move all .inc files shared with multiple sources into a separate directory in SDK folder? We may use this directory structure (included files below are just an example of usage):

Variant 1:

sdk
└─include
  ├─rst28.inc
  ├─table.c
  ├─zxuno.def
  └─zxuno.h

Usage:

NOTE: In this case there will be a mix of header files (.def, .h) and shared source files (.inc, .c) in one place.

Variant 2:

sdk
├─asm
│ └─rst28.inc
├─c
│ └─table.c
└─include
  ├─zxuno.def
  └─zxuno.h

Usage:

Variant 3:

sdk
└─include
  ├─asm
  │ └─rst28.inc
  ├─c
  │ └─table.c
  ├─zxuno.def
  └─zxuno.h

Usage:

Variant 4:

sdk
├─include
│ ├─zxuno.def
│ └─zxuno.h
└─src
  ├─asm
  │ └─rst28.inc
  └─c
    └─table.c

Usage:

What do you think?

ghost commented 3 years ago

Is there anyone alive? I think the first variant will be the most suitable, because we don't know the amount of files (so as their role) in include folder.

antoniovillena commented 3 years ago

Ok. Agree with variant 1

ghost commented 3 years ago

Closed by https://github.com/zxdos/zxuno/pull/86