Skip to content
This repository has been archived by the owner on Oct 24, 2023. It is now read-only.

Commit

Permalink
libseven: header reorganisation
Browse files Browse the repository at this point in the history
  • Loading branch information
LunarLambda committed Nov 12, 2022
1 parent 8511f96 commit b8517b4
Show file tree
Hide file tree
Showing 36 changed files with 116 additions and 114 deletions.
2 changes: 1 addition & 1 deletion dist.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@ make_dist() {
sha256sum -b $PROJECT-$VERSION.zip > $PROJECT-$VERSION.zip.sha256sum
}

(PROJECT=libseven VERSION=0.7.1 make_dist)
(PROJECT=libseven VERSION=0.8.0 make_dist)
(PROJECT=minrt VERSION=0.2.0 make_dist)
4 changes: 2 additions & 2 deletions examples/template/src/main.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#include <seven/video/prelude.h>
#include <seven/video/bg_bitmap.h>
#include <seven/hw/video/prelude.h>
#include <seven/hw/video/bg_bitmap.h>

int main(void)
{
Expand Down
2 changes: 1 addition & 1 deletion libseven/include/seven/base/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <seven/base.h>

#define LIBSEVEN_VERSION_MAJOR 0
#define LIBSEVEN_VERSION_MINOR 7
#define LIBSEVEN_VERSION_MINOR 8
#define LIBSEVEN_VERSION_PATCH 0

#define LIBSEVEN_VERSION \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_HW_SVC_H
#define _LIBSEVEN_HW_SVC_H
#ifndef _LIBSEVEN_HW_BIOS_H
#define _LIBSEVEN_HW_BIOS_H

#include <seven/base.h>

Expand Down Expand Up @@ -70,4 +70,4 @@ enum SupervisorCallNumber

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_HW_SVC_H */
#endif /* !_LIBSEVEN_HW_BIOS_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_SVC_AFFINE_H
#define _LIBSEVEN_SVC_AFFINE_H
#ifndef _LIBSEVEN_HW_BIOS_AFFINE_H
#define _LIBSEVEN_HW_BIOS_AFFINE_H

#include <seven/base.h>

Expand Down Expand Up @@ -66,4 +66,4 @@ extern void svcObjAffineSet(

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_SVC_AFFINE_H */
#endif /* !_LIBSEVEN_HW_BIOS_AFFINE_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_SVC_DECOMPRESSION_H
#define _LIBSEVEN_SVC_DECOMPRESSION_H
#ifndef _LIBSEVEN_HW_BIOS_DECOMPRESSION_H
#define _LIBSEVEN_HW_BIOS_DECOMPRESSION_H

#include <seven/base.h>

Expand Down Expand Up @@ -36,4 +36,4 @@ extern void svcDiff16bitUnFilter(const void *src, void *dst);

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_SVC_DECOMPRESSION_H */
#endif /* !_LIBSEVEN_HW_BIOS_DECOMPRESSION_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_SVC_MATH_H
#define _LIBSEVEN_SVC_MATH_H
#ifndef _LIBSEVEN_HW_BIOS_MATH_H
#define _LIBSEVEN_HW_BIOS_MATH_H

#include <seven/base.h>

Expand All @@ -24,4 +24,4 @@ extern u16 svcArcTan2(i16 x, i16 y);

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_SVC_MATH_H */
#endif /* !_LIBSEVEN_HW_BIOS_MATH_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_SVC_MEMORY_H
#define _LIBSEVEN_SVC_MEMORY_H
#ifndef _LIBSEVEN_HW_BIOS_MEMORY_H
#define _LIBSEVEN_HW_BIOS_MEMORY_H

#include <seven/base.h>

Expand All @@ -31,4 +31,4 @@ extern void svcCpuFastSetFixed(u32 value, void *dst, u32 ctrl);

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_SVC_MEMORY_H */
#endif /* !_LIBSEVEN_HW_BIOS_MEMORY_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_SVC_RESET_H
#define _LIBSEVEN_SVC_RESET_H
#ifndef _LIBSEVEN_HW_BIOS_RESET_H
#define _LIBSEVEN_HW_BIOS_RESET_H

#include <seven/base.h>

Expand Down Expand Up @@ -42,4 +42,4 @@ extern void svcRegisterRamReset(u8 reset_flags);

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_SVC_RESET_H */
#endif /* !_LIBSEVEN_HW_BIOS_RESET_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_SVC_SOUND_H
#define _LIBSEVEN_SVC_SOUND_H
#ifndef _LIBSEVEN_HW_BIOS_SOUND_H
#define _LIBSEVEN_HW_BIOS_SOUND_H

#include <seven/base.h>

Expand All @@ -19,4 +19,4 @@ extern void svcSoundDriverVSyncOn(void);

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_SVC_SOUND_H */
#endif /* !_LIBSEVEN_HW_BIOS_SOUND_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_SVC_SYSTEM_H
#define _LIBSEVEN_SVC_SYSTEM_H
#ifndef _LIBSEVEN_HW_BIOS_SYSTEM_H
#define _LIBSEVEN_HW_BIOS_SYSTEM_H

#include <seven/base.h>

Expand All @@ -21,5 +21,5 @@ extern u32 svcBiosChecksum(void);

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_SVC_SYSTEM_H */
#endif /* !_LIBSEVEN_HW_BIOS_SYSTEM_H */

Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_SVC_WAIT_H
#define _LIBSEVEN_SVC_WAIT_H
#ifndef _LIBSEVEN_HW_BIOS_WAIT_H
#define _LIBSEVEN_HW_BIOS_WAIT_H

#include <seven/base.h>

Expand All @@ -29,4 +29,4 @@ extern void svcVBlankIntrWait(void);

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_SVC_WAIT_H */
#endif /* !_LIBSEVEN_HW_BIOS_WAIT_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_HW_GPIO_H
#define _LIBSEVEN_HW_GPIO_H
#ifndef _LIBSEVEN_HW_CARTRIDGE_H
#define _LIBSEVEN_HW_CARTRIDGE_H

#include <seven/base.h>

Expand All @@ -32,4 +32,4 @@ enum GpioControl

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_HW_GPIO_H */
#endif /* !_LIBSEVEN_HW_CARTRIDGE_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_SERIAL_JOYBUS_H
#define _LIBSEVEN_SERIAL_JOYBUS_H
#ifndef _LIBSEVEN_HW_SERIAL_JOYBUS_H
#define _LIBSEVEN_HW_SERIAL_JOYBUS_H

#error "seven/serial/joybus.h is unfinished and should not be used"
#error "seven/hw/serial/joybus.h is unfinished and should not be used"

#include <seven/base.h>
#include <seven/hw/serial.h>
Expand All @@ -24,4 +24,4 @@ _LIBSEVEN_EXTERN_C

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_SERIAL_JOYBUS_H */
#endif /* !_LIBSEVEN_HW_SERIAL_JOYBUS_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_SERIAL_MULTIPLAYER_H
#define _LIBSEVEN_SERIAL_MULTIPLAYER_H
#ifndef _LIBSEVEN_HW_SERIAL_MULTIPLAYER_H
#define _LIBSEVEN_HW_SERIAL_MULTIPLAYER_H

#error "seven/serial/multiplayer.h is unfinished and should not be used"
#error "seven/hw/serial/multiplayer.h is unfinished and should not be used"

#include <seven/base.h>
#include <seven/hw/serial.h>
Expand Down Expand Up @@ -37,4 +37,4 @@ enum SerialIOControlMultiplayer

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_SERIAL_MULTIPLAYER_H */
#endif /* !_LIBSEVEN_HW_SERIAL_MULTIPLAYER_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_SERIAL_RAW_H
#define _LIBSEVEN_SERIAL_RAW_H
#ifndef _LIBSEVEN_HW_SERIAL_RAW_H
#define _LIBSEVEN_HW_SERIAL_RAW_H

#error "seven/serial/raw.h is unfinished and should not be used"
#error "seven/hw/serial/raw.h is unfinished and should not be used"

#include <seven/base.h>
#include <seven/hw/serial.h>
Expand Down Expand Up @@ -41,4 +41,4 @@ enum SerialIORaw

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_SERIAL_RAW_H */
#endif /* !_LIBSEVEN_HW_SERIAL_RAW_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_SERIAL_UART_H
#define _LIBSEVEN_SERIAL_UART_H
#ifndef _LIBSEVEN_HW_SERIAL_UART_H
#define _LIBSEVEN_HW_SERIAL_UART_H

#error "seven/serial/uart.h is unfinished and should not be used"
#error "seven/hw/serial/uart.h is unfinished and should not be used"

#include <seven/base.h>
#include <seven/hw/serial.h>
Expand All @@ -32,4 +32,4 @@ enum SerialIOControlUART

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_SERIAL_UART_H */
#endif /* !_LIBSEVEN_HW_SERIAL_UART_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_VIDEO_BG_AFFINE_H
#define _LIBSEVEN_VIDEO_BG_AFFINE_H
#ifndef _LIBSEVEN_HW_VIDEO_BG_AFFINE_H
#define _LIBSEVEN_HW_VIDEO_BG_AFFINE_H

#include <seven/base.h>
#include <seven/hw/video.h>
#include <seven/video/bg_tiled.h>
#include <seven/video/bg_transform.h>
#include <seven/hw/video/bg_tiled.h>
#include <seven/hw/video/bg_transform.h>

_LIBSEVEN_EXTERN_C

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_VIDEO_BG_AFFINE_H */
#endif /* !_LIBSEVEN_HW_VIDEO_BG_AFFINE_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_VIDEO_BG_BITMAP_H
#define _LIBSEVEN_VIDEO_BG_BITMAP_H
#ifndef _LIBSEVEN_HW_VIDEO_BG_BITMAP_H
#define _LIBSEVEN_HW_VIDEO_BG_BITMAP_H

#include <seven/base.h>
#include <seven/hw/video.h>
#include <seven/video/bg_transform.h>
#include <seven/hw/video/bg_transform.h>

_LIBSEVEN_EXTERN_C

Expand Down Expand Up @@ -40,4 +40,4 @@ extern void* bmpSwapBuffers(void);

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_VIDEO_BG_BITMAP_H */
#endif /* !_LIBSEVEN_HW_VIDEO_BG_BITMAP_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_VIDEO_BG_MIXED_H
#define _LIBSEVEN_VIDEO_BG_MIXED_H
#ifndef _LIBSEVEN_HW_VIDEO_BG_MIXED_H
#define _LIBSEVEN_HW_VIDEO_BG_MIXED_H

#include <seven/base.h>
#include <seven/video/bg_affine.h>
#include <seven/video/bg_regular.h>
#include <seven/hw/video/bg_affine.h>
#include <seven/hw/video/bg_regular.h>

#endif /* !_LIBSEVEN_VIDEO_BG_MIXED_H */
#endif /* !_LIBSEVEN_HW_VIDEO_BG_MIXED_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_VIDEO_BG_REGULAR_H
#define _LIBSEVEN_VIDEO_BG_REGULAR_H
#ifndef _LIBSEVEN_HW_VIDEO_BG_REGULAR_H
#define _LIBSEVEN_HW_VIDEO_BG_REGULAR_H

#include <seven/base.h>
#include <seven/hw/video.h>
#include <seven/video/bg_scroll.h>
#include <seven/video/bg_tiled.h>
#include <seven/hw/video/bg_scroll.h>
#include <seven/hw/video/bg_tiled.h>

_LIBSEVEN_EXTERN_C

Expand All @@ -32,4 +32,4 @@ enum Tile

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_VIDEO_BG_REGULAR_H */
#endif /* !_LIBSEVEN_HW_VIDEO_BG_REGULAR_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_VIDEO_BG_SCROLL_H
#define _LIBSEVEN_VIDEO_BG_SCROLL_H
#ifndef _LIBSEVEN_HW_VIDEO_BG_SCROLL_H
#define _LIBSEVEN_HW_VIDEO_BG_SCROLL_H

#include <seven/base.h>
#include <seven/hw/video.h>
Expand All @@ -23,4 +23,4 @@ _LIBSEVEN_EXTERN_C

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_VIDEO_BG_SCROLL_H */
#endif /* !_LIBSEVEN_HW_VIDEO_BG_SCROLL_H */
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

#ifndef _LIBSEVEN_VIDEO_BG_TILED_H
#define _LIBSEVEN_VIDEO_BG_TILED_H
#ifndef _LIBSEVEN_HW_VIDEO_BG_TILED_H
#define _LIBSEVEN_HW_VIDEO_BG_TILED_H

#include <seven/base.h>
#include <seven/hw/video.h>
Expand All @@ -14,4 +14,4 @@ _LIBSEVEN_EXTERN_C

_LIBSEVEN_EXTERN_C_END

#endif /* !_LIBSEVEN_VIDEO_BG_TILED_H */
#endif /* !_LIBSEVEN_HW_VIDEO_BG_TILED_H */
Loading

0 comments on commit b8517b4

Please sign in to comment.