compatibility

GCC ABI compatibility

微笑、不失礼 提交于 2019-11-27 06:49:40
As far as I've understood, it is not possible to link libraries that use different versions of GCC's Application Binary Interface (ABI). Are there ABI changes to every version of GCC? Is it possible to link a library built with 4.3.1 if I use, say, GCC 4.3.2? Is there a matrix of some sort that lists all the ways I can combine GCC versions? ablaeul The official ABI page points to an ABIcheck . This tool may do, what you want. Since gcc-3.4.0, the ABI is forward compatible. I.E. a library made using an older release can be linked with a newer one and it should work (the reverse doesn't).

Creating Library with backward compatible ABI that uses Boost

拟墨画扇 提交于 2019-11-27 06:41:48
I'm working on a certain C++ library (or more framework). I want to make it backward compatible with previous versions preserving not only API compatibility but also ABI (like the great job Qt does). I use lots of functionality of Boost and it seems for me that this makes backward compatibility just impossible, unless I force a user to have exactly the same (sometimes old) version of Boost. Is there any way (without rewriting 1/2 of Boost) to make some "prefix" around its namespace/rename it in order to prevent it from interfering with a user version of Boost? For example my libXYZ uses Boost

How to set “Run this program as an administrator” programmatically

雨燕双飞 提交于 2019-11-27 06:41:26
I'm having a problem with good ol' bdeadmin.exe in Vista. First, let's get the predictable responses out of the way: "You should not require your application to be elevated." This one does. C'est la vie. "You need to embed a manifest file." It is already compiled, it is many years old, the company that created it has no intention of doing it again, and it is installed from a Merge Module (MSM file). "BDE is obsolete, you should be using dbExpress" One and a half million lines of code. 'Nuff said. "Drop a manifest file next to the EXE." Tried that, did nothing. As a test, that same manifest

Android: Tint using DrawableCompat

丶灬走出姿态 提交于 2019-11-27 06:24:55
I'm trying to tint an image prior to Android API level 21. I've successfully tinted items using: <android:tint="@color/red"/> However, I can't seem to figure out how to do this through code on an ImageView: Drawable iconDrawable = this.mContext.getResources().getDrawable(R.drawable.somedrawable); DrawableCompat.setTint(iconDrawable, this.mContext.getResources().getColor(R.color.red)); imageView.setImageDrawable(iconDrawable); I've tried setting the TintMode but this seems to make no different. Am I using the v4 compatibility class DrawableCompat incorrectly? The simplest way to tint cross

iOS 11 safe area layout guide backwards compatibility

自作多情 提交于 2019-11-27 06:08:34
Is enabling Safe Area Layout Guides compatible to iOS below 11? I managed to work with the new Safe Area layout guides and maintain backwards compatibility with iOS 9 and iOS 10: (EDIT: as pointed out in the comments by @NickEntin, this implementation will presume there is a status bar present, which won't be true in landscape on the iPhone X. Resulting in to much space to the top (20 points). It will run perfectly fine however. E.g. if you want a view to be 10 points below the status bar (and 10 points below the sensor housing on iPhone X): In your XIB, go to File Inspector and enable the

CreateTextRange is not working in Chrome

旧街凉风 提交于 2019-11-27 05:49:27
问题 In this code, createRange is not working in Chrome. In IE it is working. Please help how to rectify in this. Is there any other property to work like create range. So that it will helpful for my project. <script language=javascript> var isSelected; function markSelection ( txtObj ) { if ( txtObj.createTextRange ) { txtObj.caretPos = document.selection.createRange().duplicate(); isSelected = true; } } function insertTag ( txtName, enclose ) { if(document.f_activity_email == null) { var tag =

Handling the missing MENU button in new versions of Android (3.x and up)

一个人想着一个人 提交于 2019-11-27 05:38:41
问题 I'm a fan of the menu button as used in Android <3.0, as it was very useful for my game apps - it allowed me to take important but gameplay irrelevant functionality (saving game, reference info links) and place it somewhere where it did not clutter up the main game interface, but was still easily accessible (the options menu). This use of keys became a problem with 3.0, because it removed the MENU button and substituted it with the Action Bar. The Action bar is really not suitable for a game

Angular4 Application running issues in IE11

元气小坏坏 提交于 2019-11-27 05:16:01
问题 I am building a Angular4 project using Angular CLI (1.1.2). It runs perfectly in Chrome (Version 59.0.3071.115) and firefox(54.0.1) but when I tried to use IE11 (Verison 11.0.9600.18738) nothings shows up and when I open the develper mode in IE, it shows me the following Error: SCRIPT5022: Exception thrown and not caught File: polyfills.bundle.js, Line: 829, Column: 34 And the detailed Error message is following: Anyone knows how to solve this problem? Thanks! 回答1: To add more detail to

How to find out if a Python object is a string?

社会主义新天地 提交于 2019-11-27 05:00:31
问题 How can I check if a Python object is a string (either regular or Unicode)? 回答1: Python 2 Use isinstance(obj, basestring) for an object-to-test obj . Docs. 回答2: To check if an object o is a string type of a subclass of a string type: isinstance(o, basestring) because both str and unicode are subclasses of basestring . To check if the type of o is exactly str : type(o) is str To check if o is an instance of str or any subclass of str : isinstance(o, str) The above also work for Unicode strings

Optimizing Android manifest file for largest number of supported devices

我们两清 提交于 2019-11-27 04:28:08
问题 I am having issues getting my Manifest file to be compatible with a lot of the newer phones when I upload a new APK file and I don't understand why. I am testing it on a brand new HTC Evo V, but for whatever reason, that device won't show up in the compatibility list. I'm compiling against API 17 with a minimum support of API 10, so that should encompass a large majority of the phones. What I've tried: Removed all permissions; no change Tried making WIFI not required; no change Removed