summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile3
-rwxr-xr-xtools/install.py3
2 files changed, 3 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index fba242766d..a28c66fc0a 100644
--- a/Makefile
+++ b/Makefile
@@ -8,7 +8,8 @@ SIGN ?=
PREFIX ?= /usr/local
# Determine EXEEXT
-EXEEXT=$(shell $(PYTHON) -c "import sysconfig; print(sysconfig.get_config_var('EXE'))")
+EXEEXT := $(shell $(PYTHON) -c \
+ "import sys; print('.exe' if sys.platform == 'win32' else '')")
NODE ?= ./node$(EXEEXT)
NODE_EXE = node$(EXEEXT)
diff --git a/tools/install.py b/tools/install.py
index 14342354d1..52c1109941 100755
--- a/tools/install.py
+++ b/tools/install.py
@@ -11,7 +11,6 @@ import os
import re
import shutil
import sys
-import sysconfig
# set at init time
node_prefix = '/usr/local' # PREFIX variable from Makefile
@@ -128,7 +127,7 @@ def subdir_files(path, dest, action):
action(files, subdir + '/')
def files(action):
- exeext=sysconfig.get_config_var('EXE')
+ exeext = '.exe' if sys.platform == 'win32' else ''
action(['out/Release/node' + exeext], 'bin/node' + exeext)
if 'true' == variables.get('node_use_dtrace'):