diff --git a/Sound/ALSA/Mixer/Internal.chs b/Sound/ALSA/Mixer/Internal.chs
--- a/Sound/ALSA/Mixer/Internal.chs
+++ b/Sound/ALSA/Mixer/Internal.chs
@@ -167,14 +167,13 @@
 
 elements :: Mixer -> IO [(SimpleElementId, SimpleElement)]
 elements fMix = do
-    pFirst <- sndMixerFirstElem fMix
-    pLast <- sndMixerLastElem fMix
-    es <- elements' pFirst [] pLast
+    pFirst <- sndMixerFirstElem fMix -- Returns null if list of mixer-elems is empty.
+    es <- elements' pFirst []
     mapM (simpleElement fMix) es
-  where elements' pThis xs pLast | pThis == pLast = return $ pThis : xs
-                                 | otherwise = do
-                                     pNext <- sndMixerElemNext pThis
-                                     elements' pNext (pThis : xs) pLast
+  where elements' pThis xs | pThis == nullPtr = return xs
+                           | otherwise = do
+                               pNext <- sndMixerElemNext pThis
+                               elements' pNext (pThis : xs)
 
 -----------------------------------------------------------------------
 -- simpleElement
diff --git a/alsa-mixer.cabal b/alsa-mixer.cabal
--- a/alsa-mixer.cabal
+++ b/alsa-mixer.cabal
@@ -1,5 +1,5 @@
 Name:                alsa-mixer
-Version:             0.3.0
+Version:             0.3.0.1
 Synopsis:            Bindings to the ALSA simple mixer API.
 Description:         This package provides bindings to the ALSA simple mixer API.
 License:             BSD3
@@ -9,7 +9,7 @@
 Copyright:           2014-2018 Thomas Tuegel
 Category:            Sound
 Build-type:          Simple
-Cabal-version:       >=1.6
+Cabal-version:       >=1.10
 Homepage:            https://github.com/ttuegel/alsa-mixer
 Bug-reports:         https://github.com/ttuegel/alsa-mixer/issues
 Extra-source-files:  changelog
@@ -18,11 +18,18 @@
   Type:     git
   Location: https://github.com/ttuegel/alsa-mixer.git
 
+Flag cross
+  Description:         Set this flag if cross-compiling
+  Default:             False
+  Manual:              True
+
 Library
   Exposed-modules:     Sound.ALSA.Mixer
   Other-modules:       Sound.ALSA.Mixer.Internal
-  Build-tools:         c2hs
+  if !flag(cross)
+      Build-tools:     c2hs
   Extra-libraries:     asound
   Build-depends:       base == 4.*,
                        alsa-core == 0.5.*,
                        unix >= 2.6 && < 3
+  default-language: Haskell2010
diff --git a/changelog b/changelog
--- a/changelog
+++ b/changelog
@@ -1,3 +1,7 @@
+0.3.0.1 Thomas Tuegel <ttuegel@mailbox.org> 2023-12-09
+    * Add +cross flag to .cabal file (#8)
+    * Avoid returning [nullPtr] if mixer elements are empty (#13)
+
 0.3.0 Thomas Tuegel <ttuegel@mailbox.org> 2018-12-09
     * Use C types in exported interface (#6)
 
