Squirrel Bot · @squirrelbot
10 followers · 5229 posts · Server mstdn.jp

_FP_W_TYPE_SIZE < 64
"Only stud muffins allowed, schmuck."

-- linux/arch/sparc64/quad.c

#fortune #endif #error #if

Last updated 1 year ago

fortune · @fortune
1918 followers · 4969 posts · Server social.linux.pizza

+ defined(__alpha__) && defined(CONFIG_PCI)
+ /*
+ * The meaning of life, the universe, and everything. Plus
+ * this makes the year come out right.
+ */
+ year -= 42;
+
-- From the patch for 1.3.2: (kernel/time.c), submitted by Marcus Meissner

#if #endif

Last updated 1 year ago

Ludovic · @usul
558 followers · 6937 posts · Server piaille.fr

- VBoxNetFlt does not build on 38 - Super User
superuser.com/questions/180620

edit /usr/share/virtualbox/src/vboxhost/vboxnetflt/linux/VBoxNetFlt-linux.c and change
RTLNX_VER_MIN(6,5,0) # include <net/gso.h>

to 5,4,0

#linux #fedora #If #endif

Last updated 1 year ago

Squirrel Bot · @squirrelbot
9 followers · 5016 posts · Server mstdn.jp

_FP_W_TYPE_SIZE < 32
"Here's a nickel kid. Go buy yourself a real computer."

-- linux/arch/sparc64/double.h

#fortune #endif #error #if

Last updated 1 year ago

Wolf480pl · @wolf480pl
1098 followers · 35871 posts · Server mstdn.io

@nytpu how about sth like this once in some header

_WINDLL
DLLEXPORT __declspec(dllexport)

DLLEXPORT

And then you just

DLLEXPORT
int
eventHandler(...)

#ifdef #define #else #endif

Last updated 1 year ago

Koakuma · @koakuma
292 followers · 32793 posts · Server uwu.social

__cplusplus
"pls no cplusplus i want fast compiles ;_;"

#endif #error #ifdef

Last updated 1 year ago

Matt Mascarenhas · @miblo
105 followers · 750 posts · Server mas.to

@lain_7 @rifkin @jef Basically same here:

────
0
ctime -begin ${0%.*}.ctm
clang -g -fsanitize=address -std=c99 $0 -o ${0%.*}
ctime -end ${0%.*}.ctm
exit

────

That's the intro to all my new .c files. (ctime, by the way, times the build.) I got the idea from Won Chun, and like to think of it grandly as "The Won Build System".

#endif #if

Last updated 1 year ago

David Mankins · @lain_7
118 followers · 1320 posts · Server tldr.nettime.org

@rifkin @jef

I used to start quickie C programs with:

----------------------------
notdef
gcc $0 -o $(basename $0 .c)
exit $?

int main....

---------------------------

Then I could compile by saying "sh foo.c"

This was especially useful if the compile line was complicated (e.g., the C program required linking with special libraries or something).

(Actually I used back-quotes instead of $(....), but this phone doesn't have back-quote on this keyboard.)

#ifdef #endif

Last updated 1 year ago

Paul Haddad :tapbots_logo: · @paul
37340 followers · 2974 posts · Server tapbots.social

@marcoarment I mean you can work around at least one of those.

let
let __auto_type const

var
var __auto_type

#ifndef #define #endif

Last updated 1 year ago

/usr/games/fortune · @fortune
14 followers · 2027 posts · Server botsin.space

_FP_W_TYPE_SIZE < 32
"Here's a nickel kid. Go buy yourself a real computer."

-- linux/arch/sparc64/double.h

#if #error #endif #humor #unix #usr #games #fortune

Last updated 1 year ago

NetBSD Source Changes · @netbsdsrc
23 followers · 3447 posts · Server mstdn.social

#endif #if

Last updated 1 year ago

Rich Felker · @dalias
1747 followers · 12689 posts · Server hachyderm.io

A || B || C || D || E
something

something_else

where A, B, C, D, and E are diverse system types, should perhaps make you think "maybe something_else is the portable option and the something that works on $mylaptop is the odd one out"

but no. 🤦

codesearch.debian.net/search?q

#if #else #endif

Last updated 1 year ago

ーーー/NNN1590@mstdn.jp · @nnn1590
7 followers · 621 posts · Server mstdn.jp

Cファイル内にシェルスクリプトを書くことによりビルドスクリプトとソースコードを1つのファイルにまとめるという荒業
```c
0
set -e
OUTPUT="$(mktemp)"
gcc "${0}" -o "${OUTPUT}"
set +e
"${OUTPUT}" "${@}"
RET="${?}"
rm "${OUTPUT}"
exit "${RET}"

<stdio.h>
<stdlib.h>

int main(int argc, char* argv[]) {
printf("Hello, world!\n");
for (int i = 1; i < argc; i++)
printf("argv[%d]: %s\n", i, argv[i]);
return EXIT_SUCCESS;
}
```

#include #endif #if

Last updated 1 year ago

NetBSD Source Changes · @netbsdsrc
26 followers · 2919 posts · Server mstdn.social

sys/arch/evbarm/nslu2: nslu2_machdep.c

rin: Missing for the previous...

cvsweb.netbsd.org/bsdweb.cgi/s

#endif

Last updated 1 year ago

SASANO Takayoshi · @uaa
61 followers · 1615 posts · Server social.mikutter.hachune.net

CONFIG_MACH_SUN50I_H616
SUNXI_DRAM_COM_BASE 0x047FA000
SUNXI_DRAM_CTL0_BASE 0x047FB000
SUNXI_DRAM_PHY0_BASE 0x04800000

#ifdef #define #endif

Last updated 1 year ago

Pitt (Swift && Tips) · @swiftandtips
122 followers · 245 posts · Server iosdev.space

In Xcode 15, Inactive code in blocks is now dimmed 👇🏻

#if #endif

Last updated 1 year ago

mattst88 :gentoo: · @mattst88
127 followers · 54 posts · Server fosstodon.org

I rebuild Mesa with assertions enabled and rerun the unit test... and it passes. Huh?

I rebuild without assertions, assuming I made some kind of mistake. Unit test fails again.

I confirm that the allocations are properly aligned when Mesa is built with assertions and unaligned when built without assertions. So I'm not going crazy, but WTF?

Then I spot this in the definition of the `gc_block_header` struct (which `gc_alloc_size` allocates):

> NDEBUG
> unsigned canary;
>

Oh.

#ifndef #endif

Last updated 1 year ago

Annie · @Anniiii
49 followers · 371 posts · Server gts.ferreo.dev

@selfisekai I'd recommend
```
_WIN32
"Won't fix!"

```

#ifdef #error #endif

Last updated 1 year ago

thradams · @thradams
7 followers · 101 posts · Server social.vivaldi.net

Compiling sqlite3.c (amalgamated version of sqlite) with cake
I got interesting warnings

static void charFunc(
...
*zOut++ = 0x80 + (u8)(c & 0x3F);
} \
}
sqlite3_result_text64(context, (char*)z, zOut-z, sqlite3_free, SQLITE_UTF8);
}

defined(SQLITE_WIN32_HAS_ANSI)
WINBASEAPI HANDLE WINAPI CreateFileMappingA(HANDLE, LPSECURITY_ATTRIBUTES, \
DWORD, DWORD, DWORD, LPCSTR);
/* defined(SQLITE_WIN32_HAS_ANSI) */

#if #endif

Last updated 1 year ago

R_dev_news · @R_devs_news
21 followers · 15 posts · Server fosstodon.org

2023-05-18: CHANGES IN R 4.3.0 patched C-LEVEL FACILITIES


*

The C prototypes for LAPACK calls ‘dspgv’ and ‘dtptrs’ in ‘R_exts/Lapack.h’ had one too many and one too few character length arguments - but this has not caused any known issues. To get the corrected prototypes, include

// for PR18534fixed PR18534fixed # define usePR18534fix 1

in your C/C++ code (PR#18534). developer.r-project.org/blosxo

#include #ifdef #endif

Last updated 1 year ago