Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SGX SDK installer is x86,not x64 #177

Closed
daichunkai opened this issue Nov 8, 2017 · 8 comments
Closed

SGX SDK installer is x86,not x64 #177

daichunkai opened this issue Nov 8, 2017 · 8 comments

Comments

@daichunkai
Copy link

Hello,When I use command

make sdk_install_pkg

to build the Intel(R) SGX SDK installer,the installer should be x64,but in my computer is x86,
the install as follows:
image

and the information of my computer as follows:
image

@yuyuany
Copy link

yuyuany commented Nov 8, 2017

Can you paste the output of the following command:
readelf -h $(SGX_SDK_DIR)/build/linux/sgx_sign

@daichunkai
Copy link
Author

image

@daichunkai
Copy link
Author

also I find a question,When my system's language is English,it will build 64bit installer,but other language is x86

@yuyuany
Copy link

yuyuany commented Nov 8, 2017

The installer build script simply reads the magic number of sgx_sign to determine it is x86 or x64. The parser may get the wrong number from a different language other than English. You can find the parser from get_arch() in linux/installer/bin/build-installpkg.sh.

@llly
Copy link
Contributor

llly commented Nov 8, 2017

Can you give the result of file -L /bin/sh for another language except English?

@daichunkai
Copy link
Author

@llly In Chinese ,the readout of file -L /bin/shis
image
@yuyuany I find build-installpkg.sh and I will try to change some code to build x64 installer

@yuyuany
Copy link

yuyuany commented Nov 9, 2017

Ok, and pull requests are welcome.

@jat001
Copy link
Contributor

jat001 commented Sep 11, 2018

LANGUAGE=en_US readelf -h build/linux/sgx_sign | sed -n '2p'
Magic:   7f 45 4c 46 02 01 01 00 00 00 00 00 00 00 00 00

LANGUAGE=zh_CN readelf -h build/linux/sgx_sign | sed -n '2p'
Magic:  7f 45 4c 46 02 01 01 00 00 00 00 00 00 00 00 00

The colon is fullwidth in CJK computing. So awk '/:/{print $6}' does not work. The simplest solution is to remove /:/ on https://github.com/intel/linux-sgx/blob/master/linux/installer/bin/build-installpkg.sh#L60

lzha101 added a commit that referenced this issue Sep 17, 2018
fix #177 - Fullwidth character issue

Signed-off-by: Zhang Lili Z <lili.z.zhang@intel.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants