portability

How necessary or convenient is it to write portable SQL?

Time and again, I've seen people here and everywhere else advocating avoidance of nonportable extensions to the SQL language, this being the latest example. I recall only one article stating what I'm about to say, and I don't have that link anymore. Have you actually benefited from writing portable SQL and dismissing your dialect's prop...

How un-portable is assembly language, /really/?

I understand that writing anything in assembly, or adding assembly to any program harms its portability. But, how bad? I mean, basically all PC's are x86 or x64 these days, right? So, if I embed assembly into a C program, why wouldn't it still compile no matter where it went? Does this notion of un-portability just refer to when you rea...

How to determine if 2 paths reference the same file in portable C++

Hello. I was wondering if there is a portable way to determine if 2 different paths actually reference the same file. I have read this thread but is Windows-specific. AFAIK, fstream isn't suitable for the job. ...

Best way to write portable Scheme code?

In Common Lisp I can conditionally exclude or include code for different implementations like this: #+sbcl (use-sbcl-cool-feature) #-sbcl (use-my-own-not-so-cool-version) This way I can write portable code by isolating the non-portable bits. How can this be done in Scheme? Is there a way to ask the Scheme interpreter or compiler its...

Portable C++ 03 Exact Width Types

Background Unfortunately the current C++ standard lacks C99's exact-width types defined in the stdint header. The next best thing I could find (in terms of portability) was Boost's cstdint.hpp implementation from the Boost.Integer library. Concerns That said, I've got a few problems with it: Boost's implementation dumps all the ...

What's the main problem of Windows-porting Banshee?

Is it specific to the Banshee project or to the Mono platform as a whole? ...

Including Large Wordlist in Stand-alone Dictionary Application

The Application I'm working on a simple dictionary search tool, with the main purpose of searching a word-list of around 180,000 words. To begin with, the word-list was a plain-text document, with each word on a single line. Upon loading, the word-list was processed into a simple array for searching. The Objective My objective, howev...

GetThreadId on pre-vista systems?

Apperantly, GetThreadId is a Vista API. How can I get a thread's id on pre vista systems? ...

Declaring fixed-size integer typedef in Standard C

Is there a reliable way to declare typedefs for integer types of fixed 8,16,32, and 64 bit length in ISO Standard C? When I say ISO Standard C, I mean that strictly: ISO C89/C90, not C99. No headers not defined in the ISO standard. No preprocessor symbols not defined in the ISO standard. No type-size assumptions not specified in the ...

How can I write portable Windows applications?

Sometimes, I want to write an simple application which will works on any Windows machine, without installing any programs or components (ex. .NET Framework), in a C# or Java like programming language. How can I do this? Thanks. EDIT: Added the 'like', sorry... ...

Portability concerns on C struct/union

Supposing I have the following type from an external library: union foreign_t { struct { enum enum_t an_enum; int an_int; } header; struct { double x, y; } point; }; is it safe to assume the following code fragment will work as expected on different platforms and with different compilers? struc...

jndi.properties in JBoss and GlassFish deployment

Currently an EJB / Web Application project uses a JBoss-specific JNDI configuration file, placed either in the conf directory or in the Jar file (both works fine). How can I make this project portable between JBoss (4.2.3 or 5) and GlassFish 3? Is there a recommended way to set different JNDI configuration parameters depending on the co...

Portable web applications framework

I like Gears (aka Google Gears), but it seems to need a lot of work and AJAX skills to enable off-line support in portions of web applications. What about distributing web applications were there is no web? I mean, something like server2go, a portable web server you can deploy along with database and PHP scripts. Is there some framework ...

Drupal Development on a Thumb Drive

I mostly a .NET developer but need to do some new work in Drupal. So I guess I need a portable - Apache - PHP - MySQL - phpMyAdmin - Drupal codebase What is the best way to work with the environment on a portable / thumb drive? I'm on Windows. I want to go portable because I work on 3 to 4 different machines throughout the week. Is...

Is there a way to build a portable RIA without using LiveCycle?

I saw your article on portable RIAs. Excellent article! http://www.adobe.com/devnet/flex/articles/portable%5Fria.html We don't have LiveCycle, but want to allow our users to view a Flex App inside PDF without an internet connection. Is there another way like using Cold Fusion, AlivePDF, to accomplish the PDF Generation part of your ar...

What is ideal software setup for programming web applications (editing php, javascript, xhtml, css) ?

I've been developing web applications for 2 years now, and have been into simpler web pages for many more. I've been using Notepad, then ConText, then Crimson Editor (was my favorite for a long time) and I've been trying with Notepad++. I have NetDrive setup so I can edit and save files directly on the ftp server. On Firefox I use the We...

Is the use of previously defined members as part of later members in an enum definition legal?

namespace ValueType { enum Enum { Boolean = 0, Float = 1, Double, SInt = 8, SLong, UInt = SInt + (1 <<4), ULong = SLong + (1 << 4) }; } ...

Unix paths: officially work in Python for any platform?

Can all paths in a Python program use ".." (for the parent directory) and / (for separating path components), and still work whatever the platform? On one hand, I have never seen such a claim in the documentation (I may have missed it), and the os and os.path modules do provide facilities for handling paths in a platform agnostic way (o...

Should I use automake/autoconf for distribution of a small ansi C app?

I have a small ANSI C application which compiles cleanly under different tested compilers and platforms. It doesn't use any preprocessor switches or external dependencies and the makefile is simply something like: myapp: *.c gcc *.c -Wall -o myapp If I want to distribute this project in source form as portable as possible, should ...

How to split file on first empty line in a portable way in shell (e.g. using sed)?

I want to split a file containg HTTP response into two files: one containing only HTTP headers, and one containg the body of a message. For this I need to split a file into two on first empty line (or for UNIX tools on first line containing only CR = '\r' character) using a shell script. How to do this in a portable way (for example us...