Several changes for size reduction (#929)

* Support CAPSTONE_STATIC with __GNUC__ compilers

* Allow custom export rules

* Make CAPSTONE_SHARED the default visibility option with GNUC (avoids behaviour changes)

* Reduce capstone static build size (mainly for kernel usage)

* Allow basic cs_detail support in diet mode

* Fixed valid_bnd unused function warning

* Do not disable cs_detail generation in CAPSTONE_DIET, use CAPSTONE_NO_DETAIL for that.

* Reverted CAPSTONE_NO_DETAIL at least until capstone supports more flexible configuration

* Added a missing endif

* Disallow custom export rules
7 files changed