| View previous topic :: View next topic |
| Author |
Message |
coolkehon
Joined: 20 Oct 2008 Posts: 355
|
Posted: Mon Oct 12, 2009 8:44 am Post subject: Cryptopp 5.6.0 rev 477 ported to psp |
|
|
used jojojaris makefile and modified to port cryptopp
I posted it in another thread but here is the official
| Code: | #makfile originally by jojojaris
#but modified to port cryptopp 5.6.0 rev 447 by coolkehon
#hm makefile looks strangly familiar I've used this somewhere before
PREFIX=$(shell psp-config –psp-prefix)
PREFIX=/usr/local/pspdev/psp
TARGET_LIB = libcryptopp.a
SRCS = $(wildcard *.cpp)
ifeq ($(SRCS),) # workaround wildcard function bug in GNU Make 3.77
SRCS = $(shell echo *.cpp)
endif
#pre objects so that they can be removed
PRE_OBJS = $(SRCS:.cpp=.o)
#here to remove the test objects from library
TESTOBJS = bench.o bench2.o test.o validat1.o validat2.o validat3.o adhoc.o datatest.o regtest.o fipsalgt.o dlltest.o
OBJS = $(filter-out $(TESTOBJS),$(PRE_OBJS))
INCDIR =
CFLAGS = -O2 -G0 -Wall \
-DIS_LITTLE_ENDIAN #fixed this here because the psp is Little Endian
CXXFLAGS = $(CFLAGS)
ASFLAGS = $(CFLAGS)
LIBDIR =
#LDFLAGS = -flat_namespace -undefined suppress -m
LDFLAGS =
LIBS=-lstdc++
PSPSDK=$(shell psp-config --pspsdk-path)
include $(PSPSDK)/lib/build.mak
install:
mkdir -p $(PREFIX)/include/cryptopp
cp *.h $(PREFIX)/include/cryptopp
cp *.a $(PREFIX)/lib
tell:
echo $(PREFIX)
|
Last edited by coolkehon on Wed Nov 18, 2009 9:49 am; edited 1 time in total |
|
| Back to top |
|
 |
jojojoris
Joined: 30 Mar 2008 Posts: 261
|
Posted: Mon Oct 12, 2009 8:26 pm Post subject: |
|
|
Again
My name is
jojojoris
NOT
jojojaris or jojojarais etc _________________
| Code: | int main(){
SetupCallbacks();
makeNiceGame();
sceKernelExitGame();
} |
|
|
| Back to top |
|
 |
Wally

Joined: 26 Sep 2005 Posts: 672
|
Posted: Mon Oct 12, 2009 8:37 pm Post subject: |
|
|
| jojojoris wrote: | Again
My name is
jojojoris
NOT
jojojaris or jojojarais etc |
xD hilarious.
Nice port! |
|
| Back to top |
|
 |
coolkehon
Joined: 20 Oct 2008 Posts: 355
|
Posted: Mon Oct 12, 2009 10:04 pm Post subject: |
|
|
| jojojoris wrote: | Again
My name is
jojojoris
NOT
jojojaris or jojojarais etc |
mo jo jojo ris
that is so confusing to remember especially since i always spell it wrong |
|
| Back to top |
|
 |
coolkehon
Joined: 20 Oct 2008 Posts: 355
|
Posted: Wed Nov 18, 2009 9:48 am Post subject: |
|
|
I found a bug. I fixed it too.
When I created a hash using SHA512 it didn't work correctly. The hash didn't match on my computer and there was no reason for it. It took a while to figure out but I looked in the config.h file for cryptopp 5.5.2 and realized that IS_LITTLE_ENDIAN was not defined. when compiling you need to add -DIS_LITTLE_ENDIAN to your CFLAGS.
jojojaris could you add that to your makefile since 5.5.2 was your version.
Also the Cryptopp::Socket class doesn't work
As for cryptopp 5.6.0 there is another bug. When I connect to wifi and try to use regular sockets (not the class) it will not connect to wifi. I'm not sure if it's not loading the modules or what but I used jojojaris' EasyConnect class and it failed at the connect stage.
there are most likely more things to be check in the config but the -DIS_LITTLE_ENDIAN fixed my problem and I don't know of any other's at the moment except for maybe the one about berkely sockets being available |
|
| Back to top |
|
 |
jojojoris
Joined: 30 Mar 2008 Posts: 261
|
Posted: Wed Nov 18, 2009 4:54 pm Post subject: |
|
|
seems i lost my crypto++ files.
I don't know what's wrong with my EasyConnect class. It works for me and i never had any problems. (i guess you are not using PSP_HEAP_SIZE_MAX() becous that won't let other modules load)
And you still spell my nickname WRONG!!!
jojojoris and not jojojaris _________________
| Code: | int main(){
SetupCallbacks();
makeNiceGame();
sceKernelExitGame();
} |
|
|
| Back to top |
|
 |
coolkehon
Joined: 20 Oct 2008 Posts: 355
|
Posted: Thu Nov 19, 2009 1:43 am Post subject: |
|
|
hm sorry about the nick though i had it this time :P
if you want i can email you a copy of your cryptopp 5.5.2.
Also it's the cryptopp 5.6.0 that i ported that doesn't work with EasyConnect not the EasyConnect not working. I don't know why but it just doesn't work. It worked with 5.5.2 but not cryptopp 5.6.0. Probably something with the config.h in cryptopp
and I have PSP_HEAP_SIZE_MAX(); defined
bye jojojoris |
|
| Back to top |
|
 |
jojojoris
Joined: 30 Mar 2008 Posts: 261
|
Posted: Thu Nov 19, 2009 3:20 am Post subject: |
|
|
well...don't use
PSP_HEAP_SIZE_MAX();
use
PSP_HEAP_SIZE_KB(-2048); //Leave 2MB for other modules
But you spelled my nickname right :D _________________
| Code: | int main(){
SetupCallbacks();
makeNiceGame();
sceKernelExitGame();
} |
|
|
| Back to top |
|
 |
|