2010-08-09 13:28:56 +00:00
|
|
|
# Makefile
|
|
|
|
# author: byuu
|
|
|
|
# license: public domain
|
|
|
|
|
|
|
|
[A-Z] = A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
|
|
|
|
[a-z] = a b c d e f g h i j k l m n o p q r s t u v w x y z
|
|
|
|
[0-9] = 0 1 2 3 4 5 6 7 8 9
|
|
|
|
[markup] = ` ~ ! @ \# $$ % ^ & * ( ) - _ = + [ { ] } \ | ; : ' " , < . > / ?
|
|
|
|
[all] = $([A-Z]) $([a-z]) $([0-9]) $([markup])
|
|
|
|
[space] :=
|
|
|
|
[space] +=
|
|
|
|
|
|
|
|
#####
|
|
|
|
# platform detection
|
|
|
|
#####
|
|
|
|
|
|
|
|
ifeq ($(platform),)
|
|
|
|
uname := $(shell uname -a)
|
|
|
|
ifeq ($(uname),)
|
|
|
|
platform := win
|
|
|
|
delete = del $(subst /,\,$1)
|
Update to v090 release.
byuu says:
Most notably, this release adds Nintendo DS emulation. The Nintendo DS
module was written entirely by Cydrak, so please give him all of the
credit for it. I for one am extremely grateful to be allowed to use his
module in bsnes.
The Nintendo DS emulator's standalone name is dasShiny. You will need
the Nintendo DS firmware, which I cannot provide, in order to use it. It
also cannot (currently?) detect the save type used by NDS games. As
such, manifest.xml files must be created manually for this purpose. The
long-term plan is to create a database of save types for each game.
Also, you will need an analog input device for the touch screen for now
(joypad axes work well.)
There have also been a lot of changes from my end: a unified
manifest.xml format across all systems, major improvements to SPC7110
emulation, enhancements to RTC emulation, MSU1 enhancements, icons in
the file browser list, improvements to SNES coprocessor memory mapping,
cleanups and improvements in the libraries used to build bsnes, etc.
I've also included kaijuu (which allows launching game folders directly
with bsnes) and purify (which allows opening images that are compressed,
have copier headers, and have wrong extensions); both of which are fully
GUI-based.
This release only loads game folders, not files. Use purify to load ROM
files in bsnes.
Note that this will likely be the last release for a long time, and that
I will probably rename the emulator for the next release, due to how
many additional systems it now supports.
2012-08-07 14:08:37 +00:00
|
|
|
else ifneq ($(findstring Windows,$(uname)),)
|
|
|
|
platform := win
|
|
|
|
delete = del $(subst /,\,$1)
|
Update to v084r03 release.
(r02 was not posted to the WIP thread)
byuu says:
Internally, all color is processed with 30-bit precision. The filters
also operate at 30-bit depth.
There's a new config file setting, video.depth, which defaults to 24.
This causes the final output to downsample to 24-bit, as most will
require.
If you set it to 30-bit, the downsampling will not occur, and bsnes will
ask ruby for a 30-bit surface. If you don't have one available, you're
going to get bad colors. Or maybe even a crash with OpenGL.
I don't yet have detection code to make sure you have an appropriate
visual in place.
30-bit mode will really only work if you are running Linux, running Xorg
at Depth 30, use the OpenGL or XShm driver, have an nVidia Quadro or AMD
FireGL card with the official drivers, and have a 30-bit capable
monitor.
Lots of planning and work for very little gain here, but it's nice that
it's finally finished.
Oh, I had to change the contrast/brightness formulas a tiny bit, but
they still work and look nice.
2011-12-03 03:22:54 +00:00
|
|
|
else ifneq ($(findstring CYGWIN,$(uname)),)
|
|
|
|
platform := win
|
|
|
|
delete = del $(subst /,\,$1)
|
2010-08-09 13:28:56 +00:00
|
|
|
else ifneq ($(findstring Darwin,$(uname)),)
|
|
|
|
platform := osx
|
|
|
|
delete = rm -f $1
|
|
|
|
else
|
|
|
|
platform := x
|
|
|
|
delete = rm -f $1
|
|
|
|
endif
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(compiler),)
|
2010-10-26 12:01:41 +00:00
|
|
|
ifeq ($(platform),win)
|
2010-08-09 13:28:56 +00:00
|
|
|
compiler := gcc
|
2010-10-26 12:01:41 +00:00
|
|
|
else ifeq ($(platform),osx)
|
Update to v090 release.
byuu says:
Most notably, this release adds Nintendo DS emulation. The Nintendo DS
module was written entirely by Cydrak, so please give him all of the
credit for it. I for one am extremely grateful to be allowed to use his
module in bsnes.
The Nintendo DS emulator's standalone name is dasShiny. You will need
the Nintendo DS firmware, which I cannot provide, in order to use it. It
also cannot (currently?) detect the save type used by NDS games. As
such, manifest.xml files must be created manually for this purpose. The
long-term plan is to create a database of save types for each game.
Also, you will need an analog input device for the touch screen for now
(joypad axes work well.)
There have also been a lot of changes from my end: a unified
manifest.xml format across all systems, major improvements to SPC7110
emulation, enhancements to RTC emulation, MSU1 enhancements, icons in
the file browser list, improvements to SNES coprocessor memory mapping,
cleanups and improvements in the libraries used to build bsnes, etc.
I've also included kaijuu (which allows launching game folders directly
with bsnes) and purify (which allows opening images that are compressed,
have copier headers, and have wrong extensions); both of which are fully
GUI-based.
This release only loads game folders, not files. Use purify to load ROM
files in bsnes.
Note that this will likely be the last release for a long time, and that
I will probably rename the emulator for the next release, due to how
many additional systems it now supports.
2012-08-07 14:08:37 +00:00
|
|
|
compiler := gcc-mp-4.7
|
2010-10-26 12:01:41 +00:00
|
|
|
else
|
Update to v090 release.
byuu says:
Most notably, this release adds Nintendo DS emulation. The Nintendo DS
module was written entirely by Cydrak, so please give him all of the
credit for it. I for one am extremely grateful to be allowed to use his
module in bsnes.
The Nintendo DS emulator's standalone name is dasShiny. You will need
the Nintendo DS firmware, which I cannot provide, in order to use it. It
also cannot (currently?) detect the save type used by NDS games. As
such, manifest.xml files must be created manually for this purpose. The
long-term plan is to create a database of save types for each game.
Also, you will need an analog input device for the touch screen for now
(joypad axes work well.)
There have also been a lot of changes from my end: a unified
manifest.xml format across all systems, major improvements to SPC7110
emulation, enhancements to RTC emulation, MSU1 enhancements, icons in
the file browser list, improvements to SNES coprocessor memory mapping,
cleanups and improvements in the libraries used to build bsnes, etc.
I've also included kaijuu (which allows launching game folders directly
with bsnes) and purify (which allows opening images that are compressed,
have copier headers, and have wrong extensions); both of which are fully
GUI-based.
This release only loads game folders, not files. Use purify to load ROM
files in bsnes.
Note that this will likely be the last release for a long time, and that
I will probably rename the emulator for the next release, due to how
many additional systems it now supports.
2012-08-07 14:08:37 +00:00
|
|
|
compiler := gcc-4.7
|
2010-08-09 13:28:56 +00:00
|
|
|
endif
|
|
|
|
endif
|
|
|
|
|
Update to v090 release.
byuu says:
Most notably, this release adds Nintendo DS emulation. The Nintendo DS
module was written entirely by Cydrak, so please give him all of the
credit for it. I for one am extremely grateful to be allowed to use his
module in bsnes.
The Nintendo DS emulator's standalone name is dasShiny. You will need
the Nintendo DS firmware, which I cannot provide, in order to use it. It
also cannot (currently?) detect the save type used by NDS games. As
such, manifest.xml files must be created manually for this purpose. The
long-term plan is to create a database of save types for each game.
Also, you will need an analog input device for the touch screen for now
(joypad axes work well.)
There have also been a lot of changes from my end: a unified
manifest.xml format across all systems, major improvements to SPC7110
emulation, enhancements to RTC emulation, MSU1 enhancements, icons in
the file browser list, improvements to SNES coprocessor memory mapping,
cleanups and improvements in the libraries used to build bsnes, etc.
I've also included kaijuu (which allows launching game folders directly
with bsnes) and purify (which allows opening images that are compressed,
have copier headers, and have wrong extensions); both of which are fully
GUI-based.
This release only loads game folders, not files. Use purify to load ROM
files in bsnes.
Note that this will likely be the last release for a long time, and that
I will probably rename the emulator for the next release, due to how
many additional systems it now supports.
2012-08-07 14:08:37 +00:00
|
|
|
c := $(compiler) -std=gnu99
|
|
|
|
cpp := $(subst cc,++,$(compiler)) -std=gnu++0x
|
|
|
|
|
2010-08-09 13:28:56 +00:00
|
|
|
ifeq ($(prefix),)
|
|
|
|
prefix := /usr/local
|
|
|
|
endif
|
|
|
|
|
|
|
|
#####
|
|
|
|
# function rwildcard(directory, pattern)
|
|
|
|
#####
|
|
|
|
rwildcard = \
|
|
|
|
$(strip \
|
|
|
|
$(filter $(if $2,$2,%), \
|
|
|
|
$(foreach f, \
|
|
|
|
$(wildcard $1*), \
|
|
|
|
$(eval t = $(call rwildcard,$f/)) \
|
|
|
|
$(if $t,$t,$f) \
|
|
|
|
) \
|
|
|
|
) \
|
|
|
|
)
|
|
|
|
|
|
|
|
#####
|
|
|
|
# function strtr(source, from, to)
|
|
|
|
#####
|
|
|
|
strtr = \
|
|
|
|
$(eval __temp := $1) \
|
|
|
|
$(strip \
|
|
|
|
$(foreach c, \
|
|
|
|
$(join $(addsuffix :,$2),$3), \
|
|
|
|
$(eval __temp := \
|
|
|
|
$(subst $(word 1,$(subst :, ,$c)),$(word 2,$(subst :, ,$c)),$(__temp)) \
|
|
|
|
) \
|
|
|
|
) \
|
|
|
|
$(__temp) \
|
|
|
|
)
|
|
|
|
|
|
|
|
#####
|
|
|
|
# function strupper(source)
|
|
|
|
#####
|
|
|
|
strupper = $(call strtr,$1,$([a-z]),$([A-Z]))
|
|
|
|
|
|
|
|
#####
|
|
|
|
# function strlower(source)
|
|
|
|
#####
|
|
|
|
strlower = $(call strtr,$1,$([A-Z]),$([a-z]))
|
|
|
|
|
|
|
|
#####
|
|
|
|
# function strlen(source)
|
|
|
|
#####
|
|
|
|
strlen = \
|
|
|
|
$(eval __temp := $(subst $([space]),_,$1)) \
|
|
|
|
$(words \
|
|
|
|
$(strip \
|
|
|
|
$(foreach c, \
|
|
|
|
$([all]), \
|
|
|
|
$(eval __temp := \
|
|
|
|
$(subst $c,$c ,$(__temp)) \
|
|
|
|
) \
|
|
|
|
) \
|
|
|
|
$(__temp) \
|
|
|
|
) \
|
|
|
|
)
|
|
|
|
|
|
|
|
#####
|
|
|
|
# function streq(source)
|
|
|
|
#####
|
|
|
|
streq = $(if $(filter-out xx,x$(subst $1,,$2)$(subst $2,,$1)x),,1)
|
|
|
|
|
|
|
|
#####
|
|
|
|
# function strne(source)
|
|
|
|
#####
|
|
|
|
strne = $(if $(filter-out xx,x$(subst $1,,$2)$(subst $2,,$1)x),1,)
|