From 90ac44f2fa29e3affd1a26659981e96af7d58e9e Mon Sep 17 00:00:00 2001 From: Sam Al-Sapti Date: Thu, 30 Mar 2023 18:22:46 +0200 Subject: [PATCH] Move stuff into src folder --- Makefile => src/Makefile | 10 ++++++---- config.patch => src/config.patch | 0 src/gale_shapley.mpc | 2 +- run.sh => src/run.sh | 2 +- 4 files changed, 8 insertions(+), 6 deletions(-) rename Makefile => src/Makefile (66%) rename config.patch => src/config.patch (100%) rename run.sh => src/run.sh (76%) diff --git a/Makefile b/src/Makefile similarity index 66% rename from Makefile rename to src/Makefile index e105ffe..4271aa8 100644 --- a/Makefile +++ b/src/Makefile @@ -1,10 +1,10 @@ -MP_SPDZ_PATH := src/MP-SPDZ +MP_SPDZ_PATH := $(CURDIR)/MP-SPDZ all: patch deps $(MAKE) -C $(MP_SPDZ_PATH) all patch: - -git -C $(MP_SPDZ_PATH) apply ../../config.patch + -git -C $(MP_SPDZ_PATH) apply $(CURDIR)/config.patch deps: patch sudo apt install automake build-essential clang cmake git libntl-dev \ @@ -12,8 +12,10 @@ deps: patch $(MAKE) -C $(MP_SPDZ_PATH) boost $(MAKE) -C $(MP_SPDZ_PATH) libote mpir -%.mpc: - cd $(MP_SPDZ_PATH) && ./compile.py ../$@ +%.mpc: _phony + python3 $(MP_SPDZ_PATH)/compile.py $@ %: $(MAKE) -C $(MP_SPDZ_PATH) $@ + +.PHONY: _phony diff --git a/config.patch b/src/config.patch similarity index 100% rename from config.patch rename to src/config.patch diff --git a/src/gale_shapley.mpc b/src/gale_shapley.mpc index 09e3d14..8d5ceb6 100644 --- a/src/gale_shapley.mpc +++ b/src/gale_shapley.mpc @@ -148,6 +148,6 @@ class Matchmaker: print('match', self.oram_type) -mm = Matchmaker(5, oram_type=OptimalORAM) +mm = Matchmaker(50, oram_type=OptimalORAM) mm.init_easy() mm.match() diff --git a/run.sh b/src/run.sh similarity index 76% rename from run.sh rename to src/run.sh index cc4cad3..f678cf9 100755 --- a/run.sh +++ b/src/run.sh @@ -2,5 +2,5 @@ MACHINE="$1" shift -cd src/MP-SPDZ +cd MP-SPDZ "./$MACHINE" "$@"