Skip to content

Commit

Permalink
Make windows fail
Browse files Browse the repository at this point in the history
  • Loading branch information
xpenatan committed Jul 11, 2023
1 parent e7a97d4 commit ba6cb86
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 4 deletions.
2 changes: 1 addition & 1 deletion example/example-build/jni/cpp/src/NormalClass.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@

int NormalClass::addIntValue(int a, int b)
{
return a + b;
return (a + b) * hiddenInt * hiddenParentInt;
}
5 changes: 4 additions & 1 deletion example/example-build/jni/cpp/src/NormalClass.h
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
#include "ParentClass.h"

#ifndef NORMALCLASS_H
#define NORMALCLASS_H

class NormalClass
class NormalClass : public ParentClass
{
int hiddenInt = 1;
public:
int addIntValue(int a, int b);
};
Expand Down
4 changes: 2 additions & 2 deletions example/example-build/jni/cpp/src/ParentClass.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

float ParentClass::addFloatValue(float a, float b)
{
return a + b;
return (a + b) * hiddenParentInt;
}

bool ParentClass::invertBoolean(bool value)
{
return !value;
return !(bool)(value * hiddenParentInt);
}
2 changes: 2 additions & 0 deletions example/example-build/jni/cpp/src/ParentClass.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@

class ParentClass
{
protected:
int hiddenParentInt = 1;
public:
float addFloatValue(float a, float b);
bool invertBoolean(bool value);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ private static void generateCPP() throws Exception {
CppCodeParser idlParser = new CppCodeParser(cppGenerator, idlReader, basePackage);
idlParser.generateClass = true;
JParser.generate(idlParser, baseJavaDir, genDir);
CPPBuildHelper.DEBUG_BUILD = true;
CPPBuildHelper.build(libName, jniBuildPath, libsDir);
}
}

0 comments on commit ba6cb86

Please sign in to comment.