Code Monkey home page Code Monkey logo

Comments (16)

D13410N3 avatar D13410N3 commented on August 15, 2024 12

A little patch (maybe it even works on MIPS, idk)
https://github.com/ICQFan4ever/MTProxyARMPatch

Compiled on ARMv7 successfully

from mtproxy.

daro-ilovetea avatar daro-ilovetea commented on August 15, 2024 6

A little patch (maybe it even works on MIPS, idk)
https://github.com/ICQFan4ever/MTProxyARMPatch

Not working (any more?) on ARM:

`common/crc32c.c: In function ‘crc32c_partial_sse42_clmul’:
common/crc32c.c:406:14: warning: implicit declaration of function ‘__builtin_ia32_pclmulqdq128’ [-Wimplicit-function-declaration]
v2di F = __builtin_ia32_pclmulqdq128 (D, K, 0x00) ^ __builtin_ia32_pclmulqd

common/crc32c.c:406:14: error: incompatible types when initializing type ‘v2di {aka __vector(2) long long int}’ using type ‘int’
common/crc32c.c:471:14: error: incompatible types when initializing type ‘v2di {aka __vector(2) long long int}’ using type ‘int’
v2di F = __builtin_ia32_pclmulqdq128 (D, K, 0x00) ^ __builtin_ia32_pclmulqd`

from mtproxy.

stek29 avatar stek29 commented on August 15, 2024 2

It's not compatible with arm at all -- there are some hacks and/or inline assembly

from mtproxy.

pokono avatar pokono commented on August 15, 2024 2

Any plans on porting it?

from mtproxy.

Kirya2k avatar Kirya2k commented on August 15, 2024 1

If you are going to port sourcecode for arm, please do not use arm-specific instructions as you would like to have crosscode for mips/mipscel too.
Plz...

from mtproxy.

khaliullov avatar khaliullov commented on August 15, 2024 1

It seems that ARMv7 does not have CRC32x assembler directives (possible SSE4 extensions). I have tried to compile using following flags:

+CFLAGS = $(ARCH) -O3 -std=gnu11 -Wall -mtune=cortex-a9 -march=armv7-a -mfpu=vfp -mfloat-abi=softfp -fno-strict-aliasing -fno-strict-overflow -fwrapv -DAES=1 -DCOMMIT=\"${COMMIT}\" -D_GNU_SOURCE=1 -D_FILE_OFFSET_BITS=64

but without success:

/opt/tmp/ccB39ZkK.s:34: Error: selected processor does not support `crc32b (r3),r2' in ARM mode
/opt/tmp/ccB39ZkK.s:52: Error: bad instruction `crc32l (ip),r2'
/opt/tmp/ccB39ZkK.s:73: Error: selected processor does not support `crc32b (r3),r0' in ARM mode
/opt/tmp/ccB39ZkK.s:83: Error: selected processor does not support `crc32b (r2),r0' in ARM mode
/opt/tmp/ccB39ZkK.s:93: Error: selected processor does not support `crc32b (r3),r0' in ARM mode
make: *** [Makefile:89: objs/common/crc32c.o] Error 1

So, the only way is to implement them (CRC32 instuctions) on C by modification of crc32c.c.

from mtproxy.

khaliullov avatar khaliullov commented on August 15, 2024 1

@ICQFan4ever thank you! Just checked - and it works on my Raspberry Pi 3+

from mtproxy.

SergeyAnuchin avatar SergeyAnuchin commented on August 15, 2024 1

A little patch (maybe it even works on MIPS, idk)
https://github.com/ICQFan4ever/MTProxyARMPatch

Compiled on ARMv7 successfully

Thank you! Compiled successfully on

lscpu
Architecture: armv7l
Byte Order: Little Endian
Model name: ARMv7 Processor rev 2 (v7l)

./mtproto-proxy --help
[25630][2019-02-20 17:38:47.421699 local] Invoking engine mtproxy-0.01 compiled at Feb 20 2019 17:34:49 by gcc 5.4.0 20160609 32-bit after commit 2c94211
usage: ./mtproto-proxy [-v] [-6] [-p] [-H{,}] [-M] [-u] [-b] [-c] [-l] [-W]
mtproxy-0.01 compiled at Feb 20 2019 17:34:49 by gcc 5.4.0 20160609 32-bit after commit 2c94211

from mtproxy.

kogeler avatar kogeler commented on August 15, 2024

Almost a year has passed. : ((

from mtproxy.

Meysam- avatar Meysam- commented on August 15, 2024

A little patch (maybe it even works on MIPS, idk)
https://github.com/ICQFan4ever/MTProxyARMPatch

Compiled on ARMv7 successfully

Thank you! It compiles successfully on my Raspberry pi 4b :D

from mtproxy.

dllz avatar dllz commented on August 15, 2024

A little patch (maybe it even works on MIPS, idk)
https://github.com/ICQFan4ever/MTProxyARMPatch

Compiled on ARMv7 successfully

Can add that the patch works on Raspberry Pi 3 in 2020

from mtproxy.

John-Lin avatar John-Lin commented on August 15, 2024

Compiled failed on ARMv8 on Raspberry Pi 4
Screen Shot 2020-07-12 at 10 56 20 PM

from mtproxy.

nuBacuk avatar nuBacuk commented on August 15, 2024

Screenshot 2021-12-01 at 01 31 42

I tried to compile for arm ampere for Oracle, it did not work.

from mtproxy.

argent-tower avatar argent-tower commented on August 15, 2024

I tried to compile for arm ampere for Oracle, it did not work. lscpu listing is on the screenshot
image

from mtproxy.

kingofnull avatar kingofnull commented on August 15, 2024

A little patch (maybe it even works on MIPS, idk) https://github.com/ICQFan4ever/MTProxyARMPatch

Compiled on ARMv7 successfully

Thanks a lot it worked for Orange PI PC. I think it at least works at most of the armhf platforms .

from mtproxy.

posti85 avatar posti85 commented on August 15, 2024

The patch output was:

$ patch -p1 < arm.patch
patching file Makefile
Hunk #2 FAILED at 13.
1 out of 2 hunks FAILED -- saving rejects to file Makefile.rej
patching file common/cpuid.c
patching file common/crc32.c
patching file common/crc32c.c
patching file common/precise-time.h
patching file common/server-functions.h

and then the make command execution didn't work :(

from mtproxy.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.